aboutsummaryrefslogtreecommitdiffstats
path: root/spec
diff options
context:
space:
mode:
Diffstat (limited to 'spec')
-rw-r--r--spec/factories/import_resources.rb2
-rw-r--r--spec/models/import_resource_spec.rb4
2 files changed, 3 insertions, 3 deletions
diff --git a/spec/factories/import_resources.rb b/spec/factories/import_resources.rb
index 125f549b8..76afcc486 100644
--- a/spec/factories/import_resources.rb
+++ b/spec/factories/import_resources.rb
@@ -1,7 +1,7 @@
FactoryGirl.define do
factory :import_resource do
association :import
- status :new
+ status :WARNING
sequence(:name) { |n| "Import resource #{n}" }
resource_type 'type'
reference 'reference'
diff --git a/spec/models/import_resource_spec.rb b/spec/models/import_resource_spec.rb
index 6416babdc..c88bb5dd2 100644
--- a/spec/models/import_resource_spec.rb
+++ b/spec/models/import_resource_spec.rb
@@ -3,7 +3,7 @@ require 'rails_helper'
RSpec.describe ImportResource, :type => :model do
it { should belong_to(:import) }
- it { should enumerize(:status).in(:OK, :ERROR, :WARNING, :IGNORED) }
+ it { should enumerize(:status).in("OK", "ERROR", "WARNING", "IGNORED") }
it { should validate_presence_of(:name) }
it { should validate_presence_of(:resource_type) }
@@ -13,7 +13,7 @@ RSpec.describe ImportResource, :type => :model do
let(:import_resource) { create(:import_resource) }
it 'should initialize with new state' do
- expect(import_resource.new?).to be_truthy
+ expect(import_resource.status).to eq("WARNING")
end
end
end