@@ -53,6 +53,48 @@ Feature: Update WordPress core
5353 [{"name":"core","old_version":"6.0","new_version":"6.1","status":"Updated"}]
5454 """
5555
56+ @require-php-7.0
57+ Scenario : Output in CSV format
58+ Given a WP install
59+ And I try `wp theme install twentytwenty --activate`
60+
61+ When I run `wp core download --version=6.0 --force`
62+ Then STDOUT should not be empty
63+
64+ When I run `wp eval 'echo $GLOBALS["wp_version"];' `
65+ Then STDOUT should be:
66+ """
67+ 6.0
68+ """
69+
70+ When I run `wget http://wordpress.org/wordpress-6.1.zip --quiet`
71+ And I run `wp core update wordpress-6.1.zip --format=csv`
72+ Then STDOUT should be:
73+ """
74+ name,old_version,new_version,status
75+ core,6.0,6.1,Updated
76+ """
77+
78+ @require-php-7.0
79+ Scenario : Output in table format
80+ Given a WP install
81+ And I try `wp theme install twentytwenty --activate`
82+
83+ When I run `wp core download --version=6.0 --force`
84+ Then STDOUT should not be empty
85+
86+ When I run `wp eval 'echo $GLOBALS["wp_version"];' `
87+ Then STDOUT should be:
88+ """
89+ 6.0
90+ """
91+
92+ When I run `wget http://wordpress.org/wordpress-6.1.zip --quiet`
93+ And I run `wp core update wordpress-6.1.zip --format=table`
94+ Then STDOUT should be a table containing rows:
95+ | name | old_version | new_version | status |
96+ | core | 6 .0 | 6 .1 | Updated |
97+
5698 # PHP 7.1 needs WP 3.9 (due to wp_check_php_mysql_versions(), see trac changeset [27257]),
5799 # and travis doesn't install mysql extension by default for PHP 7.0.
58100 @less-than-php-7
0 commit comments