diff options
author | Brian Picciano <mediocregopher@gmail.com> | 2023-01-18 20:15:12 +0100 |
---|---|---|
committer | Brian Picciano <mediocregopher@gmail.com> | 2023-01-18 20:15:12 +0100 |
commit | e7b5b55f6718b25a437a891a06a26c21384b6818 (patch) | |
tree | 6c95d222f00806e2d3b335bfd0d04c4be34c740f /src/post/post_test.go | |
parent | 4878495914fb9701bedc242eb5087394138c8ee3 (diff) |
Add format column to post tables
Diffstat (limited to 'src/post/post_test.go')
-rw-r--r-- | src/post/post_test.go | 10 |
1 files changed, 6 insertions, 4 deletions
diff --git a/src/post/post_test.go b/src/post/post_test.go index 7e87200..4c7f517 100644 --- a/src/post/post_test.go +++ b/src/post/post_test.go @@ -37,9 +37,10 @@ func TestNewID(t *testing.T) { func testPost(i int) Post { istr := strconv.Itoa(i) return Post{ - ID: istr, - Title: istr, - Body: istr, + ID: istr, + Title: istr, + Body: istr, + Format: FormatMarkdown, } } @@ -108,7 +109,7 @@ func TestStore(t *testing.T) { post.Tags = []string{"foo", "bar"} first, err := h.store.Set(post, now) - assert.NoError(t, err) + assert.NoError(t, err, "post:%+v", post) assert.True(t, first) gotPost, err := h.store.GetByID(post.ID) @@ -130,6 +131,7 @@ func TestStore(t *testing.T) { post.Series = "whatever" post.Body = "anything" post.Tags = []string{"bar", "baz"} + post.Format = FormatGemtext first, err = h.store.Set(post, newNow) assert.NoError(t, err) |