]> err.no Git - dak/commitdiff
Use original dak.conf in tests/create_pickle_file.py.
authorTorsten Werner <twerner@debian.org>
Wed, 12 Jan 2011 21:11:23 +0000 (22:11 +0100)
committerTorsten Werner <twerner@debian.org>
Wed, 12 Jan 2011 21:11:23 +0000 (22:11 +0100)
We don't want to use the test database for creating the pickle file.

Signed-off-by: Torsten Werner <twerner@debian.org>
tests/create_pickle_file.py

index 55843a910b2ba3f8ffb348e587ab189269d6bb24..74c50a0edd745da9ac360d8796b56b7cdbaa344a 100755 (executable)
@@ -3,14 +3,15 @@
 # recreate the pickle file db-metadata-*.pkl that needs to be updated
 # after a database upgrade
 
-from base_test import fixture
 from daklib.dbconn import DBConn
 
 from sqlalchemy import create_engine, __version__
 
 import pickle
+from os.path import abspath, dirname
 
-pickle_filename = fixture('db-metadata-%s.pkl' % __version__)
+DAK_TEST_DIR = dirname(abspath(__file__))
+pickle_filename = '%s/fixtures/db-metadata-%s.pkl' % (DAK_TEST_DIR, __version__)
 pickle_file = open(pickle_filename, 'w')
 metadata = DBConn().db_meta
 pickle.dump(metadata, pickle_file)