forked from TrueCloudLab/restic
b2/s3: Move config validation from ApplyEnvironment to Open/Create
Conceptually the backend configuration should be validated when creating or opening the backend, but not when filling in information from environment variables into the configuration.
This commit is contained in:
parent
19ac12d95b
commit
3a3cf608f5
12 changed files with 23 additions and 45 deletions
|
@ -35,11 +35,7 @@ func newAzureTestSuite(t testing.TB) *test.Suite[azure.Config] {
|
|||
return nil, err
|
||||
}
|
||||
|
||||
err = cfg.ApplyEnvironment("RESTIC_TEST_")
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
||||
cfg.ApplyEnvironment("RESTIC_TEST_")
|
||||
cfg.Prefix = fmt.Sprintf("test-%d", time.Now().UnixNano())
|
||||
return cfg, nil
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue