23 lines
439 B
MySQL
23 lines
439 B
MySQL
|
-- Test roles
|
||
|
set client_min_messages to warning;
|
||
|
create extension if not exists pgtap;
|
||
|
reset client_min_messages;
|
||
|
|
||
|
begin;
|
||
|
|
||
|
select plan(7);
|
||
|
|
||
|
select has_role('guest');
|
||
|
select has_role('publisher');
|
||
|
select has_role('admin');
|
||
|
select has_role('authenticator');
|
||
|
|
||
|
select is_member_of('guest', 'authenticator');
|
||
|
select is_member_of('publisher', 'authenticator');
|
||
|
select is_member_of('admin', 'authenticator');
|
||
|
|
||
|
select *
|
||
|
from finish();
|
||
|
|
||
|
rollback;
|