Closed (fixed)
Project:
Drupal core
Version:
9.0.x-dev
Component:
quickedit.module
Priority:
Critical
Category:
Bug report
Assigned:
Unassigned
Issue tags:
Reporter:
Created:
4 Mar 2019 at 18:56 UTC
Updated:
9 Nov 2020 at 08:59 UTC
Jump to comment: Most recent, Most recent file
Comments
Comment #2
tedbowI have altered
\Drupal\Tests\quickedit\FunctionalJavascript\QuickEditIntegrationTest::testArticleNode()to invoke the same test 2x.Then it runs only this test 50x
Comment #4
tedbow#2 mostly failed but passed randomly.
Comment #6
wim leersThanks for doing this! 🙏
😨
Comment #7
tim.plunkettOut of 100 runs, this failed 54 times.
Comment #8
wim leersAttempting to apply the techniques from #2948828-136: Layout Builder's Field Blocks do not work with Quick Edit here.
Comment #11
catchComment #12
catchThis is probably fixed by #3082602: Remove transform rule from css_disable_transitions_test. Going to mark as duplicate. Worst case we can re-open it.
Comment #13
catchCSS transitions aren't disabled in 8.x, so while that issue might reduce the frequency, it probably doesn't actually fix this.
Comment #15
jhodgdonI have seen several fails in this test in the past few days. Example:
https://www.drupal.org/pift-ci-job/1777967
This is definitely still a problem.
Comment #16
larowlanJust got this in head, going to retest
Comment #17
jhodgdonI'm getting this one and two others in issues I follow fairly frequently. I think about once a week in total, and it's often QuickEditIntegrationTest... Could we maybe remove the 3 most common culprits (look through the many RTBC issues that have been hanging out for months in the RTBC queue, and see what they've failed on) and not put these repeat offenders back into Core until they will reliably work?
See also #3165263: Allow known flaky tests to be automatically repeated
Comment #18
catchThis may be fixed by #3175112: hold_test module creates files in incorrect place leading to possible random errors.
Comment #19
catchGoing to go ahead and mark this as duplicate, since that issue is the first concrete fix for this for a long time. If it does recur, we can re-open.
Comment #20
longwaveUnfortunately that didn't solve it, this just failed again in https://www.drupal.org/pift-ci-job/1848467
Comment #21
catchThat is a shame, I think we should do this.
Comment #22
alexpottOnly waits for Ckeditor to be ready in the background it doesn't wait for the instances or loaded event to fire - see https://github.com/ckeditor/ckeditor4/blob/d1710c198d8f5007e8d04fed9870b...
I think we can fix this by waiting for the what we expect rather than for ckeditor's internal state.
Comment #24
alexpottBeen meaning to fix this the unhelpful reporting from WebDriverCurlService for a while.
Comment #26
alexpottFor a while I've been wondering if concurrency might be causing an issue in JS tests.
Comment #27
alexpottAnd with a concurrency of 5
Comment #28
alexpottAdd now 10
Comment #30
alexpottLet's see if going incognito helps...
Comment #32
alexpottComment #34
alexpottWell as useful as the test passing all the time is the test failing all the time! So the check for
is bogus. Once "save" is pressed in quickedit this class is eventually removed. It passes now on HEAD because this happens after the AJAX response so most of the time these elements do indeed exist. I have no idea why concurrency makes it more likely to happen - maybe things just go quicker when everything is running the same code.
fingers-crossed this one will pass...
Comment #35
alexpottLet's run all the tests...
Comment #36
alexpottConsistency... hold_test_request() is never actually called so it doesn't matter but it is best to be consistent. Let's enforce the consistency and the relationship to the time waiting in HoldTestSubscriber
Comment #37
alexpottSeeming as the latest approach fixes the test
Comment #40
alexpottOh fun. In #35 QuickEditImageTest - it's pressing save and expecting things to test able and not change. We need to use hold_test so we can test what is it testing. Also in reviewing this I realised we can re-instate the checks I removed ....
but move them before the hold_test_response() is released.
Comment #41
alexpottSo I think we one remaining question here is should we remove the now unused arguments. The only thing that is used now the $expected_field_attributes. Maybe we should tidy that up in a follow-up.
Comment #43
alexpottLet's trigger a deprecation. Imo this is not worth a CR but if there are any custom tests using this then at least you can ignore deprecations to make them pass... or make the change. There's no contrib using this.
Comment #44
longwaveI don't think the deprecation will ever trigger, as $entity_type_id is never going to be an array and so it will fail the type check first.
Comment #45
alexpottCreated #3178758: Remove deprecation layer and add argument type to ::assertEntityInstanceFieldMarkup for the deprecation removal and adding the typehint.
Comment #46
longwaveThis certainly looks like it should be more reliable, asserting in Mink instead of in-browser JS and not relying on CKEditor internal state definitely feels much cleaner.
Comment #47
jonathan1055 commentedNow that #3048495: Fix Drupal.Semantics.FunctionTriggerError coding standard is RTBC here's an updated patch to make the two new deprecation messages follow standards. Fixing them here has two benefits (a) the people involved here get to check the message in context, and (b) if this issue is committed first it avoids me re-rolling on the main issue.
I've set this back to NR for #47 but of course, if you don't want to fix the message, just put it to RTBC for patch #45
Comment #48
longwaveDidn't spot here that the deprecated method name should end in
()- if you want to make that change and upload it feel free to mark it RTBC.Comment #49
jonathan1055 commentedOK, thanks for that. Here's the updated patch and interdiff.
Comment #53
catchCommitted/pushed to 9.2.x and cherry-picked back to 9.0.x
Doesn't cherry-pick to 8.9.x - marking fixed but please re-open with a backport patch if someone does one.