mirror of
https://github.com/Echtzeitsysteme/gips-tests.git
synced 2024-05-20 12:00:56 +00:00
Code formatter + adds new generic scheduling to README.md
This commit is contained in:
parent
c81bc884c6
commit
54fcd38532
|
@ -26,6 +26,7 @@ Thus, you have to install and configure GLPK or change the configuration of all
|
|||
| `gips.multilayeredinheritence.*` | GIPSL | Tests the correct behaviour of GIPS for multi-layered inheritence in classes |
|
||||
| `gips.null*` | GIPSL set | Test project and metamodel to trigger a NPE bug in GIPS |
|
||||
| `gips.sort.*` | GIPSL set | A simple test to create a sorted linked-list |
|
||||
| `gips.scheduling.*` | GIPSL set | Test project and metamodel to plan generic task scheduling |
|
||||
| `gipsl.all.build.*` | GIPSL set | Multiple projects with the same metamodel to test individual language features |
|
||||
| `gipsl.imports.*` | GIPSL set | Multiple projects to test the import functionality |
|
||||
| `gips(l).*bug.*` | GIPSL set | Multiple projects to triggern known bugs (fixed or not fixed) |
|
||||
|
|
|
@ -1,2 +1,6 @@
|
|||
<?xml version="1.0" encoding="UTF-8" standalone="no"?>
|
||||
<?eclipse version="3.0"?><plugin/>
|
||||
<?eclipse version="3.0"?><plugin>
|
||||
<extension point="org.eclipse.emf.ecore.generated_package">
|
||||
<package class="nullmodel.NullmodelPackage" genModel="model/Nullmodel.genmodel" uri="platform:/resource/gips.nullmodel/model/Nullmodel.ecore"/>
|
||||
</extension>
|
||||
</plugin>
|
||||
|
|
|
@ -10,15 +10,15 @@ import org.emoflon.gips.intermediate.GipsIntermediate.ILPSolverType;
|
|||
import test.suite.gips.utils.GlobalTestConfig;
|
||||
|
||||
public class GlobalTestRunnerAllSolvers {
|
||||
|
||||
|
||||
private final static String BASE_REPORT_PATH = "report.html";
|
||||
|
||||
|
||||
private final static String GLPK_SUB_PATH = "glpk";
|
||||
private final static String GLPK_REPORT_PATH = "report_" + GLPK_SUB_PATH + ".html";
|
||||
|
||||
|
||||
private final static String GUROBI_SUB_PATH = "gurobi";
|
||||
private final static String GUROBI_REPORT_PATH = "report_" + GUROBI_SUB_PATH + ".html";
|
||||
|
||||
|
||||
private final static String CPLEX_SUB_PATH = "cplex";
|
||||
private final static String CPLEX_REPORT_PATH = "report_" + CPLEX_SUB_PATH + ".html";
|
||||
|
||||
|
@ -29,17 +29,17 @@ public class GlobalTestRunnerAllSolvers {
|
|||
}
|
||||
|
||||
GlobalTestConfig.solverOverride = true;
|
||||
|
||||
|
||||
GlobalTestConfig.solverType = ILPSolverType.GLPK;
|
||||
removeFile(GLPK_REPORT_PATH);
|
||||
GlobalTestRunner.runTests(pathArg, GLPK_SUB_PATH);
|
||||
renameFile(BASE_REPORT_PATH, GLPK_REPORT_PATH);
|
||||
|
||||
|
||||
GlobalTestConfig.solverType = ILPSolverType.GUROBI;
|
||||
removeFile(GUROBI_REPORT_PATH);
|
||||
GlobalTestRunner.runTests(pathArg, GUROBI_SUB_PATH);
|
||||
renameFile(BASE_REPORT_PATH, GUROBI_REPORT_PATH);
|
||||
|
||||
|
||||
GlobalTestConfig.solverType = ILPSolverType.CPLEX;
|
||||
removeFile(CPLEX_REPORT_PATH);
|
||||
GlobalTestRunner.runTests(pathArg, CPLEX_SUB_PATH);
|
||||
|
@ -47,7 +47,7 @@ public class GlobalTestRunnerAllSolvers {
|
|||
|
||||
System.exit(0);
|
||||
}
|
||||
|
||||
|
||||
//
|
||||
// Utility methods
|
||||
//
|
||||
|
@ -82,12 +82,12 @@ public class GlobalTestRunnerAllSolvers {
|
|||
throw new RuntimeException("Renamig of file <" + from + "> was not successful.");
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
private static void removeFile(final String path) {
|
||||
if (path == null || path.isBlank()) {
|
||||
throw new IllegalArgumentException("File path was null or empty.");
|
||||
}
|
||||
|
||||
|
||||
try {
|
||||
Files.deleteIfExists(Paths.get(path));
|
||||
} catch (final IOException e) {
|
||||
|
|
|
@ -34,7 +34,7 @@ public class GipsSortConstantTermBugTest extends AGipsSortTest {
|
|||
assertEquals(ILPSolverStatus.OPTIMAL, ret.status());
|
||||
assertEquals(1, ret.objectiveValue());
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void test2Entries() {
|
||||
SortModelGenerator.genNEntries(2);
|
||||
|
@ -44,7 +44,7 @@ public class GipsSortConstantTermBugTest extends AGipsSortTest {
|
|||
assertEquals(ILPSolverStatus.OPTIMAL, ret.status());
|
||||
assertEquals(2, ret.objectiveValue());
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void test10Entries() {
|
||||
SortModelGenerator.genNEntries(10);
|
||||
|
|
|
@ -31,7 +31,7 @@ public class GipsSortPatternMappingBugTest extends AGipsSortTest {
|
|||
}
|
||||
|
||||
// Actual tests
|
||||
|
||||
|
||||
@Test
|
||||
public void test1Entry() {
|
||||
SortModelGenerator.genNEntries(1);
|
||||
|
@ -53,7 +53,7 @@ public class GipsSortPatternMappingBugTest extends AGipsSortTest {
|
|||
assertEquals(ILPSolverStatus.OPTIMAL, ret.status());
|
||||
assertEquals(2 * 2, ret.objectiveValue());
|
||||
}
|
||||
|
||||
|
||||
@Test
|
||||
public void test10Entries() {
|
||||
SortModelGenerator.genNEntries(10);
|
||||
|
|
Loading…
Reference in a new issue