diff options
author | Claire <claire.github-309c@sitedethib.com> | 2022-11-14 10:31:28 +0100 |
---|---|---|
committer | GitHub <noreply@github.com> | 2022-11-14 10:31:28 +0100 |
commit | 72335694744da87cbfaff20992cb36817f6f8a60 (patch) | |
tree | 55c1b799be04cf83f425414dce762bf9403e2b85 /spec/models | |
parent | 81b1d32d5b618daa4003b8de8292ae4dd3e656f6 (diff) | |
parent | c31e756644120cab650452e9d1c00a1e2f26ade4 (diff) |
Merge pull request #1923 from ClearlyClaire/glitch-soc/merge-upstream
Merge upstream changes
Diffstat (limited to 'spec/models')
-rw-r--r-- | spec/models/account/field_spec.rb | 16 | ||||
-rw-r--r-- | spec/models/custom_emoji_filter_spec.rb | 4 |
2 files changed, 18 insertions, 2 deletions
diff --git a/spec/models/account/field_spec.rb b/spec/models/account/field_spec.rb index fcb2a884a..b4beec048 100644 --- a/spec/models/account/field_spec.rb +++ b/spec/models/account/field_spec.rb @@ -89,6 +89,14 @@ RSpec.describe Account::Field, type: :model do expect(subject.verifiable?).to be false end end + + context 'for text which is blank' do + let(:value) { '' } + + it 'returns false' do + expect(subject.verifiable?).to be false + end + end end context 'for remote accounts' do @@ -133,6 +141,14 @@ RSpec.describe Account::Field, type: :model do expect(subject.verifiable?).to be false end end + + context 'for text which is blank' do + let(:value) { '' } + + it 'returns false' do + expect(subject.verifiable?).to be false + end + end end end end diff --git a/spec/models/custom_emoji_filter_spec.rb b/spec/models/custom_emoji_filter_spec.rb index d859f5c5f..2b1b5dc54 100644 --- a/spec/models/custom_emoji_filter_spec.rb +++ b/spec/models/custom_emoji_filter_spec.rb @@ -50,10 +50,10 @@ RSpec.describe CustomEmojiFilter do context 'else' do let(:params) { { else: 'else' } } - it 'raises RuntimeError' do + it 'raises Mastodon::InvalidParameterError' do expect do subject - end.to raise_error(RuntimeError, /Unknown filter: else/) + end.to raise_error(Mastodon::InvalidParameterError, /Unknown filter: else/) end end end |