mirror of
https://github.com/containers/skopeo.git
synced 2025-08-13 20:25:38 +00:00
Add --registry-token tests to utils_tests.go
Signed-off-by: Alvaro Iradier <airadier@gmail.com>
This commit is contained in:
parent
3c73c0c0cd
commit
2d5f12b9a6
@ -54,6 +54,7 @@ func TestImageOptionsNewSystemContext(t *testing.T) {
|
||||
"--dest-daemon-host", "daemon-host.example.com",
|
||||
"--dest-tls-verify=false",
|
||||
"--dest-creds", "creds-user:creds-password",
|
||||
"--dest-registry-token", "faketoken",
|
||||
})
|
||||
res, err = opts.newSystemContext()
|
||||
require.NoError(t, err)
|
||||
@ -71,6 +72,7 @@ func TestImageOptionsNewSystemContext(t *testing.T) {
|
||||
DockerDaemonHost: "daemon-host.example.com",
|
||||
DockerDaemonInsecureSkipTLSVerify: true,
|
||||
BigFilesTemporaryDir: "/srv",
|
||||
DockerBearerRegistryToken: "faketoken",
|
||||
}, res)
|
||||
|
||||
// Global/per-command tlsVerify behavior
|
||||
@ -164,6 +166,7 @@ func TestImageDestOptionsNewSystemContext(t *testing.T) {
|
||||
"--dest-daemon-host", "daemon-host.example.com",
|
||||
"--dest-tls-verify=false",
|
||||
"--dest-creds", "creds-user:creds-password",
|
||||
"--dest-registry-token", "faketoken",
|
||||
})
|
||||
res, err = opts.newSystemContext()
|
||||
require.NoError(t, err)
|
||||
@ -182,6 +185,7 @@ func TestImageDestOptionsNewSystemContext(t *testing.T) {
|
||||
DockerDaemonInsecureSkipTLSVerify: true,
|
||||
DirForceCompress: true,
|
||||
BigFilesTemporaryDir: "/srv",
|
||||
DockerBearerRegistryToken: "faketoken",
|
||||
}, res)
|
||||
|
||||
// Invalid option values in imageOptions
|
||||
|
Loading…
Reference in New Issue
Block a user