MCPcopy Create free account
hub / github.com/gogs/gogs / TestHTMLURL

Function TestHTMLURL

internal/repoutil/repoutil_test.go:73–83  ·  view source on GitHub ↗
(t *testing.T)

Source from the content-addressed store, hash-verified

71}
72
73func TestHTMLURL(t *testing.T) {
74 conf.SetMockServer(t,
75 conf.ServerOpts{
76 ExternalURL: "https://example.com/",
77 },
78 )
79
80 got := HTMLURL("alice", "example")
81 want := "https://example.com/alice/example"
82 assert.Equal(t, want, got)
83}
84
85func TestCompareCommitsPath(t *testing.T) {
86 got := CompareCommitsPath("alice", "example", "old", "new")

Callers

nothing calls this directly

Calls 2

SetMockServerFunction · 0.92
HTMLURLFunction · 0.85

Tested by

no test coverage detected