Documentation
¶
Index ¶
- type Assertions
- func (a *Assertions) HasEquivalentSequenceTo(y interface{})
- func (a *Assertions) IsEqualTo(y interface{})
- func (a *Assertions) IsFalse()
- func (a *Assertions) IsGreaterThan(y interface{})
- func (a *Assertions) IsGreaterThanOrEqualTo(y interface{})
- func (a *Assertions) IsLessThan(y interface{})
- func (a *Assertions) IsLessThanOrEqualTo(y interface{})
- func (a *Assertions) IsNil()
- func (a *Assertions) IsNotEqualTo(y interface{})
- func (a *Assertions) IsNotNil()
- func (a *Assertions) IsTrue()
- type Recorder
- type T
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Assertions ¶
type Assertions struct {
// contains filtered or unexported fields
}
Assertions defines a number of assertions that can be made about x.
func That ¶
func That(t T, x interface{}) *Assertions
That returns a new *Assertions using the provided *testing.T and subject, x.
func (*Assertions) HasEquivalentSequenceTo ¶
func (a *Assertions) HasEquivalentSequenceTo(y interface{})
HasEquivalentSequenceTo fails the test if the subject, x, does not have the exact same sequence of values as y. Only for slices.
func (*Assertions) IsEqualTo ¶
func (a *Assertions) IsEqualTo(y interface{})
IsEqualTo fails the test if y is not equal to the subject, x.
func (*Assertions) IsFalse ¶
func (a *Assertions) IsFalse()
IsFalse fails the test if the subject, x, is not a boolean, or is true.
func (*Assertions) IsGreaterThan ¶
func (a *Assertions) IsGreaterThan(y interface{})
IsGreaterThan fails the test if the subject, x, is not greater than y.
func (*Assertions) IsGreaterThanOrEqualTo ¶
func (a *Assertions) IsGreaterThanOrEqualTo(y interface{})
IsGreaterThanOrEqualTo fails the test if the subject, x, is not greater than or equal to y.
func (*Assertions) IsLessThan ¶
func (a *Assertions) IsLessThan(y interface{})
IsLessThan fails the test if the subject, x, is not less than y.
func (*Assertions) IsLessThanOrEqualTo ¶
func (a *Assertions) IsLessThanOrEqualTo(y interface{})
IsLessThanOrEqualTo fails the test if the subject, x, is not less than or equal to y.
func (*Assertions) IsNil ¶
func (a *Assertions) IsNil()
IsNil fails the test if the subject, x, is not nil.
func (*Assertions) IsNotEqualTo ¶
func (a *Assertions) IsNotEqualTo(y interface{})
IsNotEqualTo fails the test if y is equal to the subject, x.
func (*Assertions) IsNotNil ¶
func (a *Assertions) IsNotNil()
IsNotNil fails the test if the subject, x, is nil.
func (*Assertions) IsTrue ¶
func (a *Assertions) IsTrue()
IsTrue fails the test if the subject, x, is not a boolean, or is false.