weldr/api_test: don't access what should be private Store fields
In a follow-up these will be made private. Signed-off-by: Tom Gundersen <teg@jklm.no>
This commit is contained in:
parent
e5b3e737b6
commit
4c4bad5444
1 changed files with 5 additions and 3 deletions
|
|
@ -521,11 +521,13 @@ func TestCompose(t *testing.T) {
|
|||
continue
|
||||
}
|
||||
|
||||
require.Equalf(t, 1, len(s.Composes), "%s: bad compose count in store", c.Path)
|
||||
composes := s.GetAllComposes()
|
||||
|
||||
require.Equalf(t, 1, len(composes), "%s: bad compose count in store", c.Path)
|
||||
|
||||
// I have no idea how to get the compose in better way
|
||||
var composeStruct compose.Compose
|
||||
for _, c := range s.Composes {
|
||||
for _, c := range composes {
|
||||
composeStruct = c
|
||||
break
|
||||
}
|
||||
|
|
@ -564,7 +566,7 @@ func TestComposeDelete(t *testing.T) {
|
|||
|
||||
idsInStore := []string{}
|
||||
|
||||
for id := range s.Composes {
|
||||
for id := range s.GetAllComposes() {
|
||||
idsInStore = append(idsInStore, id.String())
|
||||
}
|
||||
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue