Class RealTests
java.lang.Object
net.ssehub.easy.dslCore.test.AbstractTest<net.ssehub.easy.instantiation.core.model.buildlangModel.Script>
test.de.uni_hildesheim.sse.vil.buildlang.AbstractTest<net.ssehub.easy.instantiation.core.model.buildlangModel.Script>
net.ssehub.easy.producer.scenario_tests.AbstractScenarioTest
net.ssehub.easy.producer.scenario_tests.AbstractEasyScenarioTest
net.ssehub.easy.producer.scenario_tests.AbstractRealTests
net.ssehub.easy.producer.scenario_tests.RealTests
- Direct Known Subclasses:
LocalRealTests
Real use case tests. Although Maven is available, we run the tests without Maven in order to
avoid external resolution issues and to allow for offline use. Thus, maven is commented out if used.
- Author:
- Holger Eichelberger, El-Sharkawy
-
Nested Class Summary
Nested ClassesNested classes/interfaces inherited from class net.ssehub.easy.producer.scenario_tests.AbstractScenarioTest
AbstractScenarioTest.ITestModifier, AbstractScenarioTest.MakeExecutableTestModifier, AbstractScenarioTest.ModeNested classes/interfaces inherited from class test.de.uni_hildesheim.sse.vil.buildlang.AbstractTest
test.de.uni_hildesheim.sse.vil.buildlang.AbstractTest.CleanerNested classes/interfaces inherited from class net.ssehub.easy.dslCore.test.AbstractTest
net.ssehub.easy.dslCore.test.AbstractTest.EqualitySetup<R extends net.ssehub.easy.basics.modelManagement.IModel> -
Field Summary
FieldsFields inherited from class net.ssehub.easy.producer.scenario_tests.AbstractRealTests
enableRealTimeAssertsFields inherited from class net.ssehub.easy.producer.scenario_tests.AbstractScenarioTest
debug, DEFAULT_MODEL_PATHS, instantiate, MEASUREMENTS, modelPathsFields inherited from class net.ssehub.easy.dslCore.test.AbstractTest
OBSERVER -
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionprotected voidprotected voidassertCurlOut(File base) Assert the output of the curl wrapper to be expected.protected voidassertEqual(String file, int... expectedErrorCodes) Asserts equality of the models and the parsed/analyzed result, i.e.protected voidassertEqual(String file, String expectedName, int... expectedErrorCodes) Asserts equality of the models and the parsed/analyzed result, i.e.protected voidassertEqual(String file, String expectedName, String expectedVersion, int... expectedErrorCodes) Asserts equality of the models and the parsed/analyzed result, i.e.protected static voidassertExists(File file) Asserts the existence of the given file.protected static voidassertExists(File base, String name, String extension) Asserts the existence of the given source file and the related class file.protected voidcleanTempFolder(File baseFolder) Deletes a newly created folder inside the temp folder.protected voidenumerateJavaFiles(File location, List<File> files) Enumerate Java files inlocationand store results infiles.protected voidexecuteIipCase(String folder, String modelName, String vilStartRuleName, String... cfgFolder) Executes an IIP-Ecosphere case.protected FileexecuteIndenicaCase(String projectName, String ivmlVersion, String vilVersion, String... makeExecutable) Executes an INDENICA case.protected Fileprotected net.ssehub.easy.instantiation.core.model.execution.TracerFactoryCreates the tracer factory.static voidshutDown()Tears down the test.static voidstartUp()Starts up the test.voidTests the elevator case.voidtestEP1()Tests the initial Easy-Producer 1 build file.voidTests the IIP-Ecosphere model / instantiation (November 21).voidTests the IIP-Ecosphere model / instantiation (October 21).voidTests the IIP-Ecosphere model / instantiation (September 21).voidTests the IIP-Ecosphere model / instantiation (for debugging).voidTests the complete VIL setup for the INDENICA RMS platform.voidTests the complete VIL setup for the INDENICA YMS platform.voidTests whether the instantiation process of templates will work.voidTests the oktoflow model / instantiation (June 24).voidTests the very initial QualiMaster test case.voidTests the QualiMaster model / derivation in its state at the first review (February 2015).voidTests the QualiMaster model / derivation in its state at the second review (February 2016).voidTests the QualiMaster model / derivation (February 2017, without rt-VIL).protected voidTests the QualiMaster model / derivation (February 2017, without rt-VIL).voidTests the QualiMaster model / derivation (June 2015, without rt-VIL).voidTests the QualiMaster model / derivation for VIL field migration (March 2015).voidTests the very initial QualiMaster test case.voidTests the QualiMaster model / derivation (June 2015, without rt-VIL).voidTests the QualiMaster model / derivation (February 2017, experimentally modified, without rt-VIL).protected voidTests the QualiMaster model / derivation (February 2017, experimentally modified, without rt-VIL).voidTests the SVNControl test case.private voidtestSvncontrol(String[] versions) Tests the SVNcontrol use case for given versions.voidtestYMS1()Tests the initial YMS build file (contributed by Christian).Methods inherited from class net.ssehub.easy.producer.scenario_tests.AbstractRealTests
assertConfigurationMethods inherited from class net.ssehub.easy.producer.scenario_tests.AbstractEasyScenarioTest
getMeasurementFileNameMethods inherited from class net.ssehub.easy.producer.scenario_tests.AbstractScenarioTest
configureExecution, createReasoner, createTestConfigurer, executeCase, executeCase, executeCase, executeCase, furtherInitialization, getIvmlFolderIn, getMeasurements, getVilFolderIn, getVtlFolderIn, initializeReasoner, obtainIvmlModelMethods inherited from class test.de.uni_hildesheim.sse.vil.buildlang.AbstractTest
assertEqual, assertEqual, assertExecutor, assertFailure, assertFailure, assertOutdated, cleanTemp, copyFile, createFile, createTempDir, deleteQuietly, getSystemPropertyName, getTempDir, getTestConfigurer, getTestDataDir, registerTypeAnyway, testExecutorMethods inherited from class net.ssehub.easy.dslCore.test.AbstractTest
assertNamingAndVersion, checkEqualsAndPrepareMessage, checkEqualsAndPrepareMessage, checkEqualsAndPrint, checkEqualsAndPrint, checkErrorCodes, checkErrorCodes, checkWarnings, determineTestDataDir, file2String, isEqual, resourceInitialization, toString
-
Field Details
-
RELATIVE_CURL_EXECUTABLES
-
tests
-
-
Constructor Details
-
RealTests
public RealTests()
-
-
Method Details
-
addTestDataLocations
protected void addTestDataLocations()- Overrides:
addTestDataLocationsin classtest.de.uni_hildesheim.sse.vil.buildlang.AbstractTest<net.ssehub.easy.instantiation.core.model.buildlangModel.Script>
-
startUp
public static void startUp()Starts up the test. -
shutDown
public static void shutDown()Tears down the test. -
getTestFolder
- Specified by:
getTestFolderin classtest.de.uni_hildesheim.sse.vil.buildlang.AbstractTest<net.ssehub.easy.instantiation.core.model.buildlangModel.Script>
-
cleanTempFolder
Deletes a newly created folder inside the temp folder. Should be called after the creation of new tests.- Parameters:
baseFolder- A project folder created during a test.
-
assertEqual
protected void assertEqual(String file, String expectedName, int... expectedErrorCodes) throws IOException Asserts equality of the models and the parsed/analyzed result, i.e. it readsfileas a model, analyzes it, compares the obtained errors withexpectedErrorCodes, compares the contents offilewith the printed (analyzed) model and checks the project information directly obtained from file. It is assumed that no version shall be checked.- Parameters:
file- the name of the file containing the model (without suffix)expectedName- the expected name of the modelexpectedErrorCodes- the expected and allowed error codes (errors occurring multiple times need to be listed multiple times here)- Throws:
IOException- problems finding or reading the model file
-
assertEqual
protected void assertEqual(String file, String expectedName, String expectedVersion, int... expectedErrorCodes) throws IOException Asserts equality of the models and the parsed/analyzed result, i.e. it readsfileas a model, analyzes it, compares the obtained errors withexpectedErrorCodes, compares the contents offilewith the printed (analyzed) model and checks the project information directly obtained from file. It is assumed that the name of the model is the same as of the file.- Parameters:
file- the name of the file containing the model (without suffix)expectedName- the expected name of the modelexpectedVersion- the expected version ofexpectedNameexpectedErrorCodes- the expected and allowed error codes (errors occurring multiple times need to be listed multiple times here)- Throws:
IOException- problems finding or reading the model file
-
assertEqual
Asserts equality of the models and the parsed/analyzed result, i.e. it readsfileas a model, analyzes it, compares the obtained errors withexpectedErrorCodes, compares the contents offilewith the printed (analyzed) model and checks the project information directly obtained from file. It is assumed that the name of the model is the same as of the file and no version.- Parameters:
file- the name of the file containing the model (without suffix)expectedErrorCodes- the expected and allowed error codes (errors occurring multiple times need to be listed multiple times here)- Throws:
IOException- problems finding or reading the model file
-
assertCurlOut
Assert the output of the curl wrapper to be expected.- Parameters:
base- the base directory- Throws:
IOException- in case of I/O problems (shall not happen)
-
executeIndenicaCase
protected File executeIndenicaCase(String projectName, String ivmlVersion, String vilVersion, String... makeExecutable) throws IOException Executes an INDENICA case.- Parameters:
projectName- the name of the projectivmlVersion- the version of the IVML file (may be null)vilVersion- the version of the VIL build file (may be null)makeExecutable- those files (in relative paths) within the temporary copy of the project to be made executable- Returns:
- the base directory of the instantiated project (null for no assert)
- Throws:
IOException- in case of I/O problems
-
testIndenicaPlRmsPlatform2
Tests the complete VIL setup for the INDENICA RMS platform.- Throws:
IOException- should not occur
-
testIndenicaPlYmsPlatform
Tests the complete VIL setup for the INDENICA YMS platform.- Throws:
IOException- should not occur
-
testEP1
Tests the initial Easy-Producer 1 build file.- Throws:
IOException- should not occur
-
testYMS1
Tests the initial YMS build file (contributed by Christian).- Throws:
IOException- should not occur
-
testElevator
Tests the elevator case.- Throws:
IOException- should not occur
-
enumerateJavaFiles
Enumerate Java files inlocationand store results infiles.- Parameters:
location- the location to enumeratefiles- the resulting java files (modified as a side effect)
-
testInstantiateNumericCSVInstantiation
Tests whether the instantiation process of templates will work.- Throws:
IOException- If the produced file was not saved or the expected file was not found for comparison
-
testSvncontrol
Tests the SVNControl test case.- Throws:
IOException- shall not occur
-
testSvncontrol
Tests the SVNcontrol use case for given versions.- Parameters:
versions- the version of the models, index 0 IVML, index 1 VIL build file (may be null)- Throws:
IOException- shall not occur
-
assertExists
Asserts the existence of the given source file and the related class file.- Parameters:
base- the base foldername- the name/path of the file (without extension)extension- the primary extension which leads to the class file
-
assertExists
Asserts the existence of the given file.- Parameters:
file- the file
-
testQualiMasterApril14
Tests the very initial QualiMaster test case.- Throws:
IOException- shall not occur
-
testQualiMasterMay14
Tests the very initial QualiMaster test case.- Throws:
IOException- shall not occur
-
testQualiMasterFeb15
Tests the QualiMaster model / derivation in its state at the first review (February 2015).- Throws:
IOException- shall not occur
-
testQualiMasterFeb16
Tests the QualiMaster model / derivation in its state at the second review (February 2016).- Throws:
IOException- shall not occur
-
testQualiMasterMar15
Tests the QualiMaster model / derivation for VIL field migration (March 2015).- Throws:
IOException- shall not occur
-
testQualiMasterJun15
Tests the QualiMaster model / derivation (June 2015, without rt-VIL).- Throws:
IOException- shall not occur
-
testQualiMasterFeb17Impl
Tests the QualiMaster model / derivation (February 2017, without rt-VIL). Seems to fail on Jenkins. This is a slightly modified version to ensure creation of artifacts in repeatable sequence.- Parameters:
mode- the test execution mode- Throws:
IOException- shall not occur
-
testQualiMasterFeb17
Tests the QualiMaster model / derivation (February 2017, without rt-VIL). Seems to fail on Jenkins. This is a slightly modified version to ensure creation of artifacts in repeatable sequence.- Throws:
IOException- shall not occur
-
testQualiMasterSep17Impl
Tests the QualiMaster model / derivation (February 2017, experimentally modified, without rt-VIL). Seems to fail on Jenkins. This is a modified version for evaluating VIL/VTL.- Parameters:
mode- the test execution mode- Throws:
IOException- shall not occur
-
testQualiMasterSep17
Tests the QualiMaster model / derivation (February 2017, experimentally modified, without rt-VIL). Seems to fail on Jenkins. This is a modified version for evaluating VIL/VTL.- Throws:
IOException- shall not occur
-
testQualiMasterMay21
Tests the QualiMaster model / derivation (June 2015, without rt-VIL).- Throws:
IOException- shall not occur
-
testIipEcosphereOct21
Tests the IIP-Ecosphere model / instantiation (October 21).- Throws:
IOException- shall not occur
-
testIipEcosphereNov21
Tests the IIP-Ecosphere model / instantiation (November 21).- Throws:
IOException- shall not occur
-
testIipEcosphereSep22
Tests the IIP-Ecosphere model / instantiation (September 21).- Throws:
IOException- shall not occur
-
testIipEcosphereTest
Tests the IIP-Ecosphere model / instantiation (for debugging).- Throws:
IOException- shall not occur
-
testOktoflowJun24
Tests the oktoflow model / instantiation (June 24).- Throws:
IOException- shall not occur
-
executeIipCase
protected void executeIipCase(String folder, String modelName, String vilStartRuleName, String... cfgFolder) throws IOException Executes an IIP-Ecosphere case.- Parameters:
folder- the case foldermodelName- the name of the model to load and execute (expected files/created files in folder of same name)vilStartRuleName- the name of the VIL start rule to executecfgFolder- additional IVML configuration folders, may be null- Throws:
IOException- if execution/comparison fails
-
getTracerFactory
protected net.ssehub.easy.instantiation.core.model.execution.TracerFactory getTracerFactory()Description copied from class:AbstractScenarioTestCreates the tracer factory.- Overrides:
getTracerFactoryin classAbstractScenarioTest- Returns:
- the tracer factory
-