From 1622f7aeb9e911d43296caef45e17181652c9c0e Mon Sep 17 00:00:00 2001 From: Matt Jankowski Date: Tue, 11 Jun 2024 03:48:42 -0400 Subject: [PATCH] Remove duplicate fabricator validity checks (#29667) --- spec/models/import_spec.rb | 5 ----- spec/models/poll_spec.rb | 8 -------- 2 files changed, 13 deletions(-) diff --git a/spec/models/import_spec.rb b/spec/models/import_spec.rb index 3605f0b9bf..10df5f8c0b 100644 --- a/spec/models/import_spec.rb +++ b/spec/models/import_spec.rb @@ -8,11 +8,6 @@ RSpec.describe Import do let(:data) { attachment_fixture('imports.txt') } describe 'validations' do - it 'has a valid parameters' do - import = described_class.create(account: account, type: type, data: data) - expect(import).to be_valid - end - it 'is invalid without an type' do import = described_class.create(account: account, data: data) expect(import).to model_have_error_on_field(:type) diff --git a/spec/models/poll_spec.rb b/spec/models/poll_spec.rb index 5aa5548cc8..ebcc459078 100644 --- a/spec/models/poll_spec.rb +++ b/spec/models/poll_spec.rb @@ -31,14 +31,6 @@ describe Poll do end describe 'validations' do - context 'when valid' do - let(:poll) { Fabricate.build(:poll) } - - it 'is valid with valid attributes' do - expect(poll).to be_valid - end - end - context 'when not valid' do let(:poll) { Fabricate.build(:poll, expires_at: nil) }