当前位置: 首页>>代码示例>>Python>>正文


Python UnitTestUtilities.deleteIfExists方法代码示例

本文整理汇总了Python中UnitTestUtilities.deleteIfExists方法的典型用法代码示例。如果您正苦于以下问题:Python UnitTestUtilities.deleteIfExists方法的具体用法?Python UnitTestUtilities.deleteIfExists怎么用?Python UnitTestUtilities.deleteIfExists使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在UnitTestUtilities的用法示例。


在下文中一共展示了UnitTestUtilities.deleteIfExists方法的2个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。

示例1: setUp

# 需要导入模块: import UnitTestUtilities [as 别名]
# 或者: from UnitTestUtilities import deleteIfExists [as 别名]
 def setUp(self):
     if Configuration.DEBUG == True: print("     ImportWMOStationDataTestCase.setUp")
     UnitTestUtilities.checkArcPy()
     self.outputFCName = "WMOStationData"
     
     # DO NOT run data download again; dependent data is needed from the ImportWMOStationsTestCase
     self.WMOGDB = os.path.join(Configuration.suitabilityDataPath, "WMO.gdb")
     
     self.StationDataInputFC = os.path.join(self.WMOGDB, "WMOFC_output")
     self.StationDataOutputFC = os.path.join(self.WMOGDB, self.outputFCName)
     self.WMOFolder = os.path.join(Configuration.suitabilityDataPath, "WMOStationFiles")
     
     UnitTestUtilities.checkFilePaths([Configuration.suitabilityDataPath, Configuration.maow_ToolboxPath, self.WMOFolder, self.WMOGDB])
     UnitTestUtilities.deleteIfExists(self.StationDataOutputFC)
开发者ID:Esri,项目名称:solutions-geoprocessing-toolbox,代码行数:16,代码来源:ImportWMOStationDataTestCase.py

示例2: setUp

# 需要导入模块: import UnitTestUtilities [as 别名]
# 或者: from UnitTestUtilities import deleteIfExists [as 别名]
 def setUp(self):
     if Configuration.DEBUG == True: print("     VisibilityRangeAtSeaTestCase.setUp")
     
     UnitTestUtilities.checkArcPy()
     # Configuration.suitabilityDataPath = os.path.join(Configuration.suitabilityPaths, "data")
     
     self.maritimeOutputGDB = os.path.join(Configuration.maritimeDataPath, "output.gdb")
     self.maritimeDataGDB = os.path.join(Configuration.maritimeDataPath, "data.gdb")
     
     self.visibleRange = os.path.join(self.maritimeOutputGDB, "visRangeOutput")
     self.vessel = os.path.join(self.maritimeOutputGDB, "vesselOutput")
     self.shipLocation = os.path.join(self.maritimeDataGDB, "Ships")
     
     UnitTestUtilities.checkFilePaths([Configuration.maritimeDataPath, Configuration.maritime_DesktopToolboxPath, Configuration.maritime_ProToolboxPath])
     UnitTestUtilities.deleteIfExists(self.vessel)
     UnitTestUtilities.deleteIfExists(self.visibleRange)
开发者ID:weepingdog,项目名称:solutions-geoprocessing-toolbox,代码行数:18,代码来源:VisibilityRangeAtSeaTestCase.py


注:本文中的UnitTestUtilities.deleteIfExists方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。