mirror of https://github.com/stretchr/testify.git
added 'assert' description
parent
676b7d5fcc
commit
58aae6cc44
19
README.md
19
README.md
|
@ -3,8 +3,23 @@ Testify - Thou shalt write tests
|
||||||
|
|
||||||
Go code (golang) set of packages that provide many tools for testifying that your code will behave as you intend.
|
Go code (golang) set of packages that provide many tools for testifying that your code will behave as you intend.
|
||||||
|
|
||||||
* Mocking
|
|
||||||
* Easy assertions
|
* Easy assertions
|
||||||
* HTTP mocking
|
* Mocking
|
||||||
|
* HTTP response trapping
|
||||||
|
|
||||||
Read the API documentation: http://go.pkgdoc.org/github.com/stretchrcom/tetify
|
Read the API documentation: http://go.pkgdoc.org/github.com/stretchrcom/tetify
|
||||||
|
|
||||||
|
Assert package
|
||||||
|
--------------
|
||||||
|
|
||||||
|
The `assert` package provides some helpful methods that allow you to write better test code in Go.
|
||||||
|
|
||||||
|
Some examples:
|
||||||
|
|
||||||
|
func TestSomething(t *testing.T) {
|
||||||
|
|
||||||
|
assert.Equal(t, 123, 123, "they should be equal")
|
||||||
|
assert.NotNil(t, object)
|
||||||
|
assert.Nil(t, object)
|
||||||
|
|
||||||
|
}
|
Loading…
Reference in New Issue