Exemplo n.º 1
0
 def test_mock_options(self):
     ''' test -o/--mock-options and -m/mock-config '''
     nextrelease = '%d' % (int(RELEASE) + 1)
     v = nextrelease if RELEASE in self.BUILDROOT else RELEASE
     buildroot = 'fedora-%s-i386' % v
     self.init_test('mock-options',
                    argv = ['-n', 'python-test', '--cache'],
                    options='--resultdir=results --uniqueext=foo',
                    buildroot=buildroot)
     bug = NameBug('python-test')
     bug.find_urls()
     bug.download_files()
     mock_cmd = ' '.join(Mock._mock_cmd())
     Mock._get_root()
     self.assertIn('-r ' + buildroot, mock_cmd)
     self.assertEqual(Mock.mock_root, buildroot + '-foo')