Skip to content

Commit

Permalink
Merge pull request #987 from vdice/fix/migrate-claims-test
Browse files Browse the repository at this point in the history
fix(migrateClaimsWrapper_test.go): sort list before validation
  • Loading branch information
carolynvs-msft authored Apr 15, 2020
2 parents 4546701 + d9beeb0 commit 7fc3943
Showing 1 changed file with 3 additions and 1 deletion.
4 changes: 3 additions & 1 deletion pkg/claims/migrateClaimsWrapper_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@ package claims
import (
"fmt"
"io/ioutil"
"sort"
"testing"

"get.porter.sh/porter/pkg/context"
Expand Down Expand Up @@ -56,8 +57,9 @@ func TestMigrateClaimsWrapper_List(t *testing.T) {
loadTestClaim(t, "migrated", dataStore)

names, err := claimStore.List()
sort.Strings(names)
require.NoError(t, err, "could not list claims")
assert.Equal(t, []string{"unmigrated", "migrated"}, names, "unexpected list of claim installation names")
assert.Equal(t, []string{"migrated", "unmigrated"}, names, "unexpected list of claim installation names")
}

func loadTestClaim(t *testing.T, claimName string, store crud.Store) {
Expand Down

0 comments on commit 7fc3943

Please sign in to comment.