Files
pisi/tests/testcase.py
T
Eray Özkural f109b4bd1e * use a testcase class for proper API init/shutdown, if that doesn't
work, nothing will anyway :)
  - this new class uses the tmp dir
* make the test cases that access pisi dirs, etc. derive
from the new testcase class
* a silly Option class in config module for those who want
to give options from API. We should have default values there, too (it seems!)
* several fixes in tests, remove old style config accesses etc.
2005-10-26 23:28:14 +00:00

28 lines
708 B
Python

# Copyright (C) 2005, TUBITAK/UEKAE
#
# 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 2 of the License, or (at your option)
# any later version.
#
# Please read the COPYING file.
#
import unittest
import os
import pisi
import pisi.api
import pisi.util
import pisi.config
class TestCase(unittest.TestCase):
def setUp(self, comar = False, database = True):
options = pisi.config.Options()
options.destdir = 'tmp'
pisi.api.init(options = options, comar = comar, database = database)
def tearDown(self, ):
pisi.api.finalize()