Tweak test to verify there are no duplicates
This commit is contained in:
parent
c8b63a28af
commit
3dfb6a3094
1 changed files with 2 additions and 2 deletions
|
@ -27,11 +27,11 @@ describe Environment, models: true do
|
|||
let!(:environment1) { create(:environment, project: project) }
|
||||
let!(:environment2) { create(:environment, project: project) }
|
||||
let!(:environment3) { create(:environment, project: project) }
|
||||
let!(:deployment2) { create(:deployment, environment: environment2) }
|
||||
let!(:deployment1) { create(:deployment, environment: environment1) }
|
||||
let!(:deployment2) { create(:deployment, environment: environment2) }
|
||||
let!(:deployment3) { create(:deployment, environment: environment1) }
|
||||
|
||||
it 'returns the environments in order of having been last deployed' do
|
||||
# byebug
|
||||
expect(project.environments.order_by_last_deployed_at.to_a).to eq([environment3, environment2, environment1])
|
||||
end
|
||||
end
|
||||
|
|
Loading…
Reference in a new issue