コード例 #1
0
 def build_ubuntu_repos(self, releases_paths):
     for repo_path in releases_paths:
         utils.exec_piped_cmds(
             ['dpkg-scanpackages .', 'gzip -c9 > Packages.gz'],
             cwd=repo_path)
         release_path = join_path(repo_path, 'Release')
         utils.render_to_file(
             self.release_tmpl_src,
             release_path,
             {'plugin_name': self.meta['name'],
              'major_version': self.plugin_version})
コード例 #2
0
 def build_ubuntu_repos(self, releases_paths):
     for repo_path in releases_paths:
         utils.exec_piped_cmds(
             ['dpkg-scanpackages -m .', 'gzip -c9 > Packages.gz'],
             cwd=repo_path)
         release_path = join_path(repo_path, 'Release')
         utils.render_to_file(
             self.release_tmpl_src, release_path, {
                 'plugin_name': self.meta['name'],
                 'major_version': self.plugin_version
             })
コード例 #3
0
 def build_ubuntu_repos(cls, releases_paths):
     for repo_path in releases_paths:
         utils.exec_piped_cmds(
             ['dpkg-scanpackages .', 'gzip -c9 > Packages.gz'],
             cwd=repo_path)
コード例 #4
0
 def test_exec_piped_cmds(self):
     process_mock = self.make_process_mock(return_code=0)
     with patch.object(subprocess, 'Popen', return_value=process_mock):
         utils.exec_piped_cmds(['some command', 'some other command'])
         process_mock.communicate.assert_called_with(input='stdout')
コード例 #5
0
ファイル: test_utils.py プロジェクト: sxpx/fuel-plugins
 def test_exec_piped_cmds(self):
     process_mock = self.make_process_mock(return_code=0)
     with patch.object(subprocess, 'Popen', return_value=process_mock):
         utils.exec_piped_cmds(['some command', 'some other command'])
         process_mock.communicate.assert_called_once_with()
コード例 #6
0
 def build_ubuntu_repos(cls, releases_paths):
     for repo_path in releases_paths:
         utils.exec_piped_cmds(
             ['dpkg-scanpackages -m .', 'gzip -c9 > Packages.gz'],
             cwd=repo_path)