本文整理汇总了Python中EDConfiguration.EDConfiguration.addConfigurationFile方法的典型用法代码示例。如果您正苦于以下问题:Python EDConfiguration.addConfigurationFile方法的具体用法?Python EDConfiguration.addConfigurationFile怎么用?Python EDConfiguration.addConfigurationFile使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在类EDConfiguration.EDConfiguration
的用法示例。
在下文中一共展示了EDConfiguration.addConfigurationFile方法的7个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Python代码示例。
示例1: testAddConfigFile
# 需要导入模块: from EDConfiguration import EDConfiguration [as 别名]
# 或者: from EDConfiguration.EDConfiguration import addConfigurationFile [as 别名]
def testAddConfigFile(self):
# Tests adding a config file
strPath = os.path.join(self.strDataPath, "XSConfiguration.xml")
edConfiguration = EDConfiguration()
edConfiguration.addConfigurationFile(strPath)
# Load the config file again, this time the cache should be used
edConfiguration.addConfigurationFile(strPath)
示例2: testGetPluginListSize
# 需要导入模块: from EDConfiguration import EDConfiguration [as 别名]
# 或者: from EDConfiguration.EDConfiguration import addConfigurationFile [as 别名]
def testGetPluginListSize(self):
"""
Testing the retrieved XSPluginList size from configuration
"""
strPath = os.path.join(self.strDataPath, "XSConfiguration.xml")
edConfiguration = EDConfiguration()
edConfiguration.addConfigurationFile(strPath)
iPluginListSize = edConfiguration.getPluginListSize()
EDAssert.equal(1, iPluginListSize)
示例3: testGetParamItem
# 需要导入模块: from EDConfiguration import EDConfiguration [as 别名]
# 或者: from EDConfiguration.EDConfiguration import addConfigurationFile [as 别名]
def testGetParamItem(self):
"""
Testing the XSParamItem inside an XSPluginItem
"""
strPath = os.path.join(self.strDataPath, "XSConfiguration.xml")
edConfiguration = EDConfiguration()
edConfiguration.addConfigurationFile(strPath)
strValue = edConfiguration.getStringValue("indexingMosflm", "workingDir")
EDAssert.equal("/path/to/working/dir", strValue)
示例4: testGetPluginItemError
# 需要导入模块: from EDConfiguration import EDConfiguration [as 别名]
# 或者: from EDConfiguration.EDConfiguration import addConfigurationFile [as 别名]
def testGetPluginItemError(self):
"""
Testing the retrieval of an absent plugin
"""
strPath = os.path.join(self.strDataPath, "XSConfiguration.xml")
edConfiguration = EDConfiguration()
edConfiguration.addConfigurationFile(strPath)
xsPluginItem = edConfiguration.getXSConfigurationItem("toto")
EDAssert.equal(None, xsPluginItem, "Non-existing configuration item should be None")
示例5: testGetParamValue
# 需要导入模块: from EDConfiguration import EDConfiguration [as 别名]
# 或者: from EDConfiguration.EDConfiguration import addConfigurationFile [as 别名]
def testGetParamValue(self):
"""
Testing the XSParamItem Value convertion from string to different formats
"""
strPath = os.path.join(self.strDataPath, "XSConfiguration.xml")
edConfiguration = EDConfiguration()
edConfiguration.addConfigurationFile(strPath)
xsPluginItem = edConfiguration.getXSConfigurationItem("indexingMosflm")
EDAssert.equal("/path/to/working/dir", edConfiguration.getStringParamValue(xsPluginItem, "workingDir"))
EDAssert.equal("/path/to/working/dir", EDConfiguration.getStringParamValue(xsPluginItem, "workingDir"))
EDAssert.equal(3, edConfiguration.getIntegerParamValue(xsPluginItem, "number"))
EDAssert.equal(3, EDConfiguration.getIntegerParamValue(xsPluginItem, "number"))
示例6: testGetPluginItem
# 需要导入模块: from EDConfiguration import EDConfiguration [as 别名]
# 或者: from EDConfiguration.EDConfiguration import addConfigurationFile [as 别名]
def testGetPluginItem(self):
"""
Testing Plugin indexingMosflm Configuration
"""
strPath = os.path.join(self.strDataPath, "XSConfiguration.xml")
edConfiguration = EDConfiguration()
edConfiguration.addConfigurationFile(strPath)
xsPluginItem = edConfiguration.getXSConfigurationItem("indexingMosflm")
EDAssert.equal("indexingMosflm", xsPluginItem.getName())
paramList = xsPluginItem.getXSParamList()
paramItems = paramList.getXSParamItem()
EDAssert.equal("workingDir", paramItems[0].getName())
EDAssert.equal("/path/to/working/dir", paramItems[0].getValue())
EDAssert.equal("number", paramItems[1].getName())
EDAssert.equal("3", paramItems[1].getValue())
示例7: testGetXSConfigurationItem1
# 需要导入模块: from EDConfiguration import EDConfiguration [as 别名]
# 或者: from EDConfiguration.EDConfiguration import addConfigurationFile [as 别名]
def testGetXSConfigurationItem1(self):
strPath = os.path.join(self.strDataPath, "XSConfiguration.xml")
edConfiguration = EDConfiguration()
edConfiguration.addConfigurationFile(strPath)
xsDataPluginItem = edConfiguration.getXSConfigurationItem("indexingMosflm")
EDAssert.equal(True, xsDataPluginItem is not None, "Obtanied configuration for indexingMosflm")