Skip to content

Commit 5f42084

Browse files
committed
updating the test cases to fix the chef-cli references
Signed-off-by: nikhil2611 <nikhilgupta2102@gmail.com>
1 parent 3926c3a commit 5f42084

File tree

7 files changed

+10
-10
lines changed

7 files changed

+10
-10
lines changed

spec/shared/a_file_generator.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def generator_context
4040
let(:argv) { [] }
4141

4242
it "emits an error message and exits" do
43-
expected_stdout = "Usage: chef generate #{generator_name} [path/to/cookbook] NAME [options]"
43+
expected_stdout = "Usage: chef-cli generate #{generator_name} [path/to/cookbook] NAME [options]"
4444

4545
expect(recipe_generator.run).to eq(1)
4646
expect(stdout).to include(expected_stdout)
@@ -85,7 +85,7 @@ def generator_context
8585
let(:argv) { [ new_file_name ] }
8686

8787
it "emits an error message and exits" do
88-
expected_stdout = "Usage: chef generate #{generator_name} [path/to/cookbook] NAME [options]"
88+
expected_stdout = "Usage: chef-cli generate #{generator_name} [path/to/cookbook] NAME [options]"
8989
expected_stderr = "Error: Directory #{Dir.pwd} is not a cookbook\n"
9090

9191
expect(recipe_generator.run).to eq(1)

spec/unit/cli_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -46,9 +46,9 @@ def stderr
4646
Patents: #{ChefCLI::Dist::PATENTS}
4747
4848
Usage:
49-
chef -h/--help
50-
chef -v/--version
51-
chef command [arguments...] [options...]
49+
chef-cli -h/--help
50+
chef-cli -v/--version
51+
chef-cli command [arguments...] [options...]
5252
5353
Available Commands:
5454
gem Runs the `gem` command in context of the embedded ruby

spec/unit/command/env_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,7 @@
2929
let(:omnibus_bin_dir) { "/foo/bin" }
3030

3131
it "has a usage banner" do
32-
expect(command_instance.banner).to eq("Usage: chef env")
32+
expect(command_instance.banner).to eq("Usage: chef-cli env")
3333
end
3434

3535
describe "when running from within an omnibus install" do

spec/unit/command/exec_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -28,7 +28,7 @@ def run_command
2828
end
2929

3030
it "has a usage banner" do
31-
expect(command_instance.banner).to eq("Usage: chef exec SYSTEM_COMMAND")
31+
expect(command_instance.banner).to eq("Usage: chef-cli exec SYSTEM_COMMAND")
3232
end
3333

3434
describe "when locating omnibus directory" do

spec/unit/command/generate_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -75,7 +75,7 @@ def stderr
7575
context "with a generator defined" do
7676
let(:expected_help_message) do
7777
<<~E
78-
Usage: chef generate GENERATOR [options]
78+
Usage: chef-cli generate GENERATOR [options]
7979
8080
Available generators:
8181
example this is a test

spec/unit/command/generator_commands/cookbook_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -131,7 +131,7 @@ def generator_context
131131
context "when given invalid/incomplete arguments" do
132132

133133
let(:expected_help_message) do
134-
"Usage: chef generate cookbook NAME [options]\n"
134+
"Usage: chef-cli generate cookbook NAME [options]\n"
135135
end
136136

137137
def with_argv(argv)

spec/unit/command/generator_commands/policyfile_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -212,7 +212,7 @@ def generator_context
212212
let(:argv) { %w{ foo bar baz } }
213213

214214
it "shows usage and exits" do
215-
expected_stdout = "Usage: chef generate policyfile [NAME] [options]"
215+
expected_stdout = "Usage: chef-cli generate policyfile [NAME] [options]"
216216

217217
expect(generator.run).to eq(1)
218218
expect(stderr).to include(expected_stdout)

0 commit comments

Comments
 (0)