Problem/Motivation

We need to provide an upgrade path from D7 for the core Testing (SimpleTest) module.

Proposed Resolution

SimpleTest really doesn't maintain any data that needs migrating :) Variables need to be moved into configuration, but that's it.

Remaining Tasks

  1. Update the patch to match HEAD
  2. Write tests
  3. Review the patch
  4. Commit the patch

Comments

hosef’s picture

Status: Active » Needs work
Issue tags: +Needs tests
StatusFileSize
new977 bytes

Attached is the YAML for this issue, from the patch in #2382117: Migration Files for Drupal 7 Variables.
Test(s) (and maybe a dump file) still need to be written.

miguelc303’s picture

Added organization support to Anexus IT

jcost’s picture

Project: IMP » Drupal core
Version: » 8.0.x-dev
Component: Code » migration system

Will need to be submitted again to Core since moving from sandbox.

phenaproxima’s picture

Title: Variable to config: simpletest.settings [d7] » Upgrade path for Simpletest 7.x
Priority: Normal » Minor
Parent issue: #2181257: [meta] Variables to config migration [d7] » #2456259: [META] Drupal 7 to Drupal 8 Migration path

Ever drop an issue summary in a comment? It happened to me.

phenaproxima’s picture

Issue summary: View changes
phenaproxima’s picture

Status: Needs work » Needs review
Issue tags: -Needs tests
StatusFileSize
new3.7 KB

Updated and wrote a test.

phenaproxima’s picture

StatusFileSize
new3.41 KB

Re-rolled. I regret that I can't provide an interdiff, due to the conflicts in the {variable} table dump.

phenaproxima’s picture

chx’s picture

Status: Needs review » Needs work

I think we agreed before on asserting empty strings and similar defaults buys us nothing.

phenaproxima’s picture

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

Fixed. Can't include an interdiff, unfortunately, due to conflicts with the {variable} dump.

chx’s picture

Status: Needs review » Reviewed & tested by the community

Looks great.

The last submitted patch, 1: simpletest_settings-2409437-1.patch, failed testing.

  • webchick committed c1e0ba3 on 8.0.x
    Issue #2409437 by phenaproxima, hosef, mikeryan, chx, jcost: Migration...
webchick’s picture

Title: Upgrade path for Simpletest 7.x » Migration path for Simpletest 7.x
Status: Reviewed & tested by the community » Fixed

Thanks to @phenaproxima and @mikeryan for the patch walk through. I'm a little rusty on this Migrate stuff, but hoping to get better starting today. :)

+      'name' => 'simpletest_clear_results',
+      'value' => 'b:1;',
+    ))->values(array(
+      'name' => 'simpletest_httpauth_method',
+      'value' => 'i:1;',
+    ))->values(array(
+      'name' => 'simpletest_httpauth_password',
+      'value' => 's:6:"foobaz";',
+    ))->values(array(
+      'name' => 'simpletest_httpauth_username',
+      'value' => 's:7:"testbot";',
+    ))->values(array(
+      'name' => 'simpletest_verbose',
+      'value' => 'b:1;',
+    ))->values(array(

phenaproxima confirmed to me that he's gone through the module painstakingly to ensure these are all the variables that need migrating. In my cursory check that seems to be correct.

This one:

+    ))->values(array(
+      'name' => 'simpletest_httpauth_password',
+      'value' => 's:6:"foobaz";',

I called specific attention to as in "we can't possibly store the httpauth_password in plain text, can we?" It turns out, we can. :( Confirmed on a fresh 7.x database.

-#5b6552f715939e2b33c22779e47e73e3
+#029f6b476578be5d7449a86251be1c77

I had no idea wtf that was, and phenaproxima explained it's a sanity check to ensure the migrate-drupal.sh script was invoked properly. Seems like that makes it really easy for collisions/long issue dependency chains to happen. :\ Not introduced in this patch, though.

+label: Drupal 7 simpletest configuration

The nittiest of picks, but that should be SimpleTest. ;) Fixed on commit. This doesn't show up anywhere in core, but does in the full Migrate UI that's currently housed in the https://www.drupal.org/project/migrate_plus project.

+process:
+  clear_results: simpletest_clear_results
+  'httpauth/method': simpletest_httpauth_method
+  'httpauth/password': simpletest_httpauth_password
+  'httpauth/username': simpletest_httpauth_username
+  verbose: simpletest_verbose

Wasn't sure what that 'httpauth/method' stuff was about, but was explained that this is the format for arrays of config. Since method, password, and userame are all related, makes sense in the new system to store them under a single httpauth array.

Everything else in here was straight-forward, so committed and pushed to 8.0.x. Thanks! Onto the next variable-to-config migration! :D

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.