Skip to content

Commit 6faa2db

Browse files
committed
Remove unused let & fix malformed test
- Removes an unused let that does not seem to serve an obvious purpose. - Fixes a test where an unused let lead to a specified case not being tested. - Mainly using `mutant` as a canary for an [`rspectre`](https://github.com/dgollahon/rspectre) release.
1 parent c1f18b7 commit 6faa2db

File tree

2 files changed

+2
-5
lines changed

2 files changed

+2
-5
lines changed

spec/unit/mutant/ast/pattern/source_spec.rb

Lines changed: 2 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -29,12 +29,11 @@ def apply
2929
end
3030

3131
context 'on non unix newline' do
32-
let(:input) { "a\r\nb" }
33-
32+
let(:string) { "a\r\nb" }
3433
let(:line_index) { 0 }
3534

3635
it 'considers the \r as part of the previous line' do
37-
expect(apply).to eql('a')
36+
expect(apply).to eql("a\r")
3837
end
3938
end
4039
end

spec/unit/mutant/matcher/method/singleton_spec.rb

Lines changed: 0 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,8 +53,6 @@ def arguments
5353
it_should_behave_like 'a method matcher' do
5454
%i[public protected private].each do |visibility|
5555
context 'with %s visibility' % visibility do
56-
let(:expected_visibility) { visibility }
57-
5856
before do
5957
scope.singleton_class.__send__(visibility, method_name)
6058
end

0 commit comments

Comments
 (0)