コード例 #1
0
 def testProjectConstraints(self):
     project = Project()
     XmlProjectParser.load_project(self.project_path, project)
     # Check the project constraints
     self.assertEqual(
         self.project_constraints,
         [os.path.basename(c.path) for c in project.get_constraints()],
     )
コード例 #2
0
 def testProjectConstraints(self):
     project = Project()
     XmlProjectParser.load_project(self.project_path, project)
     # Check the project constraints
     self.assertEqual(
         self.project_constraints,
         [os.path.basename(c.path) for c in project.get_constraints()],
     )
コード例 #3
0
ファイル: test_project.py プロジェクト: kayws426/chiptools
 def test_constraints(self):
     project = Project()
     for constraints in self.project_constraints:
         project.add_constraints(constraints, flow='dummy_flow')
     constraints = project.get_constraints()
     self.assertEquals(
         len(constraints),
         len(self.project_constraints),
         msg='Incorrect number of constraints added to project.'
     )
     self.assertTrue(
         len(constraints) > 0,
         msg='Not correctly tested as no constraints are present.'
     )
     for idx in range(len(constraints)):
         self.assertEquals(
             constraints[idx].path,
             os.path.abspath(self.project_constraints[idx]),
             msg='Constraints path was incorrectly processed.'
         )