12345678910111213141516171819202122232425262728293031323334353637 |
- # -*- coding: utf-8 -*-
- '''
- Tests for the spm info utility
- '''
- # Import python libs
- from __future__ import absolute_import, print_function, unicode_literals
- import shutil
- import pytest
- # Import Salt Testing libs
- from tests.support.case import SPMCase
- @pytest.mark.destructive_test
- class SPMInfoTest(SPMCase):
- '''
- Validate the spm info command
- '''
- def setUp(self):
- self.config = self._spm_config()
- self._spm_build_files(self.config)
- def test_spm_info(self):
- '''
- test spm build
- '''
- self._spm_create_update_repo(self.config)
- install = self.run_spm('install', self.config, 'apache')
- get_info = self.run_spm('info', self.config, 'apache')
- check_info = ['Supported OSes', 'Supported OS', 'installing Apache']
- for info in check_info:
- self.assertIn(info, ''.join(get_info))
- def tearDown(self):
- shutil.rmtree(self._tmp_spm)
|