1package main
2
3import (
4 "std"
5
6 "gno.land/p/demo/testutils"
7 "gno.land/r/gnoland/home"
8)
9
10func main() {
11 std.TestSetOrigCaller("g1manfred47kzduec920z88wfr64ylksmdcedlf5")
12 home.AdminSetOverride("Hello World!")
13 println(home.Render(""))
14 home.AdminTransferOwnership(testutils.TestAddress("newAdmin"))
15 defer func() {
16 r := recover()
17 println("r: ", r)
18 }()
19 home.AdminSetOverride("Not admin anymore")
20}
21
22// Output:
23// Hello World!
24// r: ownable: caller is not owner
overide_filetest.gno
0.46 Kb ยท 24 lines