diff options
Diffstat (limited to 'tests')
-rw-r--r-- | tests/cloud_tests/testcases/modules/salt_minion.py | 5 | ||||
-rw-r--r-- | tests/cloud_tests/testcases/modules/salt_minion.yaml | 5 |
2 files changed, 10 insertions, 0 deletions
diff --git a/tests/cloud_tests/testcases/modules/salt_minion.py b/tests/cloud_tests/testcases/modules/salt_minion.py index c697db2d..f13b48a0 100644 --- a/tests/cloud_tests/testcases/modules/salt_minion.py +++ b/tests/cloud_tests/testcases/modules/salt_minion.py @@ -26,4 +26,9 @@ class Test(base.CloudTestCase): self.assertIn('<key data>', out) self.assertIn('------END PUBLIC KEY-------', out) + def test_grains(self): + """Test master value in config.""" + out = self.get_data_file('grains') + self.assertIn('role: web', out) + # vi: ts=4 expandtab diff --git a/tests/cloud_tests/testcases/modules/salt_minion.yaml b/tests/cloud_tests/testcases/modules/salt_minion.yaml index f20d24f0..ab0e05bb 100644 --- a/tests/cloud_tests/testcases/modules/salt_minion.yaml +++ b/tests/cloud_tests/testcases/modules/salt_minion.yaml @@ -17,6 +17,8 @@ cloud_config: | ------BEGIN PRIVATE KEY------ <key data> ------END PRIVATE KEY------- + grains: + role: web collect_scripts: minion: | #!/bin/bash @@ -30,5 +32,8 @@ collect_scripts: minion.pub: | #!/bin/bash cat /etc/salt/pki/minion/minion.pub + grains: | + #!/bin/bash + cat /etc/salt/grains # vi: ts=4 expandtab |