package testify
import "github.com/stretchr/testify"
Package testify is a set of packages that provide many tools for testifying that your code will behave as you intend.
testify contains the following packages:
The assert package provides a comprehensive set of assertion functions that tie in to the Go testing system.
The mock package provides a system by which it is possible to mock your objects and verify calls are happening as expected.
The suite package provides a basic structure for using structs as testing suites, and methods on those structs as tests. It includes setup/teardown functionality in the way of interfaces.
A golangci-lint compatible linter for testify is available called testifylint.
Index ¶
Source Files ¶
Directories ¶
Path | Synopsis |
---|---|
assert | Package assert provides a set of comprehensive testing tools for use with the normal Go testing system. |
assert/internal | |
assert/yaml | Package yaml is just an indirection to handle YAML deserialization. |
http | Deprecated: Use net/http/httptest instead. |
mock | Package mock provides a system by which it is possible to mock your objects and verify calls are happening as expected. |
require | Package require implements the same assertions as the `assert` package but stops test execution when a test fails. |
suite | Package suite contains logic for creating testing suite structs and running the methods on those structs as tests. |
- Version
- v1.10.0 (latest)
- Published
- Nov 12, 2024
- Platform
- linux/amd64
- Last checked
- 6 hours ago –
Tools for package owners.