func (s *MySuite) TestMyFunction(c *C) { result := myFunction(3, 4) c.Assert(result, Equals, 7) }
func (s *MySuite) TestMyBoolean(c *C) { result := myBooleanFunction() c.Assert(result, Equals, true) }
func (s *MySuite) TestMyNil(c *C) { result := myNilFunction() c.Assert(result, IsNil) }In addition to assertions, gocheck also provides some helpful utility functions. For example, the SetUpSuite function can be used to set up any necessary state before running a suite of tests. Similarly, the TearDownSuite function can be used to tear down that state after the tests are complete. Overall, gocheck is a powerful testing framework for Go that can help make writing and debugging tests easier and more efficient.