mirror of
https://github.com/pomerium/pomerium.git
synced 2025-06-27 06:58:13 +02:00
config: use config.Config instead of config.Options everywhere
This commit is contained in:
parent
5f51510e91
commit
1b80e8a6c2
40 changed files with 484 additions and 412 deletions
|
@ -74,7 +74,7 @@ func TestNew(t *testing.T) {
|
|||
tt := tt
|
||||
t.Run(tt.name, func(t *testing.T) {
|
||||
t.Parallel()
|
||||
_, err := New(&config.Config{Options: &tt.config})
|
||||
_, err := New(config.New(&tt.config))
|
||||
if (err != nil) != tt.wantErr {
|
||||
t.Errorf("New() error = %v, wantErr %v", err, tt.wantErr)
|
||||
return
|
||||
|
@ -105,12 +105,12 @@ func TestAuthorize_OnConfigChange(t *testing.T) {
|
|||
SharedKey: tc.SharedKey,
|
||||
Policies: tc.Policies,
|
||||
}
|
||||
a, err := New(&config.Config{Options: o})
|
||||
a, err := New(config.New(o))
|
||||
require.NoError(t, err)
|
||||
require.NotNil(t, a)
|
||||
|
||||
oldPe := a.state.Load().evaluator
|
||||
cfg := &config.Config{Options: o}
|
||||
cfg := config.New(o)
|
||||
assertFunc := assert.True
|
||||
o.SigningKey = "bad-share-key"
|
||||
if tc.expectedChange {
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue