12345678910111213141516171819202122232425262728293031323334353637383940 |
- import os
- from unittest import TestCase
- from packstack.installer.processors import *
- from ..test_base import PackstackTestCaseMixin
- class ProcessorsTestCase(PackstackTestCaseMixin, TestCase):
- def test_process_host(self):
- """Test packstack.installer.processors.process_host."""
- proc_local = process_host('localhost', 'HOSTNAME')
- self.assertIn(proc_local, ['127.0.0.1', '::1'])
- def test_process_ssh_key(self):
- """Test packstack.installer.processors.process_ssh_key."""
- path = process_ssh_key(os.path.join(self.tempdir, 'id_rsa'), 'SSH_KEY')
-
- self.assertTrue(bool(path))
-
-
-
-
|