Synchronize properties context names in rules’ specs

This commit is contained in:
Sijawusz Pur Rahnama 2022-12-19 20:44:32 +01:00
parent 8112dddc8f
commit 70078cf77f
11 changed files with 13 additions and 13 deletions

View file

@ -42,7 +42,7 @@ module Ameba::Rule::Style
end
context "properties" do
it "allows to configure filter_names" do
it "#filter_names" do
rule = IsAFilter.new
rule.filter_names = %w(select)

View file

@ -130,7 +130,7 @@ module Ameba
end
context "properties" do
it "allows to configure integer min digits" do
it "#int_min_digits" do
rule = Rule::Style::LargeNumbers.new
rule.int_min_digits = 10
expect_no_issues rule, %q(1200000)

View file

@ -43,7 +43,7 @@ module Ameba::Rule::Style
end
context "properties" do
context "#exclude_ternary=" do
context "#exclude_ternary" do
it "skips ternary control expressions by default" do
expect_no_issues subject, <<-CRYSTAL
(foo > bar) ? true : false
@ -75,7 +75,7 @@ module Ameba::Rule::Style
end
end
context "#allow_safe_assignment=" do
context "#allow_safe_assignment" do
it "reports assignments by default" do
expect_issue subject, <<-CRYSTAL
if (foo = @foo)

View file

@ -201,7 +201,7 @@ module Ameba::Rule::Style
end
context "properties" do
context "#allow_multi_next=" do
context "#allow_multi_next" do
it "allows multi next statements by default" do
expect_no_issues subject, <<-CRYSTAL
block do |a, b|

View file

@ -284,7 +284,7 @@ module Ameba::Rule::Style
end
context "properties" do
context "#allow_multi_return=" do
context "#allow_multi_return" do
it "allows multi returns by default" do
expect_no_issues subject, <<-CRYSTAL
def method(a, b)