1// PKGPATH: gno.land/r/demo/boards_test
2package boards_test
3
4// SEND: 200000000ugnot
5
6import (
7 "std"
8
9 "gno.land/p/demo/testutils"
10 "gno.land/r/demo/boards"
11 "gno.land/r/demo/users"
12)
13
14var bid boards.BoardID
15
16func init() {
17 caller := testutils.TestAddress("caller")
18 std.TestSetRealm(std.NewUserRealm(caller))
19 users.Register("", "gnouser", "my profile")
20 bid = boards.CreateBoard("test_board")
21 boards.CreateReply(bid, 0, 0, "Reply of the second post")
22}
23
24func main() {
25 println(boards.Render("test_board"))
26}
27
28// Error:
29// thread not exist
z_0_d_filetest.gno
0.53 Kb ยท 29 lines