test/pelusa/lint/else_clauses_test.rb in pelusa-0.2.3 vs test/pelusa/lint/else_clauses_test.rb in pelusa-0.2.4

- old
+ new

@@ -8,38 +8,38 @@ end describe '#check' do describe 'when the class does not use else clauses' do it 'returns a SuccessAnalysis' do - klass = """ + klass = Pelusa.to_ast """ class Foo def initialize if 3 8 end unless 9 3 end end - end""".to_ast + end""" analysis = @lint.check(klass) analysis.successful?.must_equal true end end describe 'when the class uses else clauses' do it 'returns a FailureAnalysis' do - klass = """ + klass = Pelusa.to_ast """ class Foo def initialize if 3 8 else 9 end end - end""".to_ast + end""" analysis = @lint.check(klass) analysis.failed?.must_equal true end end