diff --git a/spec/ameba/rule/style/variable_names_spec.cr b/spec/ameba/rule/style/variable_names_spec.cr index 2571d0e0..2e28cf9c 100644 --- a/spec/ameba/rule/style/variable_names_spec.cr +++ b/spec/ameba/rule/style/variable_names_spec.cr @@ -43,6 +43,17 @@ module Ameba CRYSTAL end + it "reports method with multiple instance variables" do + expect_issue subject, <<-CRYSTAL + class Location + def at(@startLocation = nil, @endLocation = nil) + # ^ error: Var name should be underscore-cased: @start_location, not @startLocation + # ^ error: Var name should be underscore-cased: @end_location, not @endLocation + end + end + CRYSTAL + end + it "reports class variable name" do expect_issue subject, <<-CRYSTAL class Greeting