MCPcopy Index your code
hub / github.com/jetify-com/devbox / newGithubPluginForTest

Function newGithubPluginForTest

internal/plugin/github_test.go:92–105  ·  view source on GitHub ↗

keep in sync with newGithubPlugin

(include string)

Source from the content-addressed store, hash-verified

90
91// keep in sync with newGithubPlugin
92func newGithubPluginForTest(include string) (*githubPlugin, error) {
93 ref, err := flake.ParseRef(include)
94 if err != nil {
95 return nil, err
96 }
97
98 plugin := &githubPlugin{ref: ref}
99 name := strings.ReplaceAll(ref.Dir, "/", "-")
100 plugin.name = githubNameRegexp.ReplaceAllString(
101 strings.Join(lo.Compact([]string{ref.Owner, ref.Repo, name}), "."),
102 " ",
103 )
104 return plugin, nil
105}
106
107func TestGithubPluginAuth(t *testing.T) {
108 githubPlugin := githubPlugin{

Callers 1

TestNewGithubPluginFunction · 0.85

Calls 1

ParseRefFunction · 0.92

Tested by

no test coverage detected