Skip to content

Commit

Permalink
Issue #442, updated to 0.7.0.beta.1 with auto-upgrade policy
Browse files Browse the repository at this point in the history
Signed-off-by: Phil Hunt <[email protected]>
  • Loading branch information
independentid committed Sep 12, 2024
1 parent baa5569 commit 6abd653
Show file tree
Hide file tree
Showing 4 changed files with 7 additions and 3 deletions.
2 changes: 1 addition & 1 deletion demo/go.mod
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ require (
github.com/MicahParks/keyfunc/v3 v3.3.3
github.com/aws/aws-sdk-go-v2 v1.30.5
github.com/gorilla/mux v1.8.1
github.com/hexa-org/policy-mapper v0.7.0-alpha.2
github.com/hexa-org/policy-mapper v0.7.0-beta.1
github.com/stretchr/testify v1.9.0
golang.org/x/exp v0.0.0-20240909161429-701f63a606c0
golang.org/x/oauth2 v0.23.0
Expand Down
4 changes: 4 additions & 0 deletions demo/go.sum
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
cloud.google.com/go v0.26.0/go.mod h1:aQUYkXzVsufM+DwF1aE+0xfcU+56JwCaLick0ClmMTw=
cloud.google.com/go v0.115.1 h1:Jo0SM9cQnSkYfp44+v+NQXHpcHqlnRJk2qxh6yvxxxQ=
cloud.google.com/go/auth v0.9.4 h1:DxF7imbEbiFu9+zdKC6cKBko1e8XeJnipNqIbWZ+kDI=
cloud.google.com/go/auth v0.9.4/go.mod h1:SHia8n6//Ya940F1rLimhJCjjx7KE17t0ctFEci3HkA=
cloud.google.com/go/auth/oauth2adapt v0.2.4 h1:0GWE/FUsXhf6C+jAkWgYm7X9tK8cuEIfy19DBn6B6bY=
Expand Down Expand Up @@ -157,6 +158,8 @@ github.com/gorilla/mux v1.8.1 h1:TuBL49tXwgrFYWhqrNgrUNEY92u81SPhu7sTdzQEiWY=
github.com/gorilla/mux v1.8.1/go.mod h1:AKf9I4AEqPTmMytcMc0KkNouC66V3BtZ4qD5fmWSiMQ=
github.com/hexa-org/policy-mapper v0.7.0-alpha.2 h1:LHZoCTgpS53IhEeyuR00nLPp3KY4kA3klpSM+IrLTgA=
github.com/hexa-org/policy-mapper v0.7.0-alpha.2/go.mod h1:RMF+I1t2Wc5tRmy5mYiHjDww+ZzPEe/mA2xITGyyKRQ=
github.com/hexa-org/policy-mapper v0.7.0-beta.1 h1:S8GKCr3SGXpTM2bZ1/QqTgw51NZrtD+h/VAAe5dgo2w=
github.com/hexa-org/policy-mapper v0.7.0-beta.1/go.mod h1:33x2pYgNIy/SB2RrAb5E+YouDkpvPnjGvcqiYph3zlw=
github.com/hexops/gotextdiff v1.0.3 h1:gitA9+qJrrTCsiCl7+kh75nPqQt1cx4ZkudSTLoUqJM=
github.com/hexops/gotextdiff v1.0.3/go.mod h1:pSWU5MAI3yDq+fZBTazCSJysOMbxWL1BSow5/V2vxeg=
github.com/hhsnopek/etag v0.0.0-20171206181245-aea95f647346 h1:Odeq5rB6OZSkib5gqTG+EM1iF0bUVjYYd33XB1ULv00=
Expand Down Expand Up @@ -273,6 +276,7 @@ google.golang.org/appengine v1.4.0/go.mod h1:xpcJRLb0r/rnEns0DIKYYv+WjYCduHsrkT7
google.golang.org/genproto v0.0.0-20180817151627-c66870c02cf8/go.mod h1:JiN7NxoALGmiZfu7CAH4rXhgtRTLTxftemlI0sWmxmc=
google.golang.org/genproto v0.0.0-20190819201941-24fa4b261c55/go.mod h1:DMBHOl98Agz4BDEuKkezgsaosCRResVns1a3J2ZsMNc=
google.golang.org/genproto v0.0.0-20200526211855-cb27e3aa2013/go.mod h1:NbSheEEYHJ7i3ixzK3sjbqSGDJWnxyFXZblF3eUsNvo=
google.golang.org/genproto v0.0.0-20240903143218-8af14fe29dc1 h1:BulPr26Jqjnd4eYDVe+YvyR7Yc2vJGkO5/0UxD0/jZU=
google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1 h1:hjSy6tcFQZ171igDaN5QHOw2n6vx40juYbC/x67CEhc=
google.golang.org/genproto/googleapis/api v0.0.0-20240903143218-8af14fe29dc1/go.mod h1:qpvKtACPCQhAdu3PyQgV4l3LMXZEtft7y8QcarRsp9I=
google.golang.org/genproto/googleapis/rpc v0.0.0-20240903143218-8af14fe29dc1 h1:pPJltXNxVzT4pK9yD8vR9X75DaWYYmLGMsEvBfFQZzQ=
Expand Down
2 changes: 1 addition & 1 deletion demo/internal/admin/orchestrator_client_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -218,7 +218,7 @@ func TestOrchestratorClient_GetPolicy(t *testing.T) {

resp, raw, _ := client.GetPolicies("anId")
assert.Equal(t, rawJson, raw)
assert.Equal(t, "aVersion", resp[0].Meta.Version)
assert.Equal(t, hexapolicy.IdqlVersion, resp[0].Meta.Version)
assert.Equal(t, "anAction", resp[0].Actions[0].String())
assert.Equal(t, []string{"aUser"}, resp[0].Subjects.String())
assert.Equal(t, "aResourceId", resp[0].Object.String())
Expand Down
2 changes: 1 addition & 1 deletion demo/internal/orchestrator/applications_handler_test.go
Original file line number Diff line number Diff line change
Expand Up @@ -196,7 +196,7 @@ func TestGetPolicies(t *testing.T) {

policy := policies.Policies[0]
assert.Equal(t, "anAction", policy.Actions[0].String())
assert.Equal(t, "aVersion", policy.Meta.Version)
assert.Equal(t, hexapolicy.IdqlVersion, policy.Meta.Version)
assert.Equal(t, []string{"user:aUser"}, policy.Subjects.String())
assert.Equal(t, "anId", policy.Object.String())
})
Expand Down

0 comments on commit 6abd653

Please sign in to comment.