This patch enables all tests by default, unless when they're explicitely disabled in the config file. This will make sure newly added tests are run even when an old configuration file is used.
A comment is also added qa-sample.json. Signed-off-by: Michael Hanselmann <[email protected]> --- qa/qa-sample.json | 6 ++++-- qa/qa_config.py | 6 ++++-- 2 files changed, 8 insertions(+), 4 deletions(-) diff --git a/qa/qa-sample.json b/qa/qa-sample.json index 5a5f279..6bfd42c 100644 --- a/qa/qa-sample.json +++ b/qa/qa-sample.json @@ -66,8 +66,6 @@ "instance-add-drbd-disk": true, "instance-convert-disk": true, - "instance-automatic-restart": false, - "instance-consecutive-failures": false, "instance-export": true, "instance-failover": true, "instance-import": true, @@ -80,6 +78,10 @@ "instance-rename": true, "instance-shutdown": true, + "# cron/ganeti-watcher should be disabled for these tests": null, + "instance-automatic-restart": false, + "instance-consecutive-failures": false, + "# This test might fail with certain hypervisor types, depending": null, "# on whether they support the `gnt-instance console' command.": null, "instance-console": false, diff --git a/qa/qa_config.py b/qa/qa_config.py index 942be8b..20f3308 100644 --- a/qa/qa_config.py +++ b/qa/qa_config.py @@ -60,8 +60,10 @@ def get(name, default=None): def TestEnabled(test): - """Returns True if the given test is enabled.""" - return cfg.get('tests', {}).get(test, False) + """Returns True if the given test is enabled. + + """ + return cfg.get("tests", {}).get(test, True) def GetMasterNode(): -- 1.7.0.4
