OSDN Git Service

Add a dry run test to make sure the iterator doesn't depend on updates.
authorDylan Kuhn <dylan.k.kuhn@gmail.com>
Wed, 29 May 2013 04:46:44 +0000 (21:46 -0700)
committerDylan Kuhn <dylan.k.kuhn@gmail.com>
Wed, 29 May 2013 04:46:44 +0000 (21:46 -0700)
features/search-replace.feature

index 3c3b2ce..3cf524d 100644 (file)
@@ -45,3 +45,19 @@ Feature: Do global search/replace
     Table      Column  Replacements
     wp_posts   guid    1002
     """
+
+  Scenario: Large guid search/replace dry run where replacement does not contain search
+    Given a WP install
+
+    When I run `wp option get siteurl`
+
+    And save STDOUT as {SITEURL}
+
+    And I run `wp post generate --count=1000`
+
+    And I run `wp search-replace --dry-run {SITEURL} http://newdomain.com`
+    Then STDOUT should be a table containing rows:
+    """
+    Table      Column  Replacements
+    wp_posts   guid    1002
+    """