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

Function TestUnInitializedSuites

suite/suite_test.go:737–753  ·  view source on GitHub ↗

TestUnInitializedSuites asserts the behavior of the suite methods when the suite is not initialized

(t *testing.T)

Source from the content-addressed store, hash-verified

735// TestUnInitializedSuites asserts the behavior of the suite methods when the
736// suite is not initialized
737func TestUnInitializedSuites(t *testing.T) {
738 t.Run("should panic on Require", func(t *testing.T) {
739 suite := new(unInitializedSuite)
740
741 assert.Panics(t, func() {
742 suite.Require().True(true)
743 })
744 })
745
746 t.Run("should panic on Assert", func(t *testing.T) {
747 suite := new(unInitializedSuite)
748
749 assert.Panics(t, func() {
750 suite.Assert().True(true)
751 })
752 })
753}

Callers

nothing calls this directly

Calls 5

PanicsFunction · 0.92
RequireMethod · 0.80
RunMethod · 0.45
TrueMethod · 0.45
AssertMethod · 0.45

Tested by

no test coverage detected