r692 - branches/jrst-docutils-jython/jrst/src/test/java/org/nuiton/jrst
Author: jpages Date: 2012-05-31 11:08:57 +0200 (Thu, 31 May 2012) New Revision: 692 Url: http://nuiton.org/repositories/revision/jrst/692 Log: Suppression du test generateRst qui n'a plus lieu d'?\195?\170tre. Modified: branches/jrst-docutils-jython/jrst/src/test/java/org/nuiton/jrst/JRSTTest.java Modified: branches/jrst-docutils-jython/jrst/src/test/java/org/nuiton/jrst/JRSTTest.java =================================================================== --- branches/jrst-docutils-jython/jrst/src/test/java/org/nuiton/jrst/JRSTTest.java 2012-05-31 08:49:47 UTC (rev 691) +++ branches/jrst-docutils-jython/jrst/src/test/java/org/nuiton/jrst/JRSTTest.java 2012-05-31 09:08:57 UTC (rev 692) @@ -58,64 +58,10 @@ Assert.assertNotNull(Resource.getURL(JRST.DOCBOOK_2_XHTML)); Assert.assertNotNull(Resource.getURL(JRST.DOCBOOK_2_JAVAHELP)); Assert.assertNotNull(Resource.getURL(JRST.DOCBOOK_2_HTMLHELP)); - //FIXME echatellier 20110217 following assert fails - //Assert.assertNotNull(Resource.getURL(JRST.docbook2odf)); Assert.assertNotNull(Resource.getURL(JRST.DOCBOOK_2_FO)); } - @Ignore @Test - public void generateRst() throws Exception { - File in = new File(testWorkDir, "toRst1-in.rst"); - - List<String> IN_LINES = Arrays.asList(new String[]{ - "=====", - "Title", - "=====", - "", - "SubTitle", - "--------", - "", - ".. topic:: TopicTitle", - "", - " TopicBody.", - "", - "", - "Another body outside of the topic :)" - }); - List<String> OUT_LINES = Arrays.asList(new String[]{ - "Title", - "-----", - // "", - "SubTitle", - "--------", - // "", - ".. topic:: TopicTitle", - // "", - " TopicBody.", - // "", - // "", - "Another body outside of the topic :)" - }); - - FileUtils.writeLines(in, IN_LINES); - - File out = new File(testWorkDir, "toRst1-out.rst"); - - JRST.generate(JRST.TYPE_RST, in, out, JRST.Overwrite.ALLTIME); - - List<?> readLines = FileUtils.readLines(out); - log.info(OUT_LINES); - log.info(readLines); - Assert.assertEquals(OUT_LINES.size(), readLines.size()); - for (int i = 0, j = OUT_LINES.size(); i < j; i++) { - String inLine = OUT_LINES.get(i); - String outLine = (String) readLines.get(i); - Assert.assertEquals(inLine, outLine); - } - } - - @Test public void generateXml() throws Exception { File in = getTestFile("text.rst");
participants (1)
-
jpages@users.nuiton.org