From 21f2fb5fd1bd6480279d707dd495fc0858a18a60 Mon Sep 17 00:00:00 2001 From: Jan Wittler Date: Mon, 12 Dec 2022 16:55:08 +0100 Subject: [PATCH 1/2] add JUnit to classpath --- bundles/tools.vitruv.testutils.vsum/.classpath | 1 + tests/tools.vitruv.framework.views.tests/.classpath | 1 + tests/tools.vitruv.framework.vsum.tests/.classpath | 1 + 3 files changed, 3 insertions(+) diff --git a/bundles/tools.vitruv.testutils.vsum/.classpath b/bundles/tools.vitruv.testutils.vsum/.classpath index 5b259b905..5b1a18362 100644 --- a/bundles/tools.vitruv.testutils.vsum/.classpath +++ b/bundles/tools.vitruv.testutils.vsum/.classpath @@ -1,6 +1,7 @@ + diff --git a/tests/tools.vitruv.framework.views.tests/.classpath b/tests/tools.vitruv.framework.views.tests/.classpath index c34887147..fcc32f614 100644 --- a/tests/tools.vitruv.framework.views.tests/.classpath +++ b/tests/tools.vitruv.framework.views.tests/.classpath @@ -7,6 +7,7 @@ + diff --git a/tests/tools.vitruv.framework.vsum.tests/.classpath b/tests/tools.vitruv.framework.vsum.tests/.classpath index 2d43d32ef..c8ab85ef2 100644 --- a/tests/tools.vitruv.framework.vsum.tests/.classpath +++ b/tests/tools.vitruv.framework.vsum.tests/.classpath @@ -11,6 +11,7 @@ + From 3e7a7793bcb40df2acd10230c68dc8bd1646c9a5 Mon Sep 17 00:00:00 2001 From: Jan Wittler Date: Mon, 12 Dec 2022 17:13:27 +0100 Subject: [PATCH 2/2] replace `collect(Collectors.toList()` with `Stream::toList` --- .../framework/vsum/internal/ResourceRepositoryImpl.java | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) diff --git a/bundles/tools.vitruv.framework.vsum/src/tools/vitruv/framework/vsum/internal/ResourceRepositoryImpl.java b/bundles/tools.vitruv.framework.vsum/src/tools/vitruv/framework/vsum/internal/ResourceRepositoryImpl.java index 251f0a6c8..31991b456 100644 --- a/bundles/tools.vitruv.framework.vsum/src/tools/vitruv/framework/vsum/internal/ResourceRepositoryImpl.java +++ b/bundles/tools.vitruv.framework.vsum/src/tools/vitruv/framework/vsum/internal/ResourceRepositoryImpl.java @@ -16,7 +16,6 @@ import java.util.Map; import java.util.Map.Entry; import java.util.Set; -import java.util.stream.Collectors; import org.apache.log4j.Logger; import org.eclipse.emf.common.util.URI; @@ -102,7 +101,7 @@ public void loadExistingModels() { private void writeModelsFile() throws IOException { Files.write(fileSystemLayout.getModelsNamesFilesPath(), - modelsResourceSet.getResources().stream().map(Resource::getURI).map(URI::toString).collect(Collectors.toList())); + modelsResourceSet.getResources().stream().map(Resource::getURI).map(URI::toString).toList()); } private void readModelsFile() throws IOException { @@ -208,7 +207,7 @@ public Iterable recordChanges(Runnable changeApplicator) { isRecording = false; fileExtensionRecorderMapping.getRecorders().forEach(ChangeRecorder::endRecording); return fileExtensionRecorderMapping.getRecorders().stream().map(ChangeRecorder::getChange) - .filter(TransactionalChange::containsConcreteChange).collect(Collectors.toList()); + .filter(TransactionalChange::containsConcreteChange).toList(); } @Override