From dc7535c63e4bdb78fe9ee92a866eab07658f2d8e Mon Sep 17 00:00:00 2001 From: jackyq2015 Date: Thu, 6 Aug 2015 21:31:37 -0400 Subject: [PATCH 1/2] 1. take out of issue #1021 fix which was mistakenly put in 2. fix the expected value for JUNIT --- .../com/google/refine/exporters/HtmlTableExporter.java | 7 +++++-- .../google/refine/tests/exporters/HtmlExporterTests.java | 8 ++++++-- 2 files changed, 11 insertions(+), 4 deletions(-) diff --git a/main/src/com/google/refine/exporters/HtmlTableExporter.java b/main/src/com/google/refine/exporters/HtmlTableExporter.java index 2f14ba12c..1c4163ee2 100644 --- a/main/src/com/google/refine/exporters/HtmlTableExporter.java +++ b/main/src/com/google/refine/exporters/HtmlTableExporter.java @@ -61,9 +61,12 @@ public class HtmlTableExporter implements WriterExporter { public void startFile(JSONObject options) { try { writer.write("\n"); - writer.write(""); + writer.write("<head>\n"); + writer.write("<title>"); writer.write(ProjectManager.singleton.getProjectMetadata(project.id).getName()); - writer.write("\n"); + writer.write("\n"); + writer.write("\n"); + writer.write("\n"); writer.write("\n"); writer.write("\n"); diff --git a/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java b/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java index bf3fbd50d..29fc4cb33 100644 --- a/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java +++ b/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java @@ -117,7 +117,9 @@ public class HtmlExporterTests extends RefineTest { } Assert.assertEquals(writer.toString(), "\n" + - "" + TEST_PROJECT_NAME + "\n" + + "" + TEST_PROJECT_NAME + "" + + "\n" + + "\n" + "\n" + "
\n" + "\n" + @@ -142,7 +144,9 @@ public class HtmlExporterTests extends RefineTest { } Assert.assertEquals(writer.toString(), "\n" + - "" + TEST_PROJECT_NAME + "\n" + + "" + TEST_PROJECT_NAME + "" + + "\n" + + "\n" + "\n" + "
column0column1
\n" + "\n" + From a89dc7c25a24c71c66c9ec028e21397f0fa1801b Mon Sep 17 00:00:00 2001 From: jackyq2015 Date: Thu, 6 Aug 2015 22:27:20 -0400 Subject: [PATCH 2/2] fix the junit issue --- .../google/refine/tests/exporters/HtmlExporterTests.java | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java b/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java index 29fc4cb33..47b38ca0e 100644 --- a/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java +++ b/main/tests/server/src/com/google/refine/tests/exporters/HtmlExporterTests.java @@ -117,7 +117,7 @@ public class HtmlExporterTests extends RefineTest { } Assert.assertEquals(writer.toString(), "\n" + - "" + TEST_PROJECT_NAME + "" + + "\n" + "" + TEST_PROJECT_NAME + "\n" + "\n" + "\n" + "\n" + @@ -144,7 +144,7 @@ public class HtmlExporterTests extends RefineTest { } Assert.assertEquals(writer.toString(), "\n" + - "" + TEST_PROJECT_NAME + "" + + "\n" + "" + TEST_PROJECT_NAME + "\n" + "\n" + "\n" + "\n" + @@ -171,7 +171,9 @@ public class HtmlExporterTests extends RefineTest { } Assert.assertEquals(writer.toString(), "\n" + - "" + TEST_PROJECT_NAME + "\n" + + "\n" + "" + TEST_PROJECT_NAME + "\n" + + "\n" + + "\n" + "\n" + "
row0cell0row0cell1
\n" + "\n" +
column0column1column2