def test_ui_repoid_vars(self):
     update_action = RepoUpdateActionCommand()
     content = update_action.get_all_content(baseurl="http://example.com", ca_cert=None)
     c4 = self._find_content(content, "c4")
     self.assertEquals("some path", c4["ui_repoid_vars"])
     c2 = self._find_content(content, "c2")
     self.assertEquals(None, c2["ui_repoid_vars"])
Exemple #2
0
 def test_only_allow_content_of_type_yum(self):
     update_action = RepoUpdateActionCommand()
     content = update_action.get_all_content(baseurl="http://example.com",
                                             ca_cert=None)
     self.assertTrue(self._find_content(content, "c1") is not None)
     self.assertTrue(self._find_content(content, "c5") is None)
     self.assertTrue(self._find_content(content, "c6") is None)
    def test_gpg_key(self):

        update_action = RepoUpdateActionCommand()
        content = update_action.get_all_content(baseurl="http://example.com", ca_cert=None)
        c4 = self._find_content(content, "c4")
        self.assertEquals("http://example.com/gpg.key", c4["gpgkey"])
        self.assertEquals("1", c4["gpgcheck"])
Exemple #4
0
 def test_ui_repoid_vars(self):
     update_action = RepoUpdateActionCommand()
     content = update_action.get_all_content(baseurl="http://example.com",
                                         ca_cert=None)
     c4 = self._find_content(content, 'c4')
     self.assertEqual('some path', c4['ui_repoid_vars'])
     c2 = self._find_content(content, 'c2')
     self.assertEqual(None, c2['ui_repoid_vars'])
Exemple #5
0
    def test_gpg_key(self):

        update_action = RepoUpdateActionCommand()
        content = update_action.get_all_content(baseurl="http://example.com",
                                                ca_cert=None)
        c4 = self._find_content(content, 'c4')
        self.assertEqual('http://example.com/gpg.key', c4['gpgkey'])
        self.assertEqual('1', c4['gpgcheck'])
    def test_no_gpg_key(self):

        update_action = RepoUpdateActionCommand()
        content = update_action.get_all_content(baseurl="http://example.com", ca_cert=None)
        c1 = self._find_content(content, "c1")
        self.assertEquals("", c1["gpgkey"])
        self.assertEquals("0", c1["gpgcheck"])

        c2 = self._find_content(content, "c2")
        self.assertEquals("", c2["gpgkey"])
        self.assertEquals("0", c2["gpgcheck"])
Exemple #7
0
    def test_no_gpg_key(self):

        update_action = RepoUpdateActionCommand()
        content = update_action.get_all_content(baseurl="http://example.com",
                                                ca_cert=None)
        c1 = self._find_content(content, 'c1')
        self.assertEqual('', c1['gpgkey'])
        self.assertEqual('0', c1['gpgcheck'])

        c2 = self._find_content(content, 'c2')
        self.assertEqual('', c2['gpgkey'])
        self.assertEqual('0', c2['gpgcheck'])