MCPcopy
hub / github.com/stretchr/testify / TestIsType

Function TestIsType

assert/assertions_test.go:562–573  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

560}
561
562func TestIsType(t *testing.T) {
563 t.Parallel()
564
565 mockT := new(testing.T)
566
567 if !IsType(mockT, new(AssertionTesterConformingObject), new(AssertionTesterConformingObject)) {
568 t.Error("IsType should return true: AssertionTesterConformingObject is the same type as AssertionTesterConformingObject")
569 }
570 if IsType(mockT, new(AssertionTesterConformingObject), new(AssertionTesterNonConformingObject)) {
571 t.Error("IsType should return false: AssertionTesterConformingObject is not the same type as AssertionTesterNonConformingObject")
572 }
573}
574
575func TestNotIsType(t *testing.T) {
576 t.Parallel()

Callers

nothing calls this directly

Calls 2

IsTypeFunction · 0.70
ErrorMethod · 0.45

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…