def test_update_packaging_site(self): """ Test to execute update_packaging_site. """ name = "http://192.168.0.2" ret = {"name": name, "result": True, "comment": "", "changes": {}} mock_t = MagicMock(return_value=True) with patch.dict(pkgng.__salt__, {"pkgng.update_package_site": mock_t}): self.assertDictEqual(pkgng.update_packaging_site(name), ret)
def test_update_packaging_site(self): ''' Test to execute update_packaging_site. ''' name = "http://192.168.0.2" ret = {'name': name, 'result': True, 'comment': '', 'changes': {}} mock_t = MagicMock(return_value=True) with patch.dict(pkgng.__salt__, {'pkgng.update_package_site': mock_t}): self.assertDictEqual(pkgng.update_packaging_site(name), ret)