HEAD and patches have failed repeatedly. The test appears to be running out of memory.
https://qa.drupal.org/pifr/test/720278
The test did not complete due to a fatal error. Completion check DisplayTest.php 322 Drupal\views_ui\Tests\DisplayTest->testViewStatus() <img src="/misc/watchdog-error.png" alt="" title="" width="18" height="18" />
The test did not complete due to a fatal error. Completion check DisplayTest.php 322 Drupal\views_ui\Tests\DisplayTest->testViewStatus() <img src="/misc/watchdog-error.png" alt="" title="" width="18" height="18" />
Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 268435456 bytes) in /var/lib/drupaltestbot/sites/default/files/checkout/core/lib/Drupal/Core/Database/Connection.php on line 336
HEAD fail in the same test:
* Drupal\views_ui\Tests\DisplayTest (375 pass(es), 2 fail(s), and 0 exception(s))
- [fail] [Completion check] "The test did not complete due to a fatal error." in DisplayTest.php on line 342 of Drupal\views_ui\Tests\DisplayTest->testActionLinks().
- [fail] [Completion check] "The test did not complete due to a fatal error." in DisplayTest.php on line 342 of Drupal\views_ui\Tests\DisplayTest->testActionLinks().Rather than having to increase the testbot's memory limit from 256 MB (lol), let's see if we can put this test on a diet.
| Comment | File | Size | Author |
|---|---|---|---|
| #19 | interdiff.txt | 3.26 KB | cameron tod |
| #19 | 2188897-views_displaytest_refactor-18.patch | 15.98 KB | cameron tod |
| #17 | 2188897-views_displaytest_refactor-17-do-not-test.patch | 16.36 KB | cameron tod |
| #16 | interdiff.txt | 496 bytes | cameron tod |
| #16 | 2188897-views_displaytest_refactor-16-do-not-test.patch | 64.24 KB | cameron tod |
Comments
Comment #1
xjmComment #2
tim.plunkettI ran this test locally and it took 13 minutes 37 seconds...
Comment #3
xjmComment #4
berdirDid some tests with xhprof and I think it only showed me bogus memory usage, because the numbers were very low. Note that it's also possible that we have random endless loop here, those also result in oom fatal errors. Doesn't seem that likely, though.
As usual when I'm profiling tests, found a few other issues, posted my general findings in #2006434-16: [meta] Speed up web tests.
Comment #5
berdirMaybe this was #2190421: Fix some services that shouldn't be serialized. We had a more or less persistent similar fail in UserCancelTest and PHP 5.4+ completely broken due to that.
Please report any failures about this that you see here, otherwise we can close it in a week or so?
Comment #6
berdirActually, what I think will help is #2190643: Serializing the container is a very very bad idea, let's prevent it?, because earlier test fails there showed that this class is also affected by that.
Comment #7
andypostFaced with that issue 3-4 times in #2191709-7: Remove the "configurable" flag on field types
Comment #8
damiankloip commentedWE could split this into two tests? > 10 mins for one test is not really that cool.
Comment #9
xjmSplitting it into two or more logical chunks seems like a sound idea to me, yeah.
Comment #10
berdirYes, I guess that would help, but I haven't seen this fail in quite some time, the only random fail that I've seen recently is the image field one.
So maybe change to a non-major task?
Comment #11
cameron tod commentedI split the tests into two classes:
- one class which handles adding and removing displays (DisplayTestCRUD)
- another class which handles the finer-grained actions in the UI (reordering, link displays, etc.) - DisplayTest
To cut down on duplicated code I used a trait to share code between them.
Test results:
Before patch:
After:
Comment #12
cameron tod commentedWhat's the best way to instrument memory usage on run-scripts.sh?
Comment #13
berdirYou could add a call to memory_get_peak_usage()
at the end, print it with format_size().Edit: Probably better to do it right after the test was executed the end is a bit complicated in case of that script ;)
Comment #14
cameron tod commentedo_O
Before patch:
After:
Comment #15
dawehnerI love the idea of not pack everything into one big test!
A bit of documentation would be maybe helpful.
Comment #16
cameron tod commentedBoop
Comment #17
cameron tod commentedThere's a lot of weird cruft in that patch...must have forgot to rebase.
Comment #18
damiankloip commentedSorry, this just feels like using a trait for the sake of it. This is not really a trait-like case IMO. It also has a dependency on WebTestBase.
I think randomView() should just move into the UITestBase class as this is generally a handy method - being able to create arbitrary views via the UI.
Comment #19
cameron tod commentedGood call. There might have been a touch of "cool, PHP 5.4" tbh :P
Comment #20
dawehnerIn general I consider traits as just a solution to not require base-classes for things which are technically just a copy&paste, so not sure whether dependencies actually matter ...
Comment #21
damiankloip commentedSure, but a base class usually has its own dependencies in order :) I think it is maybe not as useful in test classes tbh.
Comment #22
webchickGreat! Looks good here, apart from:
Fixed that on commit, and committed/pushed to 8.x. Thanks!
Comment #23
longwaveThis just failed again in https://qa.drupal.org/pifr/test/742998
The test did not complete due to a fatal error. Completion check DisplayTestCRUD.php 71 Drupal\views_ui\Tests\DisplayTestCRUD->testRemoveDisplay()
Fatal error: Allowed memory size of 268435456 bytes exhausted (tried to allocate 536870912 bytes) in /var/lib/drupaltestbot/sites/default/files/checkout/core/lib/Drupal/Core/Database/Connection.php on line 336
FATAL Drupal\views_ui\Tests\DisplayTestCRUD: test runner returned a non-zero error code (255).
Comment #24
berdirHaven't seen this in a very long time.