Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion composer.json
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@
},
"require-dev": {
"wp-cli/extension-command": "^1.2 || ^2 || ^3",
"wp-cli/wp-cli-tests": "^5"
"wp-cli/wp-cli-tests": "dev-builtin-directory-variables as 5.3.99"
},
"config": {
"process-timeout": 7200,
Expand Down
12 changes: 0 additions & 12 deletions features/install-wp-tests.feature
Original file line number Diff line number Diff line change
Expand Up @@ -5,8 +5,6 @@ Feature: Scaffold install-wp-tests.sh tests
@skip-windows
Scenario: Help should be displayed
Given a WP install
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}
And I run `wp scaffold plugin hello-world`

When I try `/usr/bin/env bash {PLUGIN_DIR}/hello-world/bin/install-wp-tests.sh`
Expand Down Expand Up @@ -48,8 +46,6 @@ Feature: Scaffold install-wp-tests.sh tests
And I run `wp eval-file get-phpunit-phar-url.php --skip-wordpress`
And save STDOUT as {PHPUNIT_PHAR_URL}
And I run `curl -sS -L --fail -o phpunit {PHPUNIT_PHAR_URL}`
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}
And I run `wp scaffold plugin hello-world`
# This throws a warning for the password provided via command line.
And I try `mysql -u{DB_USER} -p{DB_PASSWORD} -h{MYSQL_HOST} -P{MYSQL_PORT} --protocol=tcp -e "DROP DATABASE IF EXISTS wp_cli_test_scaffold"`
Expand Down Expand Up @@ -166,8 +162,6 @@ Feature: Scaffold install-wp-tests.sh tests
And I run `wp eval-file get-phpunit-phar-url.php --skip-wordpress`
And save STDOUT as {PHPUNIT_PHAR_URL}
And I run `curl -sS --fail -L -o phpunit {PHPUNIT_PHAR_URL}`
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}
And I run `wp scaffold plugin hello-world`
# This throws a warning for the password provided via command line.
And I try `mysql -u{DB_USER} -p{DB_PASSWORD} -h{MYSQL_HOST} -P{MYSQL_PORT} --protocol=tcp -e "DROP DATABASE IF EXISTS wp_cli_test_scaffold"`
Expand Down Expand Up @@ -296,8 +290,6 @@ Feature: Scaffold install-wp-tests.sh tests
And I run `wp eval-file get-phpunit-phar-url.php --skip-wordpress`
And save STDOUT as {PHPUNIT_PHAR_URL}
And I run `curl -sS -L --fail -o phpunit {PHPUNIT_PHAR_URL}`
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}
And I run `wp scaffold plugin hello-world`
# This throws a warning for the password provided via command line.
And I try `mysql -u{DB_USER} -p{DB_PASSWORD} -h{MYSQL_HOST} -P{MYSQL_PORT} --protocol=tcp -e "DROP DATABASE IF EXISTS wp_cli_test_scaffold"`
Expand Down Expand Up @@ -406,8 +398,6 @@ Feature: Scaffold install-wp-tests.sh tests
And I run `wp eval-file get-phpunit-phar-url.php --skip-wordpress`
And save STDOUT as {PHPUNIT_PHAR_URL}
And I run `curl -sS -f -L -o phpunit {PHPUNIT_PHAR_URL}`
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}
And I run `wp scaffold plugin hello-world`
# This throws a warning for the password provided via command line.
And I try `mysql -u{DB_USER} -p{DB_PASSWORD} -h{MYSQL_HOST} -P{MYSQL_PORT} --protocol=tcp -e "DROP DATABASE IF EXISTS wp_cli_test_scaffold"`
Expand Down Expand Up @@ -486,8 +476,6 @@ Feature: Scaffold install-wp-tests.sh tests
@require-mysql
Scenario: Install WordPress 3.7 and phpunit will not run
Given a WP install
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}
And I run `wp scaffold plugin hello-world`
# This throws a warning for the password provided via command line.
And I try `mysql -u{DB_USER} -p{DB_PASSWORD} -h{MYSQL_HOST} -P{MYSQL_PORT} --protocol=tcp -e "DROP DATABASE IF EXISTS wp_cli_test_scaffold"`
Expand Down
4 changes: 0 additions & 4 deletions features/scaffold-lint.feature
Original file line number Diff line number Diff line change
Expand Up @@ -2,8 +2,6 @@ Feature: Lint scaffolded code

Background:
Given a WP install
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}

# Create a helper plugin to install phpcs once for all scenarios
When I run `wp scaffold plugin phpcs-helper --skip-tests`
Expand Down Expand Up @@ -62,8 +60,6 @@ Feature: Lint scaffolded code

Scenario: Scaffold child theme and lint it
When I run `wp theme install twentytwentyone --force --activate`
And I run `wp theme path`
And save STDOUT as {THEME_DIR}

And I run `wp scaffold child-theme test-child --parent_theme=twentytwentyone`
Then STDOUT should not be empty
Expand Down
4 changes: 0 additions & 4 deletions features/scaffold-plugin-tests.feature
Original file line number Diff line number Diff line change
Expand Up @@ -4,8 +4,6 @@ Feature: Scaffold plugin unit tests
@skip-windows
Scenario: Scaffold plugin tests
Given a WP install
When I run `wp plugin path`
Then save STDOUT as {PLUGIN_DIR}

When I run `wp scaffold plugin hello-world --skip-tests`
Then STDOUT should not be empty
Expand Down Expand Up @@ -342,8 +340,6 @@ Feature: Scaffold plugin unit tests

Scenario: Accept bitbucket as valid CI in plugin scaffold
Given a WP install
When I run `wp plugin path`
Then save STDOUT as {PLUGIN_DIR}

When I run `wp scaffold plugin hello-world --ci=bitbucket`
Then STDOUT should not be empty
Expand Down
3 changes: 0 additions & 3 deletions features/scaffold-theme-tests.feature
Original file line number Diff line number Diff line change
Expand Up @@ -5,9 +5,6 @@ Feature: Scaffold theme unit tests
And I try `wp theme install twentytwelve --force`
And I run `wp scaffold child-theme t12child --parent_theme=twentytwelve`

When I run `wp theme path`
Then save STDOUT as {THEME_DIR}

@require-php-7.4 @require-mysql
Scenario: Scaffold theme tests
When I run `wp scaffold theme-tests t12child`
Expand Down
19 changes: 0 additions & 19 deletions features/scaffold.feature
Original file line number Diff line number Diff line change
Expand Up @@ -3,8 +3,6 @@ Feature: WordPress code scaffolding
@theme
Scenario: Scaffold a child theme
Given a WP install
And I run `wp theme path`
And save STDOUT as {THEME_DIR}

When I run `wp scaffold child-theme zombieland --parent_theme=umbrella --theme_name=Zombieland --author=Tallahassee --author_uri=https://wp-cli.org --theme_uri=http://www.zombieland.com`
Then the {THEME_DIR}/zombieland/style.css file should exist
Expand All @@ -21,8 +19,6 @@ Feature: WordPress code scaffolding

Scenario: Scaffold a child theme with only --parent_theme parameter
Given a WP install
And I run `wp theme path`
And save STDOUT as {THEME_DIR}

When I run `wp scaffold child-theme hello-world --parent_theme=simple-life`
Then STDOUT should not be empty
Expand Down Expand Up @@ -68,9 +64,6 @@ Feature: WordPress code scaffolding
When I run `wp theme install twentytwentyone --force`
Then STDOUT should not be empty

And I run `wp theme path`
And save STDOUT as {THEME_DIR}

When I run `wp scaffold child-theme first-run --parent_theme=twentytwentyone --theme_name="First Run Name" --activate`
Then STDOUT should contain:
"""
Expand Down Expand Up @@ -129,8 +122,6 @@ Feature: WordPress code scaffolding
@theme
Scenario: Scaffold a child theme with dots in the slug
Given a WP install
And I run `wp theme path`
And save STDOUT as {THEME_DIR}

When I run `wp scaffold child-theme my-theme-2.0.1 --parent_theme=umbrella`
Then the {THEME_DIR}/my-theme-2.0.1/functions.php file should exist
Expand Down Expand Up @@ -267,8 +258,6 @@ Feature: WordPress code scaffolding

Scenario: Scaffold a plugin
Given a WP install
And I run `wp plugin path`
And save STDOUT as {PLUGIN_DIR}
And I run `wp core version`
And save STDOUT as {WP_VERSION}

Expand Down Expand Up @@ -403,8 +392,6 @@ Feature: WordPress code scaffolding
@require-php-5.6 @require-wp-4.6
Scenario: Scaffold starter code for a theme
Given a WP install
And I run `wp theme path`
And save STDOUT as {THEME_DIR}

# Allow for warnings to be generated due to https://github.com/wp-cli/scaffold-command/issues/181
When I try `wp scaffold _s starter-theme`
Expand All @@ -418,8 +405,6 @@ Feature: WordPress code scaffolding
@require-php-5.6 @require-wp-4.6
Scenario: Scaffold starter code for a theme with sass
Given a WP install
And I run `wp theme path`
And save STDOUT as {THEME_DIR}

# Allow for warnings to be generated due to https://github.com/wp-cli/scaffold-command/issues/181
When I try `wp scaffold _s starter-theme --sassify`
Expand All @@ -432,8 +417,6 @@ Feature: WordPress code scaffolding
@require-php-5.6 @require-wp-4.6
Scenario: Scaffold starter code for a WooCommerce theme
Given a WP install
And I run `wp theme path`
And save STDOUT as {THEME_DIR}

# Allow for warnings to be generated due to https://github.com/wp-cli/scaffold-command/issues/181
When I try `wp scaffold _s starter-theme --woocommerce`
Expand Down Expand Up @@ -532,8 +515,6 @@ Feature: WordPress code scaffolding
Given a WP install
When I run `wp core version`
Then save STDOUT as {WP_VERSION}
When I run `wp plugin path`
Then save STDOUT as {PLUGIN_DIR}

When I run `wp scaffold plugin hello-world`
Then STDOUT should not be empty
Expand Down
Loading