Problem/Motivation
d7/MigrateFieldTest and d7/MigrateFieldInstanceTest both have two tests which normally indicates there is something different in the preparation for the test (different modules installed or changes to the source database) but in this case there are none. That is the two tests are identical except for the assertions run after the migration is finished. There is no need for two separate tests. The migration can be run once and then all the assertions
Also, an annoyance factor when working with those tests.
Steps to reproduce
Proposed resolution
Move the assertions from the second test to the first tests and remove the second test.
Remaining tasks
patch, review, commit
Comment | File | Size | Author |
---|---|---|---|
#2 | 3165763-2.patch | 2.17 KB | quietone |
Comments
Comment #2
quietone CreditAttribution: quietone as a volunteer commentedWell, lets see if anything fails.
Comment #3
bisonbleu CreditAttribution: bisonbleu commentedRemove the lonely 'a' in «both have two tests which normally indicates a there is something different in...»
Comment #4
bisonbleu CreditAttribution: bisonbleu commentedPatch applies cleanly:
git clone --branch 9.1.x https://git.drupalcode.org/project/drupal.git
Code is simple and makes sense.
What else is required before setting to RTBC?
Comment #5
mikelutzAgreed, this makes sense, and saves a little bit of overhead.
Comment #7
mikelutzLooks to be an unrelated test failure.
Comment #9
mikelutzditto
Comment #12
catchCommitted/pushed to 9.1.x and cherry-picked back to 8.9.x, thanks!