From 45ff59aea2498411cba0bd98b08805dcf04005df Mon Sep 17 00:00:00 2001 From: gwen Date: Mon, 23 Jul 2012 14:52:08 +0200 Subject: [PATCH] tests are passing again after package renaming --- test/autopath.py | 2 +- test/test_config.py | 4 ++-- test/test_config_api.py | 4 ++-- test/test_config_big_example.py | 4 ++-- test/test_option_consistency.py | 4 ++-- test/test_option_default.py | 6 +++--- test/test_option_owner.py | 6 +++--- test/test_option_setting.py | 6 +++--- test/test_option_type.py | 4 ++-- test/test_option_with_special_name.py | 4 ++-- test/test_parsing_group.py | 4 ++-- tiramisu/option.py | 4 ++-- 12 files changed, 26 insertions(+), 26 deletions(-) diff --git a/test/autopath.py b/test/autopath.py index 8d98985..11c5057 100644 --- a/test/autopath.py +++ b/test/autopath.py @@ -8,7 +8,7 @@ from os.path import dirname, abspath, join, normpath import sys HERE = dirname(abspath(__file__)) -PATH = normpath(join(HERE, '..', 'src')) +PATH = normpath(join(HERE, '..', 'tiramisu')) if PATH not in sys.path: sys.path.insert(1, PATH) diff --git a/test/test_config.py b/test/test_config.py index e01f9ae..9b345d4 100644 --- a/test/test_config.py +++ b/test/test_config.py @@ -2,8 +2,8 @@ import autopath from py.test import raises -from config import * -from option import * +from tiramisu.config import * +from tiramisu.option import * def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_config_api.py b/test/test_config_api.py index 9c6578c..d8c1ea4 100644 --- a/test/test_config_api.py +++ b/test/test_config_api.py @@ -2,8 +2,8 @@ import autopath from py.test import raises -from config import * -from option import * +from tiramisu.config import * +from tiramisu.option import * def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_config_big_example.py b/test/test_config_big_example.py index 3ffbd80..6d83dc3 100644 --- a/test/test_config_big_example.py +++ b/test/test_config_big_example.py @@ -1,7 +1,7 @@ #just a proof of concept with a lot of options and option groups import autopath -from config import * -from option import * +from tiramisu.config import * +from tiramisu.option import * all_modules = ['amon', 'sphynx', 'zephir'] diff --git a/test/test_option_consistency.py b/test/test_option_consistency.py index d59e378..a7e8370 100644 --- a/test/test_option_consistency.py +++ b/test/test_option_consistency.py @@ -1,8 +1,8 @@ import autopath from py.test import raises -from config import * -from option import * +from tiramisu.config import * +from tiramisu.option import * def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_option_default.py b/test/test_option_default.py index 3d7baf7..64504ef 100644 --- a/test/test_option_default.py +++ b/test/test_option_default.py @@ -2,9 +2,9 @@ import autopath from py.test import raises -from config import * -from option import * -from error import MandatoryError +from tiramisu.config import * +from tiramisu.option import * +from tiramisu.error import MandatoryError def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_option_owner.py b/test/test_option_owner.py index c7fd1c8..609a6a5 100644 --- a/test/test_option_owner.py +++ b/test/test_option_owner.py @@ -1,9 +1,9 @@ import autopath from py.test import raises -from config import * -from option import * -from error import SpecialOwnersError +from tiramisu.config import * +from tiramisu.option import * +from tiramisu.error import SpecialOwnersError def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_option_setting.py b/test/test_option_setting.py index 3c6d2d1..2b7b88c 100644 --- a/test/test_option_setting.py +++ b/test/test_option_setting.py @@ -2,9 +2,9 @@ import autopath from py.test import raises -from config import * -from option import * -from error import * +from tiramisu.config import * +from tiramisu.option import * +from tiramisu.error import * def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_option_type.py b/test/test_option_type.py index 5421ca4..3fb80c9 100644 --- a/test/test_option_type.py +++ b/test/test_option_type.py @@ -3,8 +3,8 @@ import autopath from py.test import raises -from config import * -from option import * +from tiramisu.config import * +from tiramisu.option import * def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_option_with_special_name.py b/test/test_option_with_special_name.py index acc1683..d606e73 100644 --- a/test/test_option_with_special_name.py +++ b/test/test_option_with_special_name.py @@ -2,8 +2,8 @@ import autopath from py.test import raises -from config import * -from option import * +from tiramisu.config import * +from tiramisu.option import * def make_description(): gcoption = ChoiceOption('name', 'GC name', ['ref', 'framework'], 'ref') diff --git a/test/test_parsing_group.py b/test/test_parsing_group.py index ea48039..992a3f8 100644 --- a/test/test_parsing_group.py +++ b/test/test_parsing_group.py @@ -1,7 +1,7 @@ # coding: utf-8 import autopath -from config import * -from option import * +from tiramisu.config import * +from tiramisu.option import * def make_description(): numero_etab = StrOption('numero_etab', "identifiant de l'établissement") diff --git a/tiramisu/option.py b/tiramisu/option.py index e6d8678..bd80579 100644 --- a/tiramisu/option.py +++ b/tiramisu/option.py @@ -231,9 +231,9 @@ class Option(HiddenBaseType, DisabledBaseType, ModeBaseType): class ChoiceOption(Option): opt_type = 'string' - def __init__(self, name, doc, values, open_values=False, default=None, + def __init__(self, name, doc, values, default=None, requires=None, callback=None, callback_params=None, - multi=False, mandatory=False): + multi=False, mandatory=False, open_values=False): self.values = values if open_values not in [True, False]: raise ConfigError('Open_values must be a boolean for '