from argparse import ArgumentParser
-import ConfigParser
+try:
+ import configparser
+except ImportError:
+ import ConfigParser as configparser
import inspect
import os
import sys
here = os.path.abspath(os.path.dirname(self.config_file_name))
else:
here = ""
- file_config = ConfigParser.SafeConfigParser({'here': here})
+ file_config = configparser.SafeConfigParser({'here': here})
if self.config_file_name:
file_config.read([self.config_file_name])
else:
staging_directory = os.path.join(os.path.dirname(__file__), 'scratch')
files_directory = os.path.join(os.path.dirname(__file__), 'files')
-testing_config = ConfigParser.ConfigParser()
+testing_config = configparser.ConfigParser()
testing_config.read(['test.cfg'])
def sqlite_db():
else:
try:
cfg = testing_config.get("db", name)
- except ConfigParser.NoOptionError:
+ except configparser.NoOptionError:
raise SkipTest("No dialect %r in test.cfg" % name)
try:
eng = create_engine(cfg)