DEV: correct test that assumed group 123 did not exist
This is an incorrect assumption leading to a flaky test, cause for all we know, since sequences do not reset every test, group 123 could exist.
This commit is contained in:
parent
f4d4f7871e
commit
307c526840
|
@ -106,8 +106,8 @@ RSpec.describe Admin::GroupsController do
|
|||
|
||||
context "#destroy" do
|
||||
it 'should return the right response for an invalid group_id' do
|
||||
delete "/admin/groups/123.json"
|
||||
|
||||
max_id = Group.maximum(:id).to_i
|
||||
delete "/admin/groups/#{max_id + 1}.json"
|
||||
expect(response.status).to eq(404)
|
||||
end
|
||||
|
||||
|
|
Loading…
Reference in New Issue