Skip to content

Commit 6d7b349

Browse files
committed
Update some tests for Windows
1 parent aa9f5fe commit 6d7b349

2 files changed

Lines changed: 5 additions & 5 deletions

File tree

features/package-install.feature

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -1374,11 +1374,11 @@ Feature: Install WP-CLI packages
13741374
"""
13751375
And STDOUT should be empty
13761376
1377-
When I try `wp package install https://example.com/non-existent-zip-asdfasdf.zip`
1377+
When I try `wp package install http://example.com/non-existent-zip-asdfasdf.zip`
13781378
Then the return code should be 1
13791379
And STDERR should contain:
13801380
"""
1381-
Error: Couldn't download package from 'https://example.com/non-existent-zip-asdfasdf.zip'
1381+
Error: Couldn't download package from 'http://example.com/non-existent-zip-asdfasdf.zip'
13821382
"""
13831383
And STDOUT should be empty
13841384

features/package-update.feature

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -62,7 +62,7 @@ Feature: Update WP-CLI packages
6262
| name | update |
6363
| wp-cli-test/updateable-package | available |
6464

65-
When I run `sed -i.bak s/v1.0.0/\>=1.0.0/g {PACKAGE_PATH}/composer.json`
65+
When I run `wp eval "file_put_contents( '{PACKAGE_PATH}composer.json', str_replace( 'v1.0.0', '>=1.0.0', file_get_contents( '{PACKAGE_PATH}composer.json' ) ) );" --skip-wordpress`
6666
Then the return code should be 0
6767

6868
When I run `cat {PACKAGE_PATH}/composer.json`
@@ -114,7 +114,7 @@ Feature: Update WP-CLI packages
114114
Success: Package installed.
115115
"""
116116

117-
When I run `sed -i.bak s/v1.0.0/\>=1.0.0/g {PACKAGE_PATH}/composer.json`
117+
When I run `wp eval "file_put_contents( '{PACKAGE_PATH}composer.json', str_replace( 'v1.0.0', '>=1.0.0', file_get_contents( '{PACKAGE_PATH}composer.json' ) ) );" --skip-wordpress`
118118
Then the return code should be 0
119119

120120
When I run `wp package update wp-cli-test/updateable-package`
@@ -147,7 +147,7 @@ Feature: Update WP-CLI packages
147147
Success: Package installed.
148148
"""
149149

150-
When I run `sed -i.bak s/v1.0.0/\>=1.0.0/g {PACKAGE_PATH}/composer.json`
150+
When I run `wp eval "file_put_contents( '{PACKAGE_PATH}composer.json', str_replace( 'v1.0.0', '>=1.0.0', file_get_contents( '{PACKAGE_PATH}composer.json' ) ) );" --skip-wordpress`
151151
Then the return code should be 0
152152

153153
When I run `wp package update wp-cli-test/updateable-package danielbachhuber/wp-cli-reset-post-date-command`

0 commit comments

Comments
 (0)