Commit c1479d0b authored by Noric Couderc's avatar Noric Couderc

Fixed tests so they compile

List.of() doesn't exist for java 8
parent 211686c4
......@@ -8,9 +8,7 @@ import se.lth.cs.bcgen.BCBenchmarkPackage;
import java.io.StringReader;
import java.lang.reflect.InvocationTargetException;
import java.util.ArrayList;
import java.util.List;
import java.util.Map;
import java.util.*;
import java.util.stream.Collectors;
import java.util.stream.Stream;
......@@ -45,7 +43,7 @@ public class SyntheticBenchmarkRunnerTest {
"Trace1", commands, new ArrayList<>());
SyntheticBenchmarkRunner runner = new SyntheticBenchmarkRunner();
List<TrainingSetValue> results = runner.runBenchmarks(List.of(benchmark));
List<TrainingSetValue> results = runner.runBenchmarks(Collections.singletonList(benchmark));
TrainingSetValue v = results.get(0);
Assert.assertTrue(v.getAverage() > 0);
// Sanity check
......
......@@ -462,7 +462,7 @@ public class SyntheticBenchmarkTest {
@Test
public void testTraceBenchmarkIdentifier() {
List<String> trace1 = List.of(
List<String> trace1 = Arrays.asList(
"runAdd",
"runAdd",
"runGet"
......@@ -473,7 +473,7 @@ public class SyntheticBenchmarkTest {
trace1,
new ArrayList<>());
List<String> trace2 = List.of(
List<String> trace2 = Arrays.asList(
"runAdd",
"runGet",
"runAdd"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment