aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorShulhan <ms@kilabit.info>2022-07-24 19:33:09 +0700
committerShulhan <ms@kilabit.info>2022-07-24 19:34:55 +0700
commit4f2549fb0f3f71ca1e1d1f2b3e80a52887dd616b (patch)
tree82974904ab601af8eccd59ddaf676990b8ed4fda
parent35bf7c2a9ebaae85a8f7980f2842c328525ee938 (diff)
downloadasciidoctor-go-4f2549fb0f3f71ca1e1d1f2b3e80a52887dd616b.tar.xz
all: rename the HTML output for test-parser
The HTML output file from asciidoctor is renamed to test.exp.html, and HTML output file from this library is renamed to test.got.html. The test.html in testdata is generated from ciigo, when running "make serve-doc".
-rw-r--r--.gitignore8
-rw-r--r--Makefile4
-rw-r--r--README4
-rw-r--r--document_test.go2
-rw-r--r--testdata/test.exp.html (renamed from testdata/test.html)0
-rw-r--r--testdata/test.got.html (renamed from testdata/got.test.html)0
6 files changed, 11 insertions, 7 deletions
diff --git a/.gitignore b/.gitignore
index 561d23f..854ac09 100644
--- a/.gitignore
+++ b/.gitignore
@@ -1,5 +1,7 @@
// SPDX-FileCopyrightText: 2020 M. Shulhan <ms@kilabit.info>
// SPDX-License-Identifier: GPL-3.0-or-later
-*.html
-cover.html
-cover.out
+/*.html
+/cover.html
+/cover.out
+/testdata/*.html
+/testdata/_includes/*.html
diff --git a/Makefile b/Makefile
index fff4d50..69792b0 100644
--- a/Makefile
+++ b/Makefile
@@ -14,7 +14,9 @@ test:
go tool cover -html=cover.out -o cover.html
test-parser:
- asciidoctor --attribute stylesheet=empty.css testdata/test.adoc
+ asciidoctor --attribute stylesheet=empty.css \
+ --out-file=testdata/test.exp.html \
+ testdata/test.adoc
go test -v -run=Open .
serve-doc:
diff --git a/README b/README
index 4facb43..fc132f2 100644
--- a/README
+++ b/README
@@ -216,5 +216,5 @@ link:CHANGELOG.html[Changelog].
The following files compare the HTML generated by asciidoctor and this
library:
-* link:testdata/test.html[HTML file generated using asciidoctor^]
-* link:testdata/got.test.html[HTML file using this library^]
+* link:testdata/test.exp.html[HTML file generated using asciidoctor^]
+* link:testdata/test.got.html[HTML file using this library^]
diff --git a/document_test.go b/document_test.go
index 377dd49..c95aa7c 100644
--- a/document_test.go
+++ b/document_test.go
@@ -22,7 +22,7 @@ func TestOpen(t *testing.T) {
t.Fatal(err)
}
- fout, err = os.OpenFile("testdata/got.test.html",
+ fout, err = os.OpenFile("testdata/test.got.html",
os.O_RDWR|os.O_CREATE|os.O_TRUNC, 0600)
if err != nil {
t.Fatal(err)
diff --git a/testdata/test.html b/testdata/test.exp.html
index ba7dbd6..ba7dbd6 100644
--- a/testdata/test.html
+++ b/testdata/test.exp.html
diff --git a/testdata/got.test.html b/testdata/test.got.html
index 54bc7b3..54bc7b3 100644
--- a/testdata/got.test.html
+++ b/testdata/test.got.html