Skip to main content
aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorRemi Schnekenburger2016-08-11 11:53:13 +0000
committerGerrit Code Review @ Eclipse.org2016-08-11 13:38:38 +0000
commit4c294665ed3a5ccdd2062b25f0be6c8a82b20302 (patch)
tree87296b2311e5aeceab033fc19e728161880a65f5 /tests/junit/extraplugins
parentf0a5f7b106f3e393bbebb8e988e0dc7850423089 (diff)
downloadorg.eclipse.papyrus-4c294665ed3a5ccdd2062b25f0be6c8a82b20302.tar.gz
org.eclipse.papyrus-4c294665ed3a5ccdd2062b25f0be6c8a82b20302.tar.xz
org.eclipse.papyrus-4c294665ed3a5ccdd2062b25f0be6c8a82b20302.zip
Bug 485342: [Layout] Integrate ELK with Papyrus
This contribution works on the release 0.1 from ELK. It provides JUnit tests on ELK integration (mainly based on an export of the diagram using SVG export facility from Papyrus, and compare with a reference diagram). - add a syserr of the current file to understand better errors in junit report Change-Id: Ifb534f2cdf07299b52c75d14186c572be5e5cf19 Signed-off-by: Remi Schnekenburger <remi.schnekenburger@cea.fr>
Diffstat (limited to 'tests/junit/extraplugins')
-rw-r--r--tests/junit/extraplugins/elk/org.eclipse.papyrus.infra.gmfdiag.elk.tests/src/org/eclipse/papyrus/infra/gmfdiag/elk/tests/classdiag/ClassDiagramLayoutTests.java5
1 files changed, 3 insertions, 2 deletions
diff --git a/tests/junit/extraplugins/elk/org.eclipse.papyrus.infra.gmfdiag.elk.tests/src/org/eclipse/papyrus/infra/gmfdiag/elk/tests/classdiag/ClassDiagramLayoutTests.java b/tests/junit/extraplugins/elk/org.eclipse.papyrus.infra.gmfdiag.elk.tests/src/org/eclipse/papyrus/infra/gmfdiag/elk/tests/classdiag/ClassDiagramLayoutTests.java
index be2a4a5c01e..79670b6fe5d 100644
--- a/tests/junit/extraplugins/elk/org.eclipse.papyrus.infra.gmfdiag.elk.tests/src/org/eclipse/papyrus/infra/gmfdiag/elk/tests/classdiag/ClassDiagramLayoutTests.java
+++ b/tests/junit/extraplugins/elk/org.eclipse.papyrus.infra.gmfdiag.elk.tests/src/org/eclipse/papyrus/infra/gmfdiag/elk/tests/classdiag/ClassDiagramLayoutTests.java
@@ -162,8 +162,9 @@ public class ClassDiagramLayoutTests extends AbstractPapyrusTest {
IRangeComparator expectedContent = new TokenComparator(readFile(expected));
IRangeComparator currentContent = new TokenComparator(readFile(current));
RangeDifference[] diffs = RangeDifferencer.findDifferences(expectedContent, currentContent);
- for(int i = 0; i < diffs.length; i++) {
- System.err.println(i + " -> " + diffs[i].toString());
+ if(diffs.length > 0) {
+ System.err.println("current file:");
+ System.err.println(readFile(expected));
}
assertThat("There should not be any difference, but some diffs were found.", diffs.length, equalTo(0));
}

Back to the top