aboutsummaryrefslogtreecommitdiffstats
path: root/spec/models/referential_spec.rb
diff options
context:
space:
mode:
Diffstat (limited to 'spec/models/referential_spec.rb')
-rw-r--r--spec/models/referential_spec.rb6
1 files changed, 6 insertions, 0 deletions
diff --git a/spec/models/referential_spec.rb b/spec/models/referential_spec.rb
index ad9c43010..d0b1d6447 100644
--- a/spec/models/referential_spec.rb
+++ b/spec/models/referential_spec.rb
@@ -12,6 +12,12 @@ describe Referential, :type => :model do
it { should belong_to(:workbench) }
it { should belong_to(:referential_suite) }
+ context "validation" do
+ subject { build_stubbed(:referential) }
+
+ it { should validate_presence_of(:objectid_format) }
+ end
+
context ".referential_ids_in_periode" do
it 'should retrieve referential id in periode range' do
range = ref.metadatas.first.periodes.sample