blob: 243d85acbb0f32c2ccab1d9002f55b197d77bb09 (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
RSpec.describe RoutePolicy, type: :policy do
let( :record ){ build_stubbed :route }
permissions :create? do
it_behaves_like 'permitted policy and same organisation', 'routes.create', archived: true
end
permissions :destroy? do
it_behaves_like 'permitted policy and same organisation', 'routes.destroy', archived: true
end
permissions :edit? do
it_behaves_like 'permitted policy and same organisation', 'routes.update', archived: true
end
permissions :new? do
it_behaves_like 'permitted policy and same organisation', 'routes.create', archived: true
end
permissions :update? do
it_behaves_like 'permitted policy and same organisation', 'routes.update', archived: true
end
end
|