diff options
14 files changed, 236 insertions, 39 deletions
diff --git a/org.eclipse.help/src/org/eclipse/help/internal/toc/TocFileParser.java b/org.eclipse.help/src/org/eclipse/help/internal/toc/TocFileParser.java index ab78f203d..9c301a26c 100644 --- a/org.eclipse.help/src/org/eclipse/help/internal/toc/TocFileParser.java +++ b/org.eclipse.help/src/org/eclipse/help/internal/toc/TocFileParser.java @@ -145,7 +145,8 @@ class TocFileParser extends DefaultHandler { */ public final void endElement(String namespaceURI, String localName, String qName) throws SAXException { - if (!qName.equals("filter")) { //$NON-NLS-1$ + if (qName.equals("toc") || qName.equals("topic") //$NON-NLS-1$ //$NON-NLS-2$ + || qName.equals("link") || qName.equals("anchor")) { //$NON-NLS-1$ //$NON-NLS-2$ elementStack.pop(); } } diff --git a/org.eclipse.ua.tests/base/org/eclipse/ua/tests/util/FileUtil.java b/org.eclipse.ua.tests/base/org/eclipse/ua/tests/util/FileUtil.java index cbc1f9c3c..a94915573 100644 --- a/org.eclipse.ua.tests/base/org/eclipse/ua/tests/util/FileUtil.java +++ b/org.eclipse.ua.tests/base/org/eclipse/ua/tests/util/FileUtil.java @@ -75,7 +75,7 @@ public class FileUtil { * Gets the contents of the result file with the given original relative path in * the given bundle, as a String (file must be encoded as UTF-8). */ - public static String getResultFileContents(Bundle bundle, String absolutePath) throws IOException { + public static String getResultFileContents(Bundle bundle, String relative) throws IOException { /* * Try [filename]_serialized_os_ws_arch.txt. If it's not there, try * [filename]_serialized.txt. @@ -86,14 +86,14 @@ public class FileUtil { */ String contents = null; try { - contents = getContents(bundle, getResultFile(absolutePath, true)); + contents = getContents(bundle, getResultFile(relative, true)); } catch(Exception e) { // didn't find the _serialized_os_ws_arch.txt file, try just _serialized.txt } if (contents == null) { try { - contents = getContents(bundle, getResultFile(absolutePath, false)); + contents = getContents(bundle, getResultFile(relative, false)); } catch(IOException e) { throw e; diff --git a/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html b/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html new file mode 100644 index 000000000..5918e900f --- /dev/null +++ b/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html @@ -0,0 +1,14 @@ +<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 4.0//EN"><HTML> +<HEAD> +<meta name="copyright" content="Copyright (c) IBM Corporation and others 2000, 2005. This page is made available under license. For full details see the LEGAL in the documentation book that contains this page." > +<META HTTP-EQUIV="Content-Type" CONTENT="text/html; charset=ISO-8859-1"> +<META HTTP-EQUIV="Content-Style-Type" CONTENT="text/css"> +<TITLE>Test</TITLE> +</HEAD> + +<p> +Test +</p> + +</BODY> +</HTML> diff --git a/org.eclipse.ua.tests/data/help/toc/extraContent/simple_toc.xml b/org.eclipse.ua.tests/data/help/toc/extraContent/simple_toc.xml new file mode 100644 index 000000000..a8e7d8041 --- /dev/null +++ b/org.eclipse.ua.tests/data/help/toc/extraContent/simple_toc.xml @@ -0,0 +1,6 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?NLS TYPE="org.eclipse.help.toc"?> + +<toc label="test"> + <topic label="test" href="data/help/toc/extraContent/simple_page.html"/> +</toc> diff --git a/org.eclipse.ua.tests/data/help/toc/extraContent/toc.xml b/org.eclipse.ua.tests/data/help/toc/extraContent/toc.xml new file mode 100644 index 000000000..286bdadf5 --- /dev/null +++ b/org.eclipse.ua.tests/data/help/toc/extraContent/toc.xml @@ -0,0 +1,32 @@ +<?xml version="1.0" encoding="UTF-8"?> +<?NLS TYPE="org.eclipse.help.toc"?> + +<!-- +A TOC with some extra elements and attributes scattered throughout. It should +be able to tolerate this. +--> +<toc unknownAttribute="value" label="TOC with extra elements"> + <topic label="Getting started" unknownAttribute2="value2"> + <link toc="data/help/toc/extraContent/simple_toc.xml" /> + </topic> + <blah value="true"/> + <topic label="Concepts"> + <link toc="data/help/toc/extraContent/simple_toc.xml" /> + </topic> + <test> + <topic label="Tasks"> + <aergaer/> + <test2 attr="true"> + <gaergr/> + <link toc="data/help/toc/extraContent/simple_toc.xml" /> + </test2> + </topic> + </test> + <topic label="Reference"> + <link toc="data/help/toc/extraContent/data/help/toc/extraContent/simple_page.html" /> + </topic> + <topic label="Tips and tricks" href="data/help/toc/extraContent/simple_page.html"/> + <topic label="What's new" href="data/help/toc/extraContent/simple_page.html_page.html"/> + <topic label="Documentation Images" href="data/help/toc/extraContent/simple_page.html"/> + <topic label="Legal" aegraerg="aerger" href="data/help/toc/extraContent/simple_page.html"/> +</toc> diff --git a/org.eclipse.ua.tests/data/help/toc/extraContent/toc2.xml b/org.eclipse.ua.tests/data/help/toc/extraContent/toc2.xml new file mode 100644 index 000000000..a97999eb7 --- /dev/null +++ b/org.eclipse.ua.tests/data/help/toc/extraContent/toc2.xml @@ -0,0 +1,35 @@ +<?xml version="1.0" encoding="utf-8"?> +<?NLS TYPE="org.eclipse.help.toc"?> +<toc label="Samples" topic="samples.htm"> + <topic label="Bats FOR product: Happy Bats, WAS; version: 9.0,8.0 ; platform: z/OS;AIX" href="bats.htm"> + <criteria name="prodname" value="Happy Bats" /> + <criteria name="prodname" value="WAS" /> + <criteria name="version" value="9.0" /> + <criteria name="version" value="8.0" /> + <criteria name="platform" value="z/OS" /> + <criteria name="platform" value="AIX" /> + <topic label="Caring for your fruit bat FOR Version: 9.0; platform: z/OS; product: WAS" href="batcaring.htm"> + <criteria name="version" value="9.0" /> + <criteria name="platform" value="z/OS" /> + <criteria name="prodname" value="WAS" /> + </topic> + <topic label="Cleaning your fruit bat FOR Version: 8.0; platform: AIX; product: Happy Bats" href="batcleaning.htm"> + <criteria name="platform" value="AIX" /> + <criteria name="version" value="8.0" /> + <criteria name="prodname" value="Happy Bats" /> + </topic> + <topic label="Feeding your bat" href="batfeeding.htm"/> + <topic label="Bat sonar" href="batsonar.htm"/> + <topic label="Bat guano" href="batguano.htm"/> + <topic label="Bat history" href="bathistory.htm"/> + <topic label="Bat recycling" href="batreuse.htm"/> + </topic> + <topic label="Bats FOR product: Happy Bats" href="bats.htm#none"> + <criteria name="prodname" value="Happy Bats" /> + <topic label="Feeding your bat" href="batfeeding.htm"/> + <topic label="Bat sonar" href="batsonar.htm"/> + <topic label="Bat guano" href="batguano.htm"/> + <topic label="Bat history" href="bathistory.htm"/> + <topic label="Bat recycling" href="batreuse.htm"/> + </topic> +</toc>
\ No newline at end of file diff --git a/org.eclipse.ua.tests/data/help/toc/extraContent/toc2_serialized.txt b/org.eclipse.ua.tests/data/help/toc/extraContent/toc2_serialized.txt new file mode 100644 index 000000000..e7b25dca4 --- /dev/null +++ b/org.eclipse.ua.tests/data/help/toc/extraContent/toc2_serialized.txt @@ -0,0 +1,61 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<toc + label="Samples" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/toc2.xml"> + <topic + label="Bats FOR product: Happy Bats, WAS; version: 9.0,8.0 ; platform: z/OS;AIX" + href="/org.eclipse.ua.tests/bats.htm"> + <topic + label="Caring for your fruit bat FOR Version: 9.0; platform: z/OS; product: WAS" + href="/org.eclipse.ua.tests/batcaring.htm"> + </topic> + <topic + label="Cleaning your fruit bat FOR Version: 8.0; platform: AIX; product: Happy Bats" + href="/org.eclipse.ua.tests/batcleaning.htm"> + </topic> + <topic + label="Feeding your bat" + href="/org.eclipse.ua.tests/batfeeding.htm"> + </topic> + <topic + label="Bat sonar" + href="/org.eclipse.ua.tests/batsonar.htm"> + </topic> + <topic + label="Bat guano" + href="/org.eclipse.ua.tests/batguano.htm"> + </topic> + <topic + label="Bat history" + href="/org.eclipse.ua.tests/bathistory.htm"> + </topic> + <topic + label="Bat recycling" + href="/org.eclipse.ua.tests/batreuse.htm"> + </topic> + </topic> + <topic + label="Bats FOR product: Happy Bats" + href="/org.eclipse.ua.tests/bats.htm#none"> + <topic + label="Feeding your bat" + href="/org.eclipse.ua.tests/batfeeding.htm"> + </topic> + <topic + label="Bat sonar" + href="/org.eclipse.ua.tests/batsonar.htm"> + </topic> + <topic + label="Bat guano" + href="/org.eclipse.ua.tests/batguano.htm"> + </topic> + <topic + label="Bat history" + href="/org.eclipse.ua.tests/bathistory.htm"> + </topic> + <topic + label="Bat recycling" + href="/org.eclipse.ua.tests/batreuse.htm"> + </topic> + </topic> +</toc> diff --git a/org.eclipse.ua.tests/data/help/toc/extraContent/toc_serialized.txt b/org.eclipse.ua.tests/data/help/toc/extraContent/toc_serialized.txt new file mode 100644 index 000000000..e35bbb632 --- /dev/null +++ b/org.eclipse.ua.tests/data/help/toc/extraContent/toc_serialized.txt @@ -0,0 +1,49 @@ +<?xml version="1.0" encoding="UTF-8" ?> +<toc + label="TOC with extra elements" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/toc.xml"> + <topic + label="Getting started" + href="null"> + <topic + label="test" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html"> + </topic> + </topic> + <topic + label="Concepts" + href="null"> + <topic + label="test" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html"> + </topic> + </topic> + <topic + label="Tasks" + href="null"> + <topic + label="test" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html"> + </topic> + </topic> + <topic + label="Reference" + href="null"> + </topic> + <topic + label="Tips and tricks" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html"> + </topic> + <topic + label="What's new" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html_page.html"> + </topic> + <topic + label="Documentation Images" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html"> + </topic> + <topic + label="Legal" + href="/org.eclipse.ua.tests/data/help/toc/extraContent/simple_page.html"> + </topic> +</toc> diff --git a/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_toc.xml b/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_toc.xml index fed835a43..ef7cc49c3 100644 --- a/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_toc.xml +++ b/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_toc.xml @@ -2,5 +2,5 @@ <?NLS TYPE="org.eclipse.help.toc"?> <toc label="test"> - <topic label="test" href="data/help/dynamicTOC/simple_page.html"/> + <topic label="test" href="data/help/filteredTOC/simple_page.html"/> </toc> diff --git a/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_linux_gtk_x86.txt b/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_linux_gtk_x86.txt index 5511aa6e5..70112dd80 100644 --- a/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_linux_gtk_x86.txt +++ b/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_linux_gtk_x86.txt @@ -10,7 +10,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -18,7 +18,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -26,7 +26,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -34,7 +34,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -42,7 +42,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -50,7 +50,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -58,7 +58,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -66,7 +66,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -74,7 +74,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic diff --git a/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_macosx_carbon_ppc.txt b/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_macosx_carbon_ppc.txt index f72ef7146..a62416e5c 100644 --- a/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_macosx_carbon_ppc.txt +++ b/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_macosx_carbon_ppc.txt @@ -10,7 +10,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -18,7 +18,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -26,7 +26,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -34,7 +34,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -42,7 +42,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -50,7 +50,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -58,7 +58,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -66,7 +66,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -74,7 +74,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic diff --git a/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_win32_win32_x86.txt b/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_win32_win32_x86.txt index 86b260094..97066bf6e 100644 --- a/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_win32_win32_x86.txt +++ b/org.eclipse.ua.tests/data/help/toc/filteredToc/toc_serialized_win32_win32_x86.txt @@ -10,7 +10,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -18,7 +18,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -26,7 +26,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -34,7 +34,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -42,7 +42,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -50,7 +50,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -58,7 +58,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -66,7 +66,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic @@ -74,7 +74,7 @@ href="/org.eclipse.ua.tests/data/help/toc/filteredToc/simple_page.html"> <topic label="test" - href="/org.eclipse.ua.tests/data/help/dynamicTOC/simple_page.html"> + href="/org.eclipse.ua.tests/data/help/filteredTOC/simple_page.html"> </topic> </topic> <topic diff --git a/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/toc/ParserTest.java b/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/toc/ParserTest.java index 66e6bbbbd..2bdb831fa 100644 --- a/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/toc/ParserTest.java +++ b/org.eclipse.ua.tests/help/org/eclipse/ua/tests/help/toc/ParserTest.java @@ -58,23 +58,19 @@ public class ParserTest extends TestCase { TocFile file = toc.getTocFile(); Bundle bundle = UserAssistanceTestPlugin.getDefault().getBundle(); - String pluginRoot = bundle.getLocation().substring("update@".length()); String relativePath = file.getHref(); /* * Only test what's in the toc test data folder. */ if (relativePath.startsWith("data/help/toc/")) { - String absolutePath = pluginRoot + relativePath; - String resultFile = FileUtil.getResultFile(absolutePath); - try { - String expected = FileUtil.getContents(bundle, FileUtil.getResultFile(relativePath, true)); + String expected = FileUtil.getResultFileContents(bundle, relativePath); String actual = TocModelSerializer.serialize(toc); - Assert.assertEquals("Serialized toc model for " + relativePath + "did not match the expected result: " + FileUtil.getResultFile(relativePath), expected, actual); + Assert.assertEquals("Serialized toc model for " + relativePath + " did not match the expected result", expected, actual); } catch(IOException e) { - Assert.fail("An error occured while loading expected result file for TOC at: " + resultFile + ": " + e); + Assert.fail("An error occured while loading expected result file for TOC at: " + relativePath + ": " + e); } } } diff --git a/org.eclipse.ua.tests/plugin.xml b/org.eclipse.ua.tests/plugin.xml index 771b33d42..e0c0e508e 100644 --- a/org.eclipse.ua.tests/plugin.xml +++ b/org.eclipse.ua.tests/plugin.xml @@ -239,6 +239,9 @@ <toc file="data/help/toc/filteredToc/toc.xml" primary="true" /> <toc file="data/help/toc/filteredToc/filter.xml" /> <toc file="data/help/toc/filteredToc/simple_toc.xml" /> + <toc file="data/help/toc/extraContent/toc.xml" primary="true"/> + <toc file="data/help/toc/extraContent/toc2.xml" primary="true"/> + <toc file="data/help/toc/extraContent/simple_toc.xml" /> <toc file="data/help/search/toc.xml" primary="true"/> </extension> |