#!/usr/bin/python
#
-# Copyright (C) 2014 Simo Sorce <simo@redhat.com>
-#
-# see file 'COPYING' for use and warranty information
-#
-# This program is free software; you can redistribute it and/or modify
-# it under the terms of the GNU General Public License as published by
-# the Free Software Foundation, either version 3 of the License, or
-# (at your option) any later version.
-#
-# This program is distributed in the hope that it will be useful,
-# but WITHOUT ANY WARRANTY; without even the implied warranty of
-# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
-# GNU General Public License for more details.
-#
-# You should have received a copy of the GNU General Public License
-# along with this program. If not, see <http://www.gnu.org/licenses/>.
-
+# Copyright (C) 2014 Ipsilon project Contributors, for license see COPYING
import ConfigParser
import io
os.mkdir(os.path.join(self.testdir, 'lib'))
os.mkdir(os.path.join(self.testdir, 'lib', test.name))
os.mkdir(os.path.join(self.testdir, 'log'))
+ os.mkdir(os.path.join(self.testdir, 'cache'))
def generate_profile(self, global_opts, args_opts, name, addr, port,
nameid='unspecified'):
newconf = ConfigParser.ConfigParser()
newconf.add_section('globals')
- for k in global_opts.keys():
+ for k in global_opts:
newconf.set('globals', k, global_opts[k])
newconf.add_section('arguments')
- for k in args_opts.keys():
+ for k in args_opts:
newconf.set('arguments', k, args_opts[k])
profile = io.BytesIO()
p = subprocess.Popen(['/usr/sbin/httpd', '-DFOREGROUND', '-f', conf],
env=env, preexec_fn=os.setsid)
self.processes.append(p)
+ return p
def start_pgdb_server(self, datadir, rundir, log, addr, port, env):
p = subprocess.Popen(['/usr/bin/pg_ctl', 'start', '-D', datadir, '-o',
env=env, preexec_fn=os.setsid)
self.processes.append(p)
p.wait()
- for d in ['adminconfig', 'users', 'transactions', 'sessions']:
+ for d in ['adminconfig', 'users', 'transactions', 'sessions',
+ 'saml2.sessions.db']:
cmd = ['/usr/bin/createdb', '-h', addr, '-p', port, d]
subprocess.check_call(cmd, env=env)