BigW Consortium Gitlab

Commit 2b0426a4 by Lin Jen-Shin

Fix tests due to error key changed

parent aae71188
...@@ -309,6 +309,6 @@ class ApplicationSetting < ActiveRecord::Base ...@@ -309,6 +309,6 @@ class ApplicationSetting < ActiveRecord::Base
def check_default_artifacts_expire_in def check_default_artifacts_expire_in
ChronicDuration.parse(default_artifacts_expire_in) ChronicDuration.parse(default_artifacts_expire_in)
rescue ChronicDuration::DurationParseError rescue ChronicDuration::DurationParseError
errors.add(:default_artifacts_expiration, "is not a correct duration") errors.add(:default_artifacts_expire_in, "is not a correct duration")
end end
end end
...@@ -59,7 +59,7 @@ describe ApplicationSetting, models: true do ...@@ -59,7 +59,7 @@ describe ApplicationSetting, models: true do
def expect_invalid def expect_invalid
expect(setting).to be_invalid expect(setting).to be_invalid
expect(setting.errors.messages) expect(setting.errors.messages)
.to have_key(:default_artifacts_expiration) .to have_key(:default_artifacts_expire_in)
end end
end end
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment