コード例 #1
0
ファイル: test_ivy_utils.py プロジェクト: baroquebobcat/pants
 def test_missing_symlinked_jar_in_candidates(self):
   empty_symlink_map = {}
   result = IvyResolveResult(['non-existent-file-location'], empty_symlink_map, 'hash-name',
                             {'default':
                                self.ivy_report_path('ivy_utils_resources/report_with_diamond.xml')
                              })
   with self.assertRaises(IvyResolveMappingError):
     list(result.resolved_jars_for_each_target('default',
                                               [self.make_target('t', JarLibrary,
                                                                 jars=[JarDependency('org1',
                                                                                     'name1')])
                                                ]))
コード例 #2
0
 def test_missing_hardlinked_jar_in_candidates(self):
   empty_hardlink_map = {}
   result = IvyResolveResult(['non-existent-file-location'], empty_hardlink_map, 'hash-name',
                             {'default':
                                self.ivy_report_path('ivy_utils_resources/report_with_diamond.xml')
                              })
   with self.assertRaises(IvyResolveMappingError):
     list(result.resolved_jars_for_each_target('default',
                                               [self.make_target('t', JarLibrary,
                                                                 jars=[JarDependency('org1',
                                                                                     'name1')])
                                                ]))
コード例 #3
0
 def test_missing_symlinked_jar_in_candidates(self):
     empty_symlink_map = {}
     result = IvyResolveResult(
         ["non-existent-file-location"],
         empty_symlink_map,
         "hash-name",
         {"default": self.ivy_report_path("ivy_utils_resources/report_with_diamond.xml")},
     )
     with self.assertRaises(IvyResolveMappingError):
         list(
             result.resolved_jars_for_each_target(
                 "default", [self.make_target("t", JarLibrary, jars=[JarDependency("org1", "name1")])]
             )
         )
コード例 #4
0
 def test_missing_hardlinked_jar_in_candidates(self):
     empty_hardlink_map = {}
     result = IvyResolveResult(
         ["non-existent-file-location"],
         empty_hardlink_map,
         "hash-name",
         {"default": self.ivy_report_path("ivy_utils_resources/report_with_diamond.xml")},
     )
     with self.assertRaises(IvyResolveMappingError):
         list(
             result.resolved_jars_for_each_target(
                 "default",
                 [self.make_target("t", JarLibrary, jars=[JarDependency("org1", "name1")])],
             )
         )