@@ -73,7 +73,9 @@ class { 'postgresql::server':
73
73
'app_test1' : { 'login' => true } ,
74
74
'rep_test1' : { 'replication' => true ,
75
75
'login' => true } ,
76
- 'rou_test1' : { 'login' => true } , } ,
76
+ 'rou_test1' : { 'login' => true } ,
77
+ 'val_test1' : { 'login' => true ,
78
+ 'valid_until' => '2030-01-01 00:00:00+00' } , } ,
77
79
'pg_hba_rules' : { 'local all INSTANCE user' : { 'type' => 'local' ,
78
80
'database' => 'all' ,
79
81
'user' => 'ins_test1' ,
@@ -214,10 +216,19 @@ class { 'postgresql::server':
214
216
it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "rou_test1" NOCREATEROLE' ) }
215
217
it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "rou_test1" NOREPLICATION' ) }
216
218
it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "rou_test1" NOSUPERUSER' ) }
219
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" CONNECTION LIMIT -1' ) }
220
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" INHERIT' ) }
221
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" LOGIN' ) }
222
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" NOCREATEDB' ) }
223
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" NOCREATEROLE' ) }
224
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" NOREPLICATION' ) }
225
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" NOSUPERUSER' ) }
226
+ it { is_expected . to contain_postgresql_psql ( 'ALTER ROLE "val_test1" VALID UNTIL \'2030-01-01 00:00:00+00\'' ) }
217
227
it { is_expected . to contain_postgresql_psql ( 'CREATE ROLE app_test1 ENCRYPTED PASSWORD ****' ) }
218
228
it { is_expected . to contain_postgresql_psql ( 'CREATE ROLE dba_test1 ENCRYPTED PASSWORD ****' ) }
219
229
it { is_expected . to contain_postgresql_psql ( 'CREATE ROLE ins_test1 ENCRYPTED PASSWORD ****' ) }
220
230
it { is_expected . to contain_postgresql_psql ( 'CREATE ROLE rep_test1 ENCRYPTED PASSWORD ****' ) }
221
231
it { is_expected . to contain_postgresql_psql ( 'CREATE ROLE rou_test1 ENCRYPTED PASSWORD ****' ) }
232
+ it { is_expected . to contain_postgresql_psql ( 'CREATE ROLE val_test1 ENCRYPTED PASSWORD ****' ) }
222
233
end
223
234
end
0 commit comments