diff options
author | Andreas Brandl <abrandl@gitlab.com> | 2018-03-13 19:43:02 +0100 |
---|---|---|
committer | Andreas Brandl <abrandl@gitlab.com> | 2018-03-16 13:35:26 +0100 |
commit | 6568b4a98e25d88a99b7a499bc7965ae47bf4b19 (patch) | |
tree | b0e7ea1bc404227d3c5fac0f6eae87478f52282b /spec/models/issue_spec.rb | |
parent | d374d0be1af0e6cef4a150425cd73189f9960f54 (diff) | |
download | gitlab-ce-6568b4a98e25d88a99b7a499bc7965ae47bf4b19.tar.gz |
Add shared specs for AtomicInternalId concern.
Diffstat (limited to 'spec/models/issue_spec.rb')
-rw-r--r-- | spec/models/issue_spec.rb | 8 |
1 files changed, 7 insertions, 1 deletions
diff --git a/spec/models/issue_spec.rb b/spec/models/issue_spec.rb index feed7968f09..11154291368 100644 --- a/spec/models/issue_spec.rb +++ b/spec/models/issue_spec.rb @@ -9,11 +9,17 @@ describe Issue do describe 'modules' do subject { described_class } - it { is_expected.to include_module(InternalId) } it { is_expected.to include_module(Issuable) } it { is_expected.to include_module(Referable) } it { is_expected.to include_module(Sortable) } it { is_expected.to include_module(Taskable) } + + it_behaves_like 'AtomicInternalId' do + let(:internal_id_attribute) { :iid } + let(:instance) { build(:issue) } + let(:scope_attrs) { { project: instance.project } } + let(:usage) { :issues } + end end subject { create(:issue) } |