MCPcopy Create free account
hub / github.com/conforma/cli / Test_SetupStatePersisted

Function Test_SetupStatePersisted

acceptance/testenv/testenv_test.go:69–78  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

67}
68
69func Test_SetupStatePersisted(t *testing.T) {
70 var s *stateful
71 ctx, err := SetupState(context.TODO(), &s)
72
73 assert.NoError(t, err)
74
75 expected := stateful{Number: 0, Str: ""}
76 assert.Equal(t, expected, *s)
77 assert.Equal(t, &expected, FetchState[stateful](ctx))
78}
79
80func Test_SetupStatePersistedTwoTypes(t *testing.T) {
81 var s *stateful

Callers

nothing calls this directly

Calls 1

SetupStateFunction · 0.85

Tested by

no test coverage detected