@@ -269,6 +269,10 @@ Feature: WP-CLI Commands
269269
270270 Scenario : Invalid subcommand of valid command
271271 Given an empty directory
272+ And a session_no file:
273+ """
274+ n
275+ """
272276 And a custom-cmd.php file:
273277 """
274278 <?php
@@ -285,10 +289,10 @@ Feature: WP-CLI Commands
285289 WP_CLI::add_command( 'command', 'Custom_Command_Class' );
286290 """
287291
288- When I try `wp --require=custom-cmd.php command invalid`
292+ When I try `wp --require=custom-cmd.php command invalid < session_no `
289293 Then STDERR should contain:
290294 """
291- Error : 'invalid' is not a registered subcommand of 'command'. See 'wp help command' for available subcommands.
295+ Warning : 'invalid' is not a registered subcommand of 'command'. See 'wp help command' for available subcommands.
292296 """
293297
294298 Scenario: Use a closure as a command
@@ -1149,21 +1153,25 @@ Feature: WP-CLI Commands
11491153
11501154 Scenario: WP-CLI suggests matching commands when user entry contains typos
11511155 Given a WP installation
1156+ And a session_no file:
1157+ """
1158+ n
1159+ """
11521160
1153- When I try `wp clu`
1154- Then STDERR should contain:
1161+ When I try `wp clu < session_no `
1162+ Then STDOUT should contain:
11551163 """
11561164 Did you mean 'cli' ?
11571165 """
11581166
1159- When I try `wp cli nfo`
1160- Then STDERR should contain:
1167+ When I try `wp cli nfo < session_no `
1168+ Then STDOUT should contain:
11611169 """
11621170 Did you mean 'info' ?
11631171 """
11641172
11651173 When I try `wp cli beyondlevenshteinthreshold`
1166- Then STDERR should not contain:
1174+ Then STDOUT should not contain:
11671175 """
11681176 Did you mean
11691177 """
0 commit comments