diff --git a/features/export.feature b/features/export.feature index 2e0c9a98..eaea18b3 100644 --- a/features/export.feature +++ b/features/export.feature @@ -40,7 +40,7 @@ Feature: Export content. """ And the return code should be 1 - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export with post_type and post_status argument Given a WP install @@ -79,7 +79,7 @@ Feature: Export content. 10 """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export a comma-separated list of post types Given a WP install @@ -132,7 +132,7 @@ Feature: Export content. 10 """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export only one post Given a WP install @@ -203,7 +203,7 @@ Feature: Export content. 2 """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export multiple posts, separated by spaces Given a WP install @@ -236,7 +236,7 @@ Feature: Export content. 2 """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export multiple posts, separated by comma Given a WP install @@ -269,7 +269,7 @@ Feature: Export content. 2 """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export posts within a given date range Given a WP install @@ -310,7 +310,7 @@ Feature: Export content. 10 """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export posts from a given category Given a WP install And I run `wp site empty --yes` @@ -392,7 +392,7 @@ Feature: Export content. Apple Post """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export posts from a given author Given a WP install And I run `wp site empty --yes` @@ -475,7 +475,7 @@ Feature: Export content. john.doe@example.com """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export posts should include user information Given a WP install And I run `wp plugin install wordpress-importer --activate` @@ -502,7 +502,7 @@ Feature: Export content. Test User """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export posts from a given starting post ID Given a WP install @@ -520,7 +520,11 @@ Feature: Export content. 10 """ - When I run `wp export --start_id=6` + # Read the 6th post's ID instead of hardcoding --start_id=6. SQLite does not reset auto-increment on `wp site empty`, so generated IDs aren't always 1..10. + When I run `wp post list --post_type=post --orderby=ID --order=ASC --posts_per_page=1 --offset=5 --format=ids` + Then save STDOUT as {START_ID} + + When I run `wp export --start_id={START_ID}` Then save STDOUT 'Writing to file %s' as {EXPORT_FILE} When I run `wp site empty --yes` @@ -541,7 +545,7 @@ Feature: Export content. 5 """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Exclude a specific post type from export Given a WP install And I run `wp site empty --yes` @@ -604,7 +608,7 @@ Feature: Export content. 0 """ - @require-mysql + Scenario: Export posts using --max_num_posts Given a WP install And I run `wp site empty --yes` @@ -662,7 +666,7 @@ Feature: Export content. thisisaverylongsitenamethatexceedsfiftycharactersandshouldbetruncated """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export a site and skip the comments Given a WP install And I run `wp comment generate --post_id=1 --count=2` @@ -843,7 +847,7 @@ Feature: Export content. """ And STDERR should be empty - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export a site to stdout Given a WP install And I run `wp comment generate --post_id=1 --count=1` @@ -897,7 +901,7 @@ Feature: Export content. """ And the return code should be 1 - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export individual post with attachments Given a WP install And I run `wp plugin install wordpress-importer --activate` @@ -989,7 +993,7 @@ Feature: Export content. white-150-square.jpg";s: """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export categories, tags and terms Given a WP install And a wp-content/mu-plugins/register-region-taxonomy.php file: @@ -1154,7 +1158,7 @@ Feature: Export content. Europe """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export posts should not include oembed_cache posts user information Given a WP install And I run `wp plugin install wordpress-importer --activate` @@ -1186,7 +1190,7 @@ Feature: Export content. Test User """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Allow export to proceed when orphaned terms are found Given a WP install And I run `wp term create category orphan --parent=1` @@ -1241,7 +1245,7 @@ Feature: Export content. 0 """ - @require-mysql + Scenario: Throw exception when orphaned terms are found Given a WP install And I run `wp term create category orphan --parent=1` @@ -1281,7 +1285,7 @@ Feature: Export content. """ - @require-wp-5.2 @require-mysql + @require-wp-5.2 Scenario: Export posts with future status Given a WP install And I run `wp plugin install wordpress-importer --activate`