Ejemplo n.º 1
0
 def test_group_remove(self):
     postgres.group_remove(
         'testgroup',
         user='******',
         host='testhost',
         port='testport',
         maintenance_db='maint_db',
         password='******',
         runas='foo'
     )
     postgres._run_psql.assert_called_once_with(
         "/usr/bin/pgsql --no-align --no-readline --no-password --username testuser "
         "--host testhost --port testport "
         "--dbname maint_db -c 'DROP ROLE testgroup'",
         host='testhost', user='******',
         password='******', runas='foo', port='testport')
Ejemplo n.º 2
0
 def test_group_remove(self):
     postgres.group_remove(
         'testgroup',
         user='******',
         host='testhost',
         port='testport',
         maintenance_db='maint_db',
         password='******',
         runas='foo'
     )
     postgres._run_psql.assert_called_once_with(
         "/usr/bin/pgsql --no-align --no-readline --username testuser "
         "--host testhost --port testport "
         "--dbname maint_db -c 'DROP ROLE testgroup'",
         host='testhost', user='******',
         password='******', runas='foo', port='testport')
Ejemplo n.º 3
0
 def test_group_remove(self):
     postgres.group_remove(
         'testgroup',
         user='******',
         host='testhost',
         port='testport',
         maintenance_db='maint_db',
         password='******',
         runas='foo'
     )
     postgres._run_psql.assert_called_once_with(
         ['/usr/bin/pgsql', '--no-align', '--no-readline',
          '--no-password', '--username', 'testuser', '--host',
          'testhost', '--port', 'testport', '--dbname', 'maint_db',
          '-c', 'DROP ROLE "testgroup"'],
         host='testhost', user='******',
         password='******', runas='foo', port='testport')
Ejemplo n.º 4
0
 def test_group_remove(self):
     postgres.group_remove('testgroup',
                           user='******',
                           host='testhost',
                           port='testport',
                           maintenance_db='maint_db',
                           password='******',
                           runas='foo')
     postgres._run_psql.assert_called_once_with([
         '/usr/bin/pgsql', '--no-align', '--no-readline', '--no-password',
         '--username', 'testuser', '--host', 'testhost', '--port',
         'testport', '--dbname', 'maint_db', '-c', 'DROP ROLE "testgroup"'
     ],
                                                host='testhost',
                                                user='******',
                                                password='******',
                                                runas='foo',
                                                port='testport')