Exemple #1
0
 def test_simple_pattern_no_match(self):
     """
     Test simple_pattern with no match, nothing should be modified
     """
     build.simple_pattern('line to test for somepkg.xyz', r'testpkg.xyz',
                          'testpkg')
     self.assertEqual(build.buildreq.buildreqs, set())
     self.assertEqual(build.must_restart, 0)
Exemple #2
0
 def test_simple_pattern(self):
     """
     Test simple_pattern with match. The main difference between
     simple_pattern and simple_pattern_pkgconfig is the string that is added
     to buildreq.buildreqs.
     """
     build.simple_pattern('line to test for testpkg.xyz', r'testpkg.xyz',
                          'testpkg')
     self.assertIn('testpkg', build.buildreq.buildreqs)
     self.assertEqual(build.must_restart, 1)