Fixed special characters not showing up on apges

This commit is contained in:
2017-10-11 18:01:01 +02:00
parent 60c6df5bbf
commit 4b814cedad
2 changed files with 15 additions and 2 deletions
+13 -1
View File
@@ -1,6 +1,7 @@
package model
import (
"fmt"
"net/url"
"testing"
"time"
@@ -29,7 +30,6 @@ var testPage = Page{
FictionalDate: fictionalDate,
PublishDate: postingDate,
EditDate: editDate,
Dated: true,
Published: true,
Unlisted: false,
Specific: false,
@@ -262,6 +262,18 @@ func TestPage(t *testing.T) {
assertEquals(t, "page.Content()", string(content), "<h1>Returning Va’ynna’s Omni-Tool</h1>\n\n<p>Additional Content is additional</p>\n")
})
t.Run("ContentSpecial", func(t *testing.T) {
page := Page{Source: "Husarskie Anioły win the EUCC 2175", Type: "Markdown"}
content, err := page.Content()
if err != nil {
t.Errorf("page.Content: %s", err)
}
t.Log(string(content))
assertEquals(t, "page.Content()", string(content), fmt.Sprintf("<p>%s</p>\n", page.Source))
})
t.Run("WikiURL", func(t *testing.T) {
t.Skip("To be implemented")
})