mirror of
https://github.com/edgelesssys/constellation.git
synced 2025-05-04 07:15:05 -04:00
AB#2512 Config secrets via env var & config refactoring (#544)
* refactor measurements to use consistent types and less byte pushing * refactor: only rely on a single multierr dependency * extend config creation with envar support * document changes Signed-off-by: Fabian Kammel <fk@edgeless.systems>
This commit is contained in:
parent
80a801629e
commit
bb76a4e4c8
42 changed files with 932 additions and 791 deletions
|
@ -13,6 +13,7 @@ import (
|
|||
"errors"
|
||||
"testing"
|
||||
|
||||
"github.com/edgelesssys/constellation/v2/internal/attestation/measurements"
|
||||
"github.com/edgelesssys/constellation/v2/internal/constants"
|
||||
"github.com/stretchr/testify/assert"
|
||||
"github.com/stretchr/testify/require"
|
||||
|
@ -24,7 +25,7 @@ func TestUpdateMeasurements(t *testing.T) {
|
|||
someErr := errors.New("error")
|
||||
testCases := map[string]struct {
|
||||
updater *stubMeasurementsUpdater
|
||||
newMeasurements map[uint32][]byte
|
||||
newMeasurements measurements.M
|
||||
wantUpdate bool
|
||||
wantErr bool
|
||||
}{
|
||||
|
@ -36,7 +37,7 @@ func TestUpdateMeasurements(t *testing.T) {
|
|||
},
|
||||
},
|
||||
},
|
||||
newMeasurements: map[uint32][]byte{
|
||||
newMeasurements: measurements.M{
|
||||
0: []byte("1"),
|
||||
},
|
||||
wantUpdate: true,
|
||||
|
@ -49,7 +50,7 @@ func TestUpdateMeasurements(t *testing.T) {
|
|||
},
|
||||
},
|
||||
},
|
||||
newMeasurements: map[uint32][]byte{
|
||||
newMeasurements: measurements.M{
|
||||
0: []byte("1"),
|
||||
},
|
||||
},
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue