about summary refs log tree commit diff
path: root/spec/validators
diff options
context:
space:
mode:
Diffstat (limited to 'spec/validators')
-rw-r--r--spec/validators/note_length_validator_spec.rb4
-rw-r--r--spec/validators/poll_validator_spec.rb1
-rw-r--r--spec/validators/unreserved_username_validator_spec.rb6
3 files changed, 6 insertions, 5 deletions
diff --git a/spec/validators/note_length_validator_spec.rb b/spec/validators/note_length_validator_spec.rb
index 6e9b4e132..390ac8d90 100644
--- a/spec/validators/note_length_validator_spec.rb
+++ b/spec/validators/note_length_validator_spec.rb
@@ -15,7 +15,7 @@ describe NoteLengthValidator do
     end
 
     it 'counts URLs as 23 characters flat' do
-      text   = ('a' * 476) + " http://#{'b' * 30}.com/example"
+      text = ('a' * 476) + " http://#{'b' * 30}.com/example"
       account = double(note: text, errors: double(add: nil))
 
       subject.validate_each(account, 'note', text)
@@ -23,7 +23,7 @@ describe NoteLengthValidator do
     end
 
     it 'does not count non-autolinkable URLs as 23 characters flat' do
-      text   = ('a' * 476) + "http://#{'b' * 30}.com/example"
+      text = ('a' * 476) + "http://#{'b' * 30}.com/example"
       account = double(note: text, errors: double(add: nil))
 
       subject.validate_each(account, 'note', text)
diff --git a/spec/validators/poll_validator_spec.rb b/spec/validators/poll_validator_spec.rb
index 941b83401..a76c63ccc 100644
--- a/spec/validators/poll_validator_spec.rb
+++ b/spec/validators/poll_validator_spec.rb
@@ -20,6 +20,7 @@ RSpec.describe PollValidator, type: :validator do
 
     context 'expires just 5 min ago' do
       let(:expires_at) { 5.minutes.from_now }
+
       it 'not calls errors add' do
         expect(errors).not_to have_received(:add)
       end
diff --git a/spec/validators/unreserved_username_validator_spec.rb b/spec/validators/unreserved_username_validator_spec.rb
index 746b3866c..e2f051b08 100644
--- a/spec/validators/unreserved_username_validator_spec.rb
+++ b/spec/validators/unreserved_username_validator_spec.rb
@@ -11,10 +11,10 @@ RSpec.describe UnreservedUsernameValidator, type: :validator do
 
     let(:validator) { described_class.new }
     let(:account)   { double(username: username, errors: errors) }
-    let(:errors )   { double(add: nil) }
+    let(:errors) { double(add: nil) }
 
     context '@username.blank?' do
-      let(:username)  { nil }
+      let(:username) { nil }
 
       it 'not calls errors.add' do
         expect(errors).not_to have_received(:add).with(:username, any_args)
@@ -22,7 +22,7 @@ RSpec.describe UnreservedUsernameValidator, type: :validator do
     end
 
     context '!@username.blank?' do
-      let(:username)  { 'f' }
+      let(:username) { 'f' }
 
       context 'reserved_username?' do
         let(:reserved_username) { true }