From 9e5338f88785a45746ef3d54f5a8972daea5250c Mon Sep 17 00:00:00 2001 From: Zack Cerza Date: Wed, 9 Jul 2014 11:36:57 -0600 Subject: [PATCH] Add test for config substitution Signed-off-by: Zack Cerza --- teuthology/test/test_suite.py | 12 +++++++++++- 1 file changed, 11 insertions(+), 1 deletion(-) diff --git a/teuthology/test/test_suite.py b/teuthology/test/test_suite.py index 0a9fb5e08e..b92ec15668 100644 --- a/teuthology/test/test_suite.py +++ b/teuthology/test/test_suite.py @@ -1,5 +1,6 @@ import os import requests +import yaml from datetime import datetime from pytest import raises, skip @@ -72,6 +73,15 @@ class TestSuiteOnline(object): suite.create_initial_config('s', 'bogus_ceph_branch', 't', 'k', 'f', 'd', 'm') + def test_config_substitution(self): + # Don't attempt to send email + config.results_email = None + job_config_str = suite.create_initial_config('MY_SUITE', 'master', + 'master', 'testing', + 'basic', 'centos', + 'plana') + job_config = yaml.safe_load(job_config_str) + assert job_config['suite'] == 'MY_SUITE' + -# add other tests that use create_initial_config, deserialize the yaml stream # maybe use notario for the above? -- 2.39.5