Skip to content

Commit 2d1fcf2

Browse files
Copilotj143
andauthored
Add edge-case test for @ in registry credentials
Agent-Logs-Url: https://github.com/j143/basic-docker-engine/sessions/9b259d2d-2dd2-4094-849b-5fb1f50355c2 Co-authored-by: j143 <53068787+j143@users.noreply.github.com>
1 parent b439617 commit 2d1fcf2

1 file changed

Lines changed: 6 additions & 0 deletions

File tree

main_test.go

Lines changed: 6 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -164,6 +164,12 @@ func TestResolveRegistry(t *testing.T) {
164164
wantRegistry: "http://localhost:5000/v2/",
165165
wantRepository: "alpine",
166166
},
167+
{
168+
name: "credentialed local registry with @ in username over http",
169+
imageName: "user@domain:password@localhost:5000/alpine:latest",
170+
wantRegistry: "http://localhost:5000/v2/",
171+
wantRepository: "alpine:latest",
172+
},
167173
}
168174

169175
for _, tt := range tests {

0 commit comments

Comments
 (0)