From da0918e71e82c407e1dc7f5cb80f33cad93263af Mon Sep 17 00:00:00 2001 From: "Chris St. Pierre" Date: Tue, 13 Aug 2013 09:31:49 -0400 Subject: testsuite: fixed unit tests for new SSLCA stuff --- .../TestPlugins/TestCfg/TestCfgAuthorizedKeysGenerator.py | 6 +++--- 1 file changed, 3 insertions(+), 3 deletions(-) (limited to 'testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgAuthorizedKeysGenerator.py') diff --git a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgAuthorizedKeysGenerator.py b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgAuthorizedKeysGenerator.py index e5cef8fa2..7e96b618c 100644 --- a/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgAuthorizedKeysGenerator.py +++ b/testsuite/Testsrc/Testlib/TestServer/TestPlugins/TestCfg/TestCfgAuthorizedKeysGenerator.py @@ -27,12 +27,12 @@ class TestCfgAuthorizedKeysGenerator(TestCfgGenerator, TestStructFile): TestCfgGenerator.setUp(self) TestStructFile.setUp(self) - def get_obj(self, name=None, core=None, fam=None): + @patch("Bcfg2.Server.Plugins.Cfg.CfgAuthorizedKeysGenerator.get_cfg") + def get_obj(self, mock_get_cfg, name=None, core=None, fam=None): if name is None: name = self.path - Bcfg2.Server.Plugins.Cfg.CfgAuthorizedKeysGenerator.CFG = Mock() if core is not None: - Bcfg2.Server.Plugins.Cfg.CfgAuthorizedKeysGenerator.CFG.core = core + mock_get_cfg.return_value.core = core return self.test_obj(name) @patch("Bcfg2.Server.Plugins.Cfg.CfgGenerator.handle_event") -- cgit v1.2.3-1-g7c22