diff --git a/spec/services/articles/builder_spec.rb b/spec/services/articles/builder_spec.rb index ecb0261ab..2aa081c7b 100644 --- a/spec/services/articles/builder_spec.rb +++ b/spec/services/articles/builder_spec.rb @@ -19,12 +19,12 @@ RSpec.describe Articles::Builder, type: :service do } end - it "initializes an article with the correct attributes and does not store location" do - subject, store_location = described_class.call(user, tag, prefill) + it "initializes an article with the correct attributes and needs authorization" do + subject, needs_authorization = described_class.call(user, tag, prefill) expect(subject).to be_an_instance_of(Article) expect(subject).to have_attributes(correct_attributes) - expect(store_location).to be true + expect(needs_authorization).to be true end end @@ -38,12 +38,12 @@ RSpec.describe Articles::Builder, type: :service do } end - it "initializes an article with the correct attributes and does not store location" do - subject, store_location = described_class.call(user, tag, prefill) + it "initializes an article with the correct attributes and needs authorization" do + subject, needs_authorization = described_class.call(user, tag, prefill) expect(subject).to be_an_instance_of(Article) expect(subject).to have_attributes(correct_attributes) - expect(store_location).to be true + expect(needs_authorization).to be true end end @@ -60,12 +60,12 @@ RSpec.describe Articles::Builder, type: :service do } end - it "initializes an article with the correct attributes and does not store location" do - subject, store_location = described_class.call(user, tag, prefill) + it "initializes an article with the correct attributes and needs authorization" do + subject, needs_authorization = described_class.call(user, tag, prefill) expect(subject).to be_an_instance_of(Article) expect(subject).to have_attributes(correct_attributes) - expect(store_location).to be true + expect(needs_authorization).to be true end end @@ -79,12 +79,12 @@ RSpec.describe Articles::Builder, type: :service do } end - it "initializes an article with the correct attributes and does not store location" do - subject, store_location = described_class.call(user, tag, prefill) + it "initializes an article with the correct attributes and needs authorization" do + subject, needs_authorization = described_class.call(user, tag, prefill) expect(subject).to be_an_instance_of(Article) expect(subject).to have_attributes(correct_attributes) - expect(store_location).to be true + expect(needs_authorization).to be true end end @@ -99,13 +99,13 @@ RSpec.describe Articles::Builder, type: :service do } end - it "initializes an article with the correct attributes and stores location" do + it "initializes an article with the correct attributes and does not need authorization" do user.setting.update(editor_version: "v1") - subject, store_location = described_class.call(user, tag, prefill) + subject, needs_authorization = described_class.call(user, tag, prefill) expect(subject).to be_an_instance_of(Article) expect(subject).to have_attributes(correct_attributes) - expect(store_location).to be false + expect(needs_authorization).to be false end end @@ -117,12 +117,12 @@ RSpec.describe Articles::Builder, type: :service do } end - it "initializes an article with the correct attributes and does stores location" do - subject, store_location = described_class.call(user, tag, prefill) + it "initializes an article with the correct attributes and does not need authorization" do + subject, needs_authorization = described_class.call(user, tag, prefill) expect(subject).to be_an_instance_of(Article) expect(subject).to have_attributes(correct_attributes) - expect(store_location).to be false + expect(needs_authorization).to be false end end @@ -139,13 +139,13 @@ RSpec.describe Articles::Builder, type: :service do } end - it "initializes an article with the correct attributes and does stores location" do + it "initializes an article with the correct attributes and does not need authorization" do user.setting.update(editor_version: "v1") - subject, store_location = described_class.call(user, tag, prefill) + subject, needs_authorization = described_class.call(user, tag, prefill) expect(subject).to be_an_instance_of(Article) expect(subject).to have_attributes(correct_attributes) - expect(store_location).to be false + expect(needs_authorization).to be false end end end