MCPcopy Create free account
hub / github.com/auth0/auth0-cli / TestFindByStack

Function TestFindByStack

internal/auth0/quickstarts_test.go:60–73  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

58}
59
60func TestFindByStack(t *testing.T) {
61 t.Run("find quickstart stack by known app type", func(t *testing.T) {
62 res, err := mockQuickStarts.FindByStack("Express")
63 assert.NoError(t, err)
64 assert.Equal(t, "Express", res.Name)
65 })
66
67 t.Run("find quickstart stack by known app type", func(t *testing.T) {
68 res, err := mockQuickStarts.FindByStack("some-non-existent-qs-type")
69 assert.Error(t, err)
70 assert.Empty(t, res)
71 assert.Equal(t, fmt.Sprintf("failed to find any quickstarts for stack: %q", "some-non-existent-qs-type"), err.Error())
72 })
73}

Callers

nothing calls this directly

Calls 2

FindByStackMethod · 0.80
ErrorMethod · 0.45

Tested by

no test coverage detected