From e7b5b55f6718b25a437a891a06a26c21384b6818 Mon Sep 17 00:00:00 2001 From: Brian Picciano Date: Wed, 18 Jan 2023 20:15:12 +0100 Subject: Add format column to post tables --- src/post/post_test.go | 10 ++++++---- 1 file changed, 6 insertions(+), 4 deletions(-) (limited to 'src/post/post_test.go') 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) -- cgit v1.2.3