chore: rubocop

chore: fix api test conventions

chore: rubocop -A spec/

chore: more rubocop -A

fix failing test

rubocop fixes

removes helper methods that are in my opinion dead code

more rubocop fixes

rubocop -a --auto-gen-config
This commit is contained in:
Philipp Rothmann 2023-05-12 13:01:12 +02:00 committed by Philipp Rothmann
parent f6fb804bbe
commit fb2b4d8a8a
331 changed files with 4263 additions and 4507 deletions

View file

@ -6,12 +6,12 @@ describe TokenVerifier do
let(:msg) { v.generate }
it 'validates' do
expect { v.verify(msg) }.to_not raise_error
expect { v.verify(msg) }.not_to raise_error
end
it 'validates when recreated' do
v2 = TokenVerifier.new(prefix)
expect { v2.verify(msg) }.to_not raise_error
expect { v2.verify(msg) }.not_to raise_error
end
it 'does not validate with a different prefix' do
@ -32,7 +32,9 @@ describe TokenVerifier do
end
it 'does not validate a random string' do
expect { v.verify(Faker::Lorem.characters(number: 100)) }.to raise_error(ActiveSupport::MessageVerifier::InvalidSignature)
expect do
v.verify(Faker::Lorem.characters(number: 100))
end.to raise_error(ActiveSupport::MessageVerifier::InvalidSignature)
end
it 'returns the message' do