Skip to content

Commit 5702bcb

Browse files
committed
Replace be_nil with be nil
1 parent fd0abd1 commit 5702bcb

File tree

6 files changed

+13
-13
lines changed

6 files changed

+13
-13
lines changed

spec/base_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -59,7 +59,7 @@ def hello
5959
end
6060

6161
it "does not set a value in the options hash" do
62-
expect(BrokenCounter.start(["1", "2", "--third", "3"])[0]).to be_nil
62+
expect(BrokenCounter.start(["1", "2", "--third", "3"])[0]).to be nil
6363
end
6464
end
6565

@@ -110,7 +110,7 @@ def hello
110110

111111
describe "#remove_class_option" do
112112
it "removes previous defined class option" do
113-
expect(ClearCounter.class_options[:third]).to be_nil
113+
expect(ClearCounter.class_options[:third]).to be nil
114114
end
115115
end
116116

spec/core_ext/ordered_hash_spec.rb

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88

99
describe "without any items" do
1010
it "returns nil for an undefined key" do
11-
expect(@hash["foo"]).to be_nil
11+
expect(@hash["foo"]).to be nil
1212
end
1313

1414
it "doesn't iterate through any items" do
@@ -35,7 +35,7 @@
3535
end
3636

3737
it "returns nil for an undefined key" do
38-
expect(@hash[:boom]).to be_nil
38+
expect(@hash[:boom]).to be nil
3939
end
4040

4141
it "returns the value for each key" do
@@ -109,7 +109,7 @@
109109
end
110110

111111
it "returns nil if the value to be deleted can't be found" do
112-
expect(@hash.delete(:nothing)).to be_nil
112+
expect(@hash.delete(:nothing)).to be nil
113113
end
114114
end
115115
end

spec/group_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -51,7 +51,7 @@
5151
end
5252

5353
it "can be nil" do
54-
expect(WhinyGenerator.desc).to be_nil
54+
expect(WhinyGenerator.desc).to be nil
5555
end
5656
end
5757

spec/parser/option_spec.rb

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -20,8 +20,8 @@ def option(name, options={})
2020
end
2121

2222
it "has no default value" do
23-
expect(parse(:foo, :string).default).to be_nil
24-
expect(parse(:foo, :numeric).default).to be_nil
23+
expect(parse(:foo, :string).default).to be nil
24+
expect(parse(:foo, :numeric).default).to be nil
2525
end
2626
end
2727

@@ -31,7 +31,7 @@ def option(name, options={})
3131
end
3232

3333
it "has no default value" do
34-
expect(parse(:foo, :required).default).to be_nil
34+
expect(parse(:foo, :required).default).to be nil
3535
end
3636
end
3737

@@ -41,7 +41,7 @@ def option(name, options={})
4141
end
4242

4343
it "has no default value" do
44-
expect(parse(:foo, :bar).default).to be_nil
44+
expect(parse(:foo, :bar).default).to be nil
4545
end
4646
end
4747
end

spec/parser/options_spec.rb

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -266,12 +266,12 @@ def remaining
266266

267267
it "accepts a --no-switch format" do
268268
create "--foo" => "bar"
269-
expect(parse("--no-foo")["foo"]).to be_nil
269+
expect(parse("--no-foo")["foo"]).to be nil
270270
end
271271

272272
it "does not consume an argument for --no-switch format" do
273273
create "--cheese" => :string
274-
expect(parse('burger', '--no-cheese', 'fries')["cheese"]).to be_nil
274+
expect(parse('burger', '--no-cheese', 'fries')["cheese"]).to be nil
275275
end
276276

277277
it "accepts a --switch format on non required types" do

spec/util_spec.rb

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@ def self.clear_user_home!
1717
end
1818

1919
it "returns nil if the namespace can't be found" do
20-
expect(Thor::Util.find_by_namespace('thor:core_ext:ordered_hash')).to be_nil
20+
expect(Thor::Util.find_by_namespace('thor:core_ext:ordered_hash')).to be nil
2121
end
2222

2323
it "returns a class if it matches the namespace" do

0 commit comments

Comments
 (0)