Skip to content

Commit

Permalink
Fix failing tests (#88)
Browse files Browse the repository at this point in the history
Travis CI support in `wp scaffold plugin` was removed in wp-cli/scaffold-command#325, so all these `.travis.yml` files no longer exist.
  • Loading branch information
swissspidy committed Dec 18, 2023
1 parent 73d568d commit e226f7d
Showing 1 changed file with 19 additions and 19 deletions.
38 changes: 19 additions & 19 deletions features/dist-archive.feature
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world`
Expand All @@ -24,7 +24,7 @@ Feature: Generate a distribution archive of a project
When I run `wp plugin install wp-content/plugins/hello-world.0.1.0.zip`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should not exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should not exist
And the wp-content/plugins/hello-world/bin directory should not exist

Scenario: Generates a tarball archive with a flag
Expand All @@ -33,7 +33,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world --format=targz`
Expand All @@ -50,7 +50,7 @@ Feature: Generate a distribution archive of a project
When I try `cd wp-content/plugins/ && tar -zxvf hello-world.0.1.0.tar.gz`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should not exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should not exist
And the wp-content/plugins/hello-world/bin directory should not exist

Scenario: Generate a ZIP archive with a custom name
Expand All @@ -59,7 +59,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world hello-world.zip`
Expand All @@ -76,7 +76,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world wp-content`
Expand All @@ -93,7 +93,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `mkdir subdir`
Expand All @@ -113,7 +113,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world {RUN_DIR}/wp-content/`
Expand Down Expand Up @@ -168,7 +168,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I try `wp dist-archive wp-content/plugins/hello-world {RUN_DIR}/some/nested/folder/hello-world.zip`
Expand All @@ -191,7 +191,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive . {RUN_DIR}/hello-world.zip` from 'wp-content/plugins/hello-world'
Expand All @@ -208,7 +208,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive . hello-world.zip` from 'wp-content/plugins/hello-world'
Expand All @@ -225,7 +225,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive . ./hello-world.zip` from 'wp-content/plugins/hello-world'
Expand All @@ -242,7 +242,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world .`
Expand All @@ -259,7 +259,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world --plugin-dirname=foobar-world`
Expand All @@ -283,7 +283,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `awk '{sub("\\* Version","Version",$0); print}' {RUN_DIR}/wp-content/plugins/hello-world/hello-world.php > hello-world.tmp && mv hello-world.tmp {RUN_DIR}/wp-content/plugins/hello-world/hello-world.php`
Expand All @@ -305,7 +305,7 @@ Feature: Generate a distribution archive of a project
When I run `wp plugin install wp-content/plugins/hello-world.0.2.0.zip`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should not exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should not exist
And the wp-content/plugins/hello-world/bin directory should not exist

# This test does not work with SQLite because it wipes wp-content
Expand Down Expand Up @@ -389,7 +389,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world --filename-format={name}-{version}`
Expand All @@ -406,7 +406,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `wp dist-archive wp-content/plugins/hello-world hello-world.zip --filename-format={name}-{version}`
Expand Down Expand Up @@ -444,7 +444,7 @@ Feature: Generate a distribution archive of a project
When I run `wp scaffold plugin hello-world`
Then the wp-content/plugins/hello-world directory should exist
And the wp-content/plugins/hello-world/hello-world.php file should exist
And the wp-content/plugins/hello-world/.travis.yml file should exist
And the wp-content/plugins/hello-world/.circleci/config.yml file should exist
And the wp-content/plugins/hello-world/bin directory should exist

When I run `mkdir subdir`
Expand Down

6 comments on commit e226f7d

@szepeviktor
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@danielbachhuber There is something wrong with the tags.
Only one file changed in v2.0.1...v3.0.0

@szepeviktor
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Could it be that v2.0.1 is not in a branch??

@BrianHenryIE
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The branch name changed from master to main — could be related ?

@szepeviktor
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@danielbachhuber
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This is weird:

CleanShot 2024-04-07 at 05 53 26@2x

I guess someone created the tag, but the release was published just now.

@BrianHenryIE
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

The tag corresponds with the last commit’s date. I don’t know that that means it wasn’t created just now.

Please sign in to comment.