Class ClassUtilityTest
java.lang.Object
test.de.iip_ecosphere.platform.support.iip_aas.ClassUtilityTest
public class ClassUtilityTest extends Object
Tests
ClassUtility.- Author:
- Holger Eichelberger, SSE
-
Nested Class Summary
Nested Classes Modifier and Type Class Description private static classClassUtilityTest.BaseA simple base test class.private static classClassUtilityTest.ComplexA simple extending test class.private static classClassUtilityTest.SimpleA simple self-contained test class. -
Field Summary
Fields Modifier and Type Field Description private static StringNAME_AASprivate static StringNAME_TEST_SUBMODELprivate static StringNAME_TEST_VAR_COMPLEXprivate static StringNAME_TEST_VAR_PRIMITIVEprivate static StringNAME_TEST_VAR_SIMPLEprivate static StringURN_AAS -
Constructor Summary
Constructors Constructor Description ClassUtilityTest() -
Method Summary
Modifier and Type Method Description voidaddTestTypeToClassWithDeployment()Tests adding a type to a deployed AAS.private voidassertTypeSubmodel(de.iip_ecosphere.platform.support.aas.Aas aas)Asserts the type sub-model.private voidpopulateModel(de.iip_ecosphere.platform.support.aas.Submodel.SubmodelBuilder smBuilder)Populates the model.voidtestAddTypeToClass()Tests adding a type to an AAS at AAS creation time.voidtestGetId()Tests theClassUtility.getId(String, Object)method.voidtestTranslateToAasName()TestsClassUtility.translateToAasName(String).
-
Field Details
-
NAME_AAS
- See Also:
- Constant Field Values
-
URN_AAS
- See Also:
- Constant Field Values
-
NAME_TEST_SUBMODEL
- See Also:
- Constant Field Values
-
NAME_TEST_VAR_PRIMITIVE
- See Also:
- Constant Field Values
-
NAME_TEST_VAR_SIMPLE
- See Also:
- Constant Field Values
-
NAME_TEST_VAR_COMPLEX
- See Also:
- Constant Field Values
-
-
Constructor Details
-
ClassUtilityTest
public ClassUtilityTest()
-
-
Method Details
-
testAddTypeToClass
Tests adding a type to an AAS at AAS creation time.- Throws:
ExecutionException- shall not occur
-
populateModel
private void populateModel(de.iip_ecosphere.platform.support.aas.Submodel.SubmodelBuilder smBuilder)Populates the model. The types are created implicitly.- Parameters:
smBuilder- the submodel builder to add the types to
-
assertTypeSubmodel
private void assertTypeSubmodel(de.iip_ecosphere.platform.support.aas.Aas aas) throws ExecutionExceptionAsserts the type sub-model.- Parameters:
aas- the AAS to assert the sub-model for- Throws:
ExecutionException- shall not occur
-
testGetId
public void testGetId()Tests theClassUtility.getId(String, Object)method. -
addTestTypeToClassWithDeployment
Tests adding a type to a deployed AAS. We pre-deploy the sub-models to keep the scenario simple.- Throws:
IOException- shall not occurExecutionException- shall not occur
-
testTranslateToAasName
public void testTranslateToAasName()TestsClassUtility.translateToAasName(String).
-