Problem/Motivation

The Migrate UI was introduced to with only basic tests added in #2647470: Write tests. And no tests for the rollback feature.

Proposed resolution

Add tests for the rollback feature.

Remaining tasks

User interface changes

None

API changes

None

Data model changes

None

Comments

xjm created an issue. See original summary.

Status: Needs review » Needs work

The last submitted patch, rollback-tests.patch, failed testing.

abhishek-anand’s picture

StatusFileSize
new2.3 KB
new879 bytes

Adding a small change.

The tests are failing because the rollback itself is not clean. Also the following error is also present in the watchdog while doing the rollback manually.

exception: [Warning] Line 232 of core/lib/Drupal/Core/Entity/EntityStorageBase.php:
array_flip(): Can only flip STRING and INTEGER values!

This appears to be a bug with the migrate module itself.

Debugging it further.

xjm’s picture

Project: Migrate Upgrade » Drupal core
Version: 8.x-1.x-dev » 8.1.x-dev
Component: Code » migration system

Version: 8.1.x-dev » 8.2.x-dev

Drupal 8.1.0-beta1 was released on March 2, 2016, which means new developments and disruptive changes should now be targeted against the 8.2.x-dev branch. For more information see the Drupal 8 minor version schedule and the Allowed changes during the Drupal 8 release cycle.

alexpott’s picture

Version: 8.2.x-dev » 8.1.x-dev

This needs to happen asap.

alexpott’s picture

Status: Needs work » Needs review
StatusFileSize
new3.2 KB

Re-rolled for core and fixing a problem that happens when a migration has failed and is marked as so...

Whilst Drupal\migrate_drupal_ui\Tests\d6\MigrateUpgrade6Test running field_test_phone fails... and then rolling it back without this patch is problematic.

+------------------------------------------------------------------+----------------------------------+---------+----------------------------------+-------------------+-----------------+---------------+------+
| source_ids_hash                                                  | sourceid1                        | destid1 | destid2                          | source_row_status | rollback_action | last_imported | hash |
+------------------------------------------------------------------+----------------------------------+---------+----------------------------------+-------------------+-----------------+---------------+------+
| 083571826d1529ac6c11ada1990b89793c6f1d5d917afcd5952a79e63ce771de | field_test_three                 | node    | field_test_three                 |                 0 |               0 |             0 |      |
| 0bbd2cb3bdd8f42575a24ba2e8a8ac774a70099ac798f47b5cf3ffd4183b148d | field_test_two                   | node    | field_test_two                   |                 0 |               0 |             0 |      |
| 0c92025b1752e9eb2bf33d8fb60e2255c6a397ad5704c462efacc7656986a54c | field_test_exclude_unset         | node    | field_test_exclude_unset         |                 0 |               0 |             0 |      |
| 118aedab42ce4ca69f70d5f330fb46d68cd2dff853f8f0657e59e24be231677f | field_test_link                  | node    | field_test_link                  |                 0 |               0 |             0 |      |
| 2d56cd0c02fdf2d4e6bf646f4242ef610a36eb516e5ec581e19d7226076cce1e | field_test_phone                 | NULL    | NULL                             |                 3 |               0 |             0 |      |
| 3cc00c4d5095800f1027a9f1174c55b74ab8da31bd3db5b11501d64bcd40f5cd | field_test_text_single_checkbox  | node    | field_test_text_single_checkbox  |                 0 |               0 |             0 |      |
| 4039c6e968de126fd7fd9e0c1c285f413a264726d8d1342c89047618d07224bb | field_test_float_single_checkbox | node    | field_test_float_single_checkbox |                 0 |               0 |             0 |      |
| 42a2c22c7b701a57c57ea83686c4c401c1c291fa31fc7d7cad9dd47ea6749648 | field_multivalue                 | node    | field_multivalue                 |                 0 |               0 |             0 |      |
| 6b90cb0c8fa2c3442ff26ba40d368292ac75c945786c4a8214d87bfcc72eca49 | field_test_datestamp             | node    | field_test_datestamp             |                 0 |               0 |             0 |      |
| 6f49fc7bc561b25f173b936a88865235d75487eec2e04b1d0c3f3b04b0eeb28a | field_test_datetime              | node    | field_test_datetime              |                 0 |               0 |             0 |      |
| 735cecdbd545a4314f8e71cc5f1ba9293a249c087535ca4de5874e4761ba93ad | field_test_email                 | node    | field_test_email                 |                 0 |               0 |             0 |      |
| 80da953fccb58a20fe92dbc600bc69d1e5c97425bbd125a7373c435f30d11c39 | field_test_filefield             | node    | field_test_filefield             |                 0 |               0 |             0 |      |
| 892bab3a818b518379c0017fa215325df61e0aa5862f8135655fa5625799330b | field_test_date                  | node    | field_test_date                  |                 0 |               0 |             0 |      |
| 8ac85be3b972469a1d902203d13db2de18338eda9ee4ddd4ea2f9eb93cf3da10 | field_test_text_single_checkbox2 | node    | field_test_text_single_checkbox2 |                 0 |               0 |             0 |      |
| 8b9dd3d89855fbf69149a905f142a5c773a81e097a54428b008102b44e1f411f | field_test_integer_selectlist    | node    | field_test_integer_selectlist    |                 0 |               0 |             0 |      |
| 9a6911936b9b32570e8f6c709a3022676e5aee516d2c034e05c4ac5cb8ba141d | field_test                       | node    | field_test                       |                 0 |               0 |             0 |      |
| aa73636ec55e89cdca4d2d2c5a0c1914a2f459f39707b4b1f007ce22443e88cd | field_test_four                  | node    | field_test_four                  |                 0 |               0 |             0 |      |
| ae44c68d140122b51966d69fa7ccb4a5bfcd46da4eb85891c018fb2f5278a276 | field_test_imagefield            | node    | field_test_imagefield            |                 0 |               0 |             0 |      |
| d042e1e3accdca9b6a22d6db2d99e02401e8bae17418a87314199f0dda053b1e | field_test_decimal_radio_buttons | node    | field_test_decimal_radio_buttons |                 0 |               0 |             0 |      |
| d651a35f521119809933bc8b8eeebcc35d9226284883a568ba0edd2dcbe0a84c | field_test_identical1            | node    | field_test_identical1            |                 0 |               0 |             0 |      |
| e89f7ca0acabecfef820a4643097feda36d0bc4f9ae4ac4eafee0fd195095ce6 | field_test_identical2            | node    | field_test_identical2            |                 0 |               0 |             0 |      |
+------------------------------------------------------------------+----------------------------------+---------+----------------------------------+-------------------+-----------------+---------------+------+

Status: Needs review » Needs work

The last submitted patch, 7: 2678994-7.patch, failed testing.

alexpott’s picture

Issue summary: View changes
benjy’s picture

mikeryan’s picture

Status: Needs work » Closed (duplicate)

Rollback was removed from the UI, and tests are part of the issue to reinstate them: #2687849: Add back rollbacks on migrate_drupal_ui.