Skip to content

Commit 8991083

Browse files
icholyclaude
andcommitted
Add test for file:// URL in GOPROXY environment variable
🤖 Generated with [Claude Code](https://claude.ai/code) Co-Authored-By: Claude <[email protected]>
1 parent 0f1137b commit 8991083

File tree

1 file changed

+5
-0
lines changed

1 file changed

+5
-0
lines changed

internal/goenv/goenv_test.go

Lines changed: 5 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -75,6 +75,11 @@ func TestGOPROXYURL(t *testing.T) {
7575
setenv: "https://proxy.golang.org,,direct, ,https://custom.proxy.com",
7676
want: []*url.URL{{Scheme: "https", Host: "proxy.golang.org"}, {Scheme: "https", Host: "custom.proxy.com"}},
7777
},
78+
{
79+
name: "file:// proxy URL",
80+
setenv: "file:///path/to/modules,https://proxy.golang.org",
81+
want: []*url.URL{{Scheme: "file", Path: "/path/to/modules"}, {Scheme: "https", Host: "proxy.golang.org"}},
82+
},
7883
}
7984
for _, tt := range tests {
8085
t.Run(tt.name, func(t *testing.T) {

0 commit comments

Comments
 (0)