forked from wp-cli/wp-cli
-
Notifications
You must be signed in to change notification settings - Fork 0
/
command.feature
1523 lines (1329 loc) · 36.9 KB
/
command.feature
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
143
144
145
146
147
148
149
150
151
152
153
154
155
156
157
158
159
160
161
162
163
164
165
166
167
168
169
170
171
172
173
174
175
176
177
178
179
180
181
182
183
184
185
186
187
188
189
190
191
192
193
194
195
196
197
198
199
200
201
202
203
204
205
206
207
208
209
210
211
212
213
214
215
216
217
218
219
220
221
222
223
224
225
226
227
228
229
230
231
232
233
234
235
236
237
238
239
240
241
242
243
244
245
246
247
248
249
250
251
252
253
254
255
256
257
258
259
260
261
262
263
264
265
266
267
268
269
270
271
272
273
274
275
276
277
278
279
280
281
282
283
284
285
286
287
288
289
290
291
292
293
294
295
296
297
298
299
300
301
302
303
304
305
306
307
308
309
310
311
312
313
314
315
316
317
318
319
320
321
322
323
324
325
326
327
328
329
330
331
332
333
334
335
336
337
338
339
340
341
342
343
344
345
346
347
348
349
350
351
352
353
354
355
356
357
358
359
360
361
362
363
364
365
366
367
368
369
370
371
372
373
374
375
376
377
378
379
380
381
382
383
384
385
386
387
388
389
390
391
392
393
394
395
396
397
398
399
400
401
402
403
404
405
406
407
408
409
410
411
412
413
414
415
416
417
418
419
420
421
422
423
424
425
426
427
428
429
430
431
432
433
434
435
436
437
438
439
440
441
442
443
444
445
446
447
448
449
450
451
452
453
454
455
456
457
458
459
460
461
462
463
464
465
466
467
468
469
470
471
472
473
474
475
476
477
478
479
480
481
482
483
484
485
486
487
488
489
490
491
492
493
494
495
496
497
498
499
500
501
502
503
504
505
506
507
508
509
510
511
512
513
514
515
516
517
518
519
520
521
522
523
524
525
526
527
528
529
530
531
532
533
534
535
536
537
538
539
540
541
542
543
544
545
546
547
548
549
550
551
552
553
554
555
556
557
558
559
560
561
562
563
564
565
566
567
568
569
570
571
572
573
574
575
576
577
578
579
580
581
582
583
584
585
586
587
588
589
590
591
592
593
863
595
596
597
598
599
600
601
602
603
604
605
606
607
608
609
610
611
612
613
614
615
616
617
618
619
620
621
622
623
624
625
626
627
628
629
630
631
632
633
634
635
636
637
638
639
640
641
642
643
644
645
646
647
648
649
650
651
652
653
654
655
656
657
658
659
660
661
662
663
664
665
666
667
668
669
670
671
672
673
674
675
676
677
678
679
680
681
682
683
684
685
686
687
688
689
690
691
692
693
694
695
696
697
698
699
700
701
702
703
704
705
706
707
708
709
710
711
712
713
714
715
716
717
718
719
720
721
722
723
724
725
726
727
728
729
730
731
732
733
734
735
736
737
738
739
740
741
742
743
744
745
746
747
748
749
750
751
752
753
754
755
756
757
758
759
760
761
762
763
764
765
766
767
768
769
770
771
772
773
774
775
776
777
778
779
780
781
782
783
784
785
786
787
788
789
790
791
792
793
794
795
796
797
798
799
800
801
802
803
804
805
806
807
808
809
810
811
812
813
814
815
816
817
818
819
820
821
822
823
824
825
826
827
828
829
830
831
832
833
834
835
836
837
838
839
840
841
842
843
844
845
846
847
848
849
850
851
852
853
854
855
856
857
858
859
860
861
862
863
864
865
866
867
868
869
870
871
872
873
874
875
876
877
878
879
880
881
882
883
884
885
886
887
888
889
890
891
892
893
894
895
896
897
898
899
900
901
902
903
904
905
906
907
908
909
910
911
912
913
914
915
916
917
918
919
920
921
922
923
924
925
926
927
928
929
930
931
932
933
934
935
936
937
938
939
940
941
942
943
944
945
946
947
948
949
950
951
952
953
954
955
956
957
958
959
960
961
962
963
964
965
966
967
968
969
970
971
972
973
974
975
976
977
978
979
980
981
982
983
984
985
986
987
988
989
990
991
992
993
994
995
996
997
998
999
1000
Feature: WP-CLI Commands
Scenario: Registered WP-CLI commands
Given an empty directory
When I run `wp help --help`
Then STDOUT should contain:
"""
wp help [<command>...]
"""
Scenario: Invalid class is specified for a command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
WP_CLI::add_command( 'command example', 'Non_Existent_Class' );
"""
When I try `wp --require=custom-cmd.php help`
Then the return code should be 1
And STDERR should contain:
"""
Callable "Non_Existent_Class" does not exist, and cannot be registered as `wp command example`.
"""
Scenario: Invalid subcommand of valid command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
/**
* @when before_wp_load
*/
class Custom_Command_Class extends WP_CLI_Command {
public function valid() {
WP_CLI::success( 'Hello world' );
}
}
WP_CLI::add_command( 'command', 'Custom_Command_Class' );
"""
When I try `wp --require=custom-cmd.php command invalid`
Then STDERR should contain:
"""
Error: 'invalid' is not a registered subcommand of 'command'. See 'wp help command' for available subcommands.
"""
Scenario: Use a closure as a command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
/**
* My awesome closure command
*
* <message>
* : An awesome message to display
*
* @when before_wp_load
*/
$foo = function( $args ) {
WP_CLI::success( $args[0] );
};
WP_CLI::add_command( 'foo', $foo );
"""
When I run `wp --require=custom-cmd.php help`
Then STDOUT should contain:
"""
foo
"""
When I run `wp --require=custom-cmd.php help foo`
Then STDOUT should contain:
"""
My awesome closure command
"""
When I try `wp --require=custom-cmd.php foo bar --burrito`
Then STDERR should contain:
"""
unknown --burrito parameter
"""
When I run `wp --require=custom-cmd.php foo bar`
Then STDOUT should contain:
"""
Success: bar
"""
Scenario: Use a function as a command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
/**
* My awesome function command
*
* <message>
* : An awesome message to display
*
* @when before_wp_load
*/
function foo( $args ) {
WP_CLI::success( $args[0] );
}
WP_CLI::add_command( 'foo', 'foo' );
"""
When I run `wp --require=custom-cmd.php help`
Then STDOUT should contain:
"""
foo
"""
When I run `wp --require=custom-cmd.php help foo`
Then STDOUT should contain:
"""
My awesome function command
"""
When I try `wp --require=custom-cmd.php foo bar --burrito`
Then STDERR should contain:
"""
unknown --burrito parameter
"""
When I run `wp --require=custom-cmd.php foo bar`
Then STDOUT should contain:
"""
Success: bar
"""
Scenario: Use a class method as a command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
class Foo_Class extends WP_CLI_Command {
public function __construct( $prefix ) {
$this->prefix = $prefix;
}
/**
* My awesome class method command
*
* <message>
* : An awesome message to display
*
* @when before_wp_load
*/
function foo( $args ) {
WP_CLI::success( $this->prefix . ':' . $args[0] );
}
}
$foo = new Foo_Class( 'boo' );
WP_CLI::add_command( 'foo', array( $foo, 'foo' ) );
"""
When I run `wp --require=custom-cmd.php help`
Then STDOUT should contain:
"""
foo
"""
When I run `wp --require=custom-cmd.php help foo`
Then STDOUT should contain:
"""
My awesome class method command
"""
When I try `wp --require=custom-cmd.php foo bar --burrito`
Then STDERR should contain:
"""
unknown --burrito parameter
"""
When I run `wp --require=custom-cmd.php foo bar`
Then STDOUT should contain:
"""
Success: boo:bar
"""
Scenario: Use a class method as a command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
class Foo_Class extends WP_CLI_Command {
/**
* My awesome class method command
*
* <message>
* : An awesome message to display
*
* @when before_wp_load
*/
function foo( $args ) {
WP_CLI::success( $args[0] );
}
}
WP_CLI::add_command( 'foo', array( 'Foo_Class', 'foo' ) );
"""
When I run `wp --require=custom-cmd.php help`
Then STDOUT should contain:
"""
foo
"""
When I run `wp --require=custom-cmd.php help foo`
Then STDOUT should contain:
"""
My awesome class method command
"""
When I try `wp --require=custom-cmd.php foo bar --burrito`
Then STDERR should contain:
"""
unknown --burrito parameter
"""
When I run `wp --require=custom-cmd.php foo bar`
Then STDOUT should contain:
"""
Success: bar
"""
Scenario: Use class with __invoke() passed as object
Given an empty directory
And a custom-cmd.php file:
"""
<?php
class Foo_Class {
public function __construct( $message ) {
$this->message = $message;
}
/**
* My awesome class method command
*
* @when before_wp_load
*/
function __invoke( $args ) {
WP_CLI::success( $this->message );
}
}
$foo = new Foo_Class( 'bar' );
WP_CLI::add_command( 'instantiated-command', $foo );
"""
When I run `wp --require=custom-cmd.php instantiated-command`
Then STDOUT should contain:
"""
bar
"""
And STDERR should be empty
Scenario: Use an invalid class method as a command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
class Foo_Class extends WP_CLI_Command {
/**
* My awesome class method command
*
* <message>
* : An awesome message to display
*
* @when before_wp_load
*/
function foo( $args ) {
WP_CLI::success( $args[0] );
}
}
$foo = new Foo_Class;
WP_CLI::add_command( 'bar', array( $foo, 'bar' ) );
"""
When I try `wp --require=custom-cmd.php bar`
Then STDERR should contain:
"""
Error: Callable ["Foo_Class","bar"] does not exist, and cannot be registered as `wp bar`.
"""
Scenario: Register a synopsis for a given command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
function foo( $args, $assoc_args ) {
$message = array_shift( $args );
WP_CLI::log( 'Message is: ' . $message );
WP_CLI::success( $assoc_args['meal'] );
}
WP_CLI::add_command( 'foo', 'foo', array(
'shortdesc' => 'My awesome function command',
'when' => 'before_wp_load',
'synopsis' => array(
array(
'type' => 'positional',
'name' => 'message',
'description' => 'An awesome message to display',
'optional' => false,
'options' => array( 'hello', 'goodbye' ),
),
array(
'type' => 'assoc',
'name' => 'apple',
'description' => 'A type of fruit.',
'optional' => false,
),
array(
'type' => 'assoc',
'name' => 'meal',
'description' => 'A type of meal.',
'optional' => true,
'default' => 'breakfast',
'options' => array( 'breakfast', 'lunch', 'dinner' ),
),
),
) );
"""
And a wp-cli.yml file:
"""
require:
- custom-cmd.php
"""
When I try `wp foo`
Then STDOUT should contain:
"""
usage: wp foo <message> --apple=<apple> [--meal=<meal>]
"""
And STDERR should be empty
And the return code should be 1
When I run `wp help foo`
Then STDOUT should contain:
"""
My awesome function command
"""
And STDOUT should contain:
"""
SYNOPSIS
"""
And STDOUT should contain:
"""
wp foo <message> --apple=<apple> [--meal=<meal>]
"""
And STDOUT should contain:
"""
OPTIONS
"""
And STDOUT should contain:
"""
<message>
An awesome message to display
---
options:
- hello
- goodbye
---
"""
And STDOUT should contain:
"""
[--meal=<meal>]
A type of meal.
---
default: breakfast
options:
- breakfast
- lunch
- dinner
---
"""
When I try `wp foo nana --apple=fuji`
Then STDERR should contain:
"""
Error: Invalid value specified for positional arg.
"""
When I try `wp foo hello --apple=fuji --meal=snack`
Then STDERR should contain:
"""
Invalid value specified for 'meal' (A type of meal.)
"""
When I try `wp foo hello --apple=fuji --meal=breakfast,lunch,dinner`
Then STDERR should be empty
When I try `wp foo hello --apple=fuji --meal=breakfast,snack,dinner`
Then STDERR should contain:
"""
Invalid value specified for 'meal' (A type of meal.)
"""
When I run `wp foo hello --apple=fuji`
Then STDOUT should be:
"""
Message is: hello
Success: breakfast
"""
When I run `wp foo hello --apple=fuji --meal=dinner`
Then STDOUT should be:
"""
Message is: hello
Success: dinner
"""
Scenario: Register a synopsis that supports multiple positional arguments
Given an empty directory
And a test-cmd.php file:
"""
<?php
WP_CLI::add_command( 'foo', function( $args ){
WP_CLI::log( count( $args ) );
}, array(
'when' => 'before_wp_load',
'synopsis' => array(
array(
'type' => 'positional',
'name' => 'arg',
'repeating' => true,
),
),
));
"""
And a wp-cli.yml file:
"""
require:
- test-cmd.php
"""
When I run `wp foo bar`
Then STDOUT should be:
"""
1
"""
When I run `wp foo bar burrito`
Then STDOUT should be:
"""
2
"""
Scenario: Register a synopsis that requires a flag
Given an empty directory
And a test-cmd.php file:
"""
<?php
WP_CLI::add_command( 'foo', function( $_, $assoc_args ){
WP_CLI::log( \WP_CLI\Utils\get_flag_value( $assoc_args, 'honk' ) ? 'honked' : 'nohonk' );
}, array(
'when' => 'before_wp_load',
'synopsis' => array(
array(
'type' => 'flag',
'name' => 'honk',
'optional' => true,
),
),
));
"""
And a wp-cli.yml file:
"""
require:
- test-cmd.php
"""
When I run `wp foo`
Then STDOUT should be:
"""
nohonk
"""
When I run `wp foo --honk`
Then STDOUT should be:
"""
honked
"""
When I run `wp foo --honk=1`
Then STDOUT should be:
"""
honked
"""
When I run `wp foo --no-honk`
Then STDOUT should be:
"""
nohonk
"""
When I run `wp foo --honk=0`
Then STDOUT should be:
"""
nohonk
"""
# Note treats "false" as true.
When I run `wp foo --honk=false`
Then STDOUT should be:
"""
honked
"""
Scenario: Register a longdesc for a given command
Given an empty directory
And a custom-cmd.php file:
"""
<?php
function foo() {
WP_CLI::success( 'Command run.' );
}
WP_CLI::add_command( 'foo', 'foo', array(
'shortdesc' => 'My awesome function command',
'when' => 'before_wp_load',
'longdesc' => '## EXAMPLES' . PHP_EOL . PHP_EOL . ' # Run the custom foo command',
) );
"""
And a wp-cli.yml file:
"""
require:
- custom-cmd.php
"""
When I run `wp help foo`
Then STDOUT should contain:
"""
NAME
wp foo
DESCRIPTION
My awesome function command
SYNOPSIS
wp foo
EXAMPLES
# Run the custom foo command
GLOBAL PARAMETERS
"""
# With synopsis, appended.
Given a hello-command.php file:
"""
<?php
$hello_command = function( $args, $assoc_args ) {
list( $name ) = $args;
$type = $assoc_args['type'];
WP_CLI::$type( "Hello, $name!" );
if ( isset( $assoc_args['honk'] ) ) {
WP_CLI::log( 'Honk!' );
}
};
WP_CLI::add_command( 'example hello', $hello_command, array(
'shortdesc' => 'Prints a greeting.',
'synopsis' => array(
array(
'type' => 'positional',
'name' => 'name',
'description' => 'Name of person to greet.',
'optional' => false,
'repeating' => false,
),
array(
'type' => 'assoc',
'name' => 'type',
'optional' => true,
'default' => 'success',
'options' => array( 'success', 'error' ),
),
array(
'type' => 'flag',
'name' => 'honk',
'optional' => true,
),
),
'when' => 'after_wp_load',
'longdesc' => "\r\n## EXAMPLES\n\n# Say hello to Newman\nwp example hello Newman\nSuccess: Hello, Newman!",
) );
"""
When I run `wp --require=hello-command.php help example hello`
Then STDOUT should contain:
"""
NAME
wp example hello
DESCRIPTION
Prints a greeting.
SYNOPSIS
wp example hello <name> [--type=<type>] [--honk]
OPTIONS
<name>
Name of person to greet.
[--type=<type>]
---
default: success
options:
- success
- error
---
[--honk]
EXAMPLES
# Say hello to Newman
wp example hello Newman
Success: Hello, Newman!
GLOBAL PARAMETERS
"""
Given a test-reordering.php file:
"""
<?php
WP_CLI::add_command( 'test-reordering', function () { }, [
'shortdesc' => 'Test reordering of arguments.',
'synopsis' => [
[
'type' => 'flag',
'name' => 'my-flag',
'description' => 'Flag something',
],
[
'type' => 'assoc',
'name' => 'my-assoc',
'description' => 'Assoc something',
'options' => [ 'a', 'b', 'c' ],
'default' => 'a',
],
[
'type' => 'positional',
'name' => 'my-positional',
'description' => 'Positional something',
'optional' => false,
'repeating' => false,
],
],
'when' => 'before_wp_load',
] );
"""
When I run `wp --require=test-reordering.php help test-reordering`
Then STDOUT should contain:
"""
NAME
wp test-reordering
DESCRIPTION
Test reordering of arguments.
SYNOPSIS
wp test-reordering <my-positional> --my-assoc=<my-assoc> --my-flag
OPTIONS
<my-positional>
Positional something
--my-assoc=<my-assoc>
Assoc something
---
default: a
options:
- a
- b
- c
---
--my-flag
Flag something
"""
Scenario: Register a command with default and accepted arguments.
Given an empty directory
And a test-cmd.php file:
"""
<?php
/**
* An amazing command for managing burritos.
*
* [<bar>]
* : This is the bar argument.
* ---
* default: burrito
* ---
*
* [<shop>...]
* : This is where you buy burritos.
* ---
* options:
* - left_coast_siesta
* - cha cha cha
* ---
*
* [--burrito=<burrito>]
* : This is the burrito argument.
* ---
* options:
* - beans
* - veggies
* ---
*
* @when before_wp_load
*/
$foo = function( $args, $assoc_args ) {
$out = array(
'bar' => isset( $args[0] ) ? $args[0] : '',
'shop' => isset( $args[1] ) ? $args[1] : '',
'burrito' => isset( $assoc_args['burrito'] ) ? $assoc_args['burrito'] : '',
);
WP_CLI::print_value( $out, array( 'format' => 'yaml' ) );
};
WP_CLI::add_command( 'foo', $foo );
"""
When I run `wp --require=test-cmd.php foo --help`
Then STDOUT should contain:
"""
[<bar>]
This is the bar argument.
---
default: burrito
---
"""
And STDOUT should contain:
"""
[--burrito=<burrito>]
This is the burrito argument.
---
options:
- beans
- veggies
---
"""
When I run `wp --require=test-cmd.php foo`
Then STDOUT should be YAML containing:
"""
bar: burrito
shop:
burrito:
"""
And STDERR should be empty
When I run `wp --require=test-cmd.php foo ''`
Then STDOUT should be YAML containing:
"""
bar:
shop:
burrito:
"""
And STDERR should be empty
When I run `wp --require=test-cmd.php foo apple --burrito=veggies`
Then STDOUT should be YAML containing:
"""
bar: apple
shop:
burrito: veggies
"""
And STDERR should be empty
When I try `wp --require=test-cmd.php foo apple --burrito=meat`
Then STDERR should contain:
"""
Error: Parameter errors:
Invalid value specified for 'burrito' (This is the burrito argument.)
"""
When I try `wp --require=test-cmd.php foo apple --burrito=''`
Then STDERR should contain:
"""
Error: Parameter errors:
Invalid value specified for 'burrito' (This is the burrito argument.)
"""
When I try `wp --require=test-cmd.php foo apple taco_del_mar`
Then STDERR should contain:
"""
Error: Invalid value specified for positional arg.
"""
When I try `wp --require=test-cmd.php foo apple 'cha cha cha' taco_del_mar`
Then STDERR should contain:
"""
Error: Invalid value specified for positional arg.
"""
When I run `wp --require=test-cmd.php foo apple 'cha cha cha'`
Then STDOUT should be YAML containing:
"""
bar: apple
shop: cha cha cha
burrito:
"""
And STDERR should be empty
Scenario: Register a command with default and accepted arguments, part two
Given an empty directory
And a test-cmd.php file:
"""
<?php
/**
* An amazing command for managing burritos.
*
* [<burrito>]
* : This is the bar argument.
* ---
* options:
* - beans
* - veggies
* ---
*
* @when before_wp_load
*/
$foo = function( $args, $assoc_args ) {
$out = array(
'burrito' => isset( $args[0] ) ? $args[0] : '',
);
WP_CLI::print_value( $out, array( 'format' => 'yaml' ) );
};
WP_CLI::add_command( 'foo', $foo );
"""
When I run `wp --require=test-cmd.php foo`
Then STDOUT should be YAML containing:
"""
burrito:
"""
And STDERR should be empty
When I run `wp --require=test-cmd.php foo beans`
Then STDOUT should be YAML containing:
"""
burrito: beans
"""
And STDERR should be empty
When I try `wp --require=test-cmd.php foo apple`
Then STDERR should be:
"""
Error: Invalid value specified for positional arg.
"""
Scenario: Removing a subcommand should remove it from the index
Given an empty directory
And a remove-comment.php file:
"""
<?php
WP_CLI::add_hook( 'after_add_command:comment', function () {
$command = WP_CLI::get_root_command();
$command->remove_subcommand( 'comment' );
} );
"""
When I run `wp`
Then STDOUT should contain:
"""
Creates, updates, deletes, and moderates comments.
"""
When I run `wp --require=remove-comment.php`
Then STDOUT should not contain:
"""
Creates, updates, deletes, and moderates comments.
"""
Scenario: before_invoke should call subcommands
Given an empty directory
And a call-invoke.php file:
"""
<?php
/**
* @when before_wp_load
*/
$before_invoke = function() {
WP_CLI::success( 'Invoked' );
};
$before_invoke_args = array( 'before_invoke' => function() {
WP_CLI::success( 'before invoke' );
}, 'after_invoke' => function() {
WP_CLI::success( 'after invoke' );
});
WP_CLI::add_command( 'before invoke', $before_invoke, $before_invoke_args );
WP_CLI::add_command( 'before-invoke', $before_invoke, $before_invoke_args );
"""
When I run `wp --require=call-invoke.php before invoke`
Then STDOUT should contain:
"""
Success: before invoke
Success: Invoked
Success: after invoke
"""
When I run `wp --require=call-invoke.php before-invoke`
Then STDOUT should contain:
"""
Success: before invoke
Success: Invoked
Success: after invoke
"""
Scenario: Default arguments should respect wp-cli.yml
Given a WP installation
And a wp-cli.yml file:
"""
post list:
format: count
"""
When I run `wp post list`
Then STDOUT should be a number
Scenario: Use class passed as object
Given an empty directory
And a custom-cmd.php file:
"""
<?php
class Foo_Class {
public function __construct( $message ) {
$this->message = $message;
}
/**
* My awesome class method command
*
* @when before_wp_load
*/
function message( $args ) {
WP_CLI::success( $this->message );
}
}
$foo = new Foo_Class( 'bar' );
WP_CLI::add_command( 'instantiated-command', $foo );
"""
When I run `wp --require=custom-cmd.php instantiated-command message`
Then STDOUT should contain:
"""
bar
"""
And STDERR should be empty
Scenario: WP-CLI suggests matching commands when user entry contains typos
Given a WP installation
When I try `wp clu`
Then STDERR should contain:
"""
Did you mean 'cli'?
"""
When I try `wp cli nfo`
Then STDERR should contain:
"""
Did you mean 'info'?
"""
When I try `wp cli beyondlevenshteinthreshold`
Then STDERR should not contain:
"""
Did you mean
"""
Scenario: WP-CLI suggests matching parameters when user entry contains typos
Given an empty directory
When I try `wp cli info --quie`