Browse Source

refactor: linting

pull/1815/head
natdeanlewissoftwire 3 years ago
parent
commit
e4bb3539b5
  1. 6
      spec/models/form/sales/pages/organisation_spec.rb
  2. 3
      spec/models/form/sales/questions/owning_organisation_id_spec.rb

6
spec/models/form/sales/pages/organisation_spec.rb

@ -81,7 +81,7 @@ RSpec.describe Form::Sales::Pages::Organisation, type: :model do
:organisation_relationship, :organisation_relationship,
child_organisation: user.organisation, child_organisation: user.organisation,
parent_organisation: stock_owner, parent_organisation: stock_owner,
) )
end end
it "is not shown" do it "is not shown" do
@ -102,12 +102,12 @@ RSpec.describe Form::Sales::Pages::Organisation, type: :model do
:organisation_relationship, :organisation_relationship,
child_organisation: user.organisation, child_organisation: user.organisation,
parent_organisation: stock_owner1, parent_organisation: stock_owner1,
) )
create( create(
:organisation_relationship, :organisation_relationship,
child_organisation: user.organisation, child_organisation: user.organisation,
parent_organisation: stock_owner2, parent_organisation: stock_owner2,
) )
end end
it "is not shown" do it "is not shown" do

3
spec/models/form/sales/questions/owning_organisation_id_spec.rb

@ -3,7 +3,7 @@ require "rails_helper"
RSpec.describe Form::Sales::Questions::OwningOrganisationId, type: :model do RSpec.describe Form::Sales::Questions::OwningOrganisationId, type: :model do
subject(:question) { described_class.new(question_id, question_definition, page) } subject(:question) { described_class.new(question_id, question_definition, page) }
let(:user) { FactoryBot.create(:user, :data_coordinator)} let(:user) { FactoryBot.create(:user, :data_coordinator) }
let(:question_id) { nil } let(:question_id) { nil }
let(:question_definition) { nil } let(:question_definition) { nil }
let(:page) { instance_double(Form::Page) } let(:page) { instance_double(Form::Page) }
@ -112,6 +112,7 @@ RSpec.describe Form::Sales::Questions::OwningOrganisationId, type: :model do
end end
end end
end end
context "when user is support" do context "when user is support" do
let(:user) { create(:user, :support) } let(:user) { create(:user, :support) }

Loading…
Cancel
Save