Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

chore(tests): Update test files to work with Docker Compose v2 #82

Merged
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 2 additions & 2 deletions .github/workflows/plugins.yml
Original file line number Diff line number Diff line change
Expand Up @@ -24,8 +24,8 @@ on:
workflow_dispatch:

env:
GO_VERSION: 1.18
GO_LINT_VERSION: v1.51.2
GO_VERSION: 1.21
GO_LINT_VERSION: v1.56.2

jobs:
lint-go:
Expand Down
4 changes: 2 additions & 2 deletions .github/workflows/xp.yml
Original file line number Diff line number Diff line change
Expand Up @@ -25,8 +25,8 @@ on:

env:
ARTIFACT_RETENTION_DAYS: 7
GO_VERSION: 1.18
GO_LINT_VERSION: v1.51.2
GO_VERSION: 1.21
GO_LINT_VERSION: v1.56.2

jobs:
lint-python:
Expand Down
18 changes: 9 additions & 9 deletions Makefile
Original file line number Diff line number Diff line change
Expand Up @@ -59,15 +59,15 @@ generate-api:
# ==================================

local-authz-server:
@docker-compose up -d postgres-auth && docker-compose run keto-server migrate sql -e
@docker-compose up -d keto-server
@docker-compose run keto-server-bootstrap-policies engines acp ory policies import glob /policies/example_policy.json
@docker compose up -d postgres-auth && docker compose run keto-server migrate sql -e
@docker compose up -d keto-server
@docker compose run keto-server-bootstrap-policies engines acp ory policies import glob /policies/example_policy.json

local-db:
@docker-compose up -d postgres
@docker compose up -d postgres

local-pubsub:
@docker-compose up -d pubsub
@docker compose up -d pubsub

.PHONY: mgmt-svc
mgmt-svc: local-authz-server local-db local-pubsub
Expand All @@ -79,7 +79,7 @@ treatment-svc: local-pubsub
cd treatment-service && go run main.go serve

swagger-ui:
@docker-compose up -d swagger-ui
@docker compose up -d swagger-ui
@xdg-open 2>/dev/null http://localhost:8081 || open http://localhost:8081

$(protoc_dir):
Expand All @@ -100,7 +100,7 @@ compile-protos: | $(protoc_dir)
.PHONY: setup
setup:
@echo "> Initializing dependencies ..."
@test -x ${GOPATH}/bin/golangci-lint || go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.51.2
@test -x ${GOPATH}/bin/golangci-lint || go install github.com/golangci/golangci-lint/cmd/golangci-lint@v1.56.2

@echo "Setting up dev tools..."
@test -x "$(which pre-commit)" || pip install pre-commit
Expand Down Expand Up @@ -186,8 +186,8 @@ install-python-ci-dependencies:
pip install -r tests/requirements.txt

e2e: build
docker-compose down
docker-compose up -d postgres pubsub
docker compose down
docker compose up -d postgres pubsub
cd tests/e2e; python -m pytest -s -v

e2e-ci:
Expand Down
10 changes: 6 additions & 4 deletions clients/go.mod
Original file line number Diff line number Diff line change
@@ -1,12 +1,14 @@
module github.com/caraml-dev/xp/clients

go 1.18
go 1.21

toolchain go1.22.3

require (
github.com/caraml-dev/xp/common v0.0.0
github.com/deepmap/oapi-codegen v1.11.0
github.com/pkg/errors v0.9.1
github.com/stretchr/testify v1.8.0
github.com/stretchr/testify v1.9.0
)

require (
Expand All @@ -15,11 +17,11 @@ require (
github.com/ghodss/yaml v1.0.0 // indirect
github.com/go-openapi/jsonpointer v0.19.5 // indirect
github.com/go-openapi/swag v0.21.1 // indirect
github.com/google/uuid v1.3.0 // indirect
github.com/google/uuid v1.6.0 // indirect
github.com/josharian/intern v1.0.0 // indirect
github.com/mailru/easyjson v0.7.7 // indirect
github.com/pmezard/go-difflib v1.0.0 // indirect
github.com/stretchr/objx v0.4.0 // indirect
github.com/stretchr/objx v0.5.2 // indirect
gopkg.in/yaml.v2 v2.4.0 // indirect
gopkg.in/yaml.v3 v3.0.1 // indirect
)
Expand Down
3 changes: 3 additions & 0 deletions clients/go.sum
Original file line number Diff line number Diff line change
Expand Up @@ -37,6 +37,7 @@ github.com/google/go-cmp v0.5.5/go.mod h1:v8dTdLbMG2kIc/vJvl+f65V22dbkXbowE6jgT/
github.com/google/gofuzz v1.0.0/go.mod h1:dBl0BpW6vV/+mYPU4Po3pmUjxk6FQPldtuIdl/M65Eg=
github.com/google/uuid v1.3.0 h1:t6JiXgmwXMjEs8VusXIJk2BXHsn+wx8BZdTaoZ5fu7I=
github.com/google/uuid v1.3.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/google/uuid v1.6.0/go.mod h1:TIyPZe4MgqvfeYDBFedMoGGpEw/LqOeaOT+nhxU+yHo=
github.com/gorilla/mux v1.8.0/go.mod h1:DVbg23sWSpFRCP0SfiEN6jmj59UnW/n46BH5rLB71So=
github.com/josharian/intern v1.0.0 h1:vlS4z54oSdjm0bgjRigI+G1HpF+tI+9rE5LLzOg8HmY=
github.com/josharian/intern v1.0.0/go.mod h1:5DoeVV0s6jJacbCEi61lwdGj/aVlrQvzHFFd8Hwg//Y=
Expand Down Expand Up @@ -88,6 +89,7 @@ github.com/rogpeppe/go-internal v1.8.0/go.mod h1:WmiCO8CzOY8rg0OYDC4/i/2WRWAB6po
github.com/stretchr/objx v0.1.0/go.mod h1:HFkY916IF+rwdDfMAkV7OtwuqBVzrE8GR6GFx+wExME=
github.com/stretchr/objx v0.4.0 h1:M2gUjqZET1qApGOWNSnZ49BAIMX4F/1plDv3+l31EJ4=
github.com/stretchr/objx v0.4.0/go.mod h1:YvHI0jy2hoMjB+UWwv71VJQ9isScKT/TqJzVSSt89Yw=
github.com/stretchr/objx v0.5.2/go.mod h1:FRsXN1f5AsAjCGJKqEizvkpNtU+EGNCLh3NxZ/8L+MA=
github.com/stretchr/testify v1.3.0/go.mod h1:M5WIy9Dh21IEIfnGCwXGc5bZfKNJtfHm1UVUgZn+9EI=
github.com/stretchr/testify v1.4.0/go.mod h1:j7eGeouHqKxXV5pUuKE4zz7dFj8WfuZ+81PSLYec5m4=
github.com/stretchr/testify v1.5.1/go.mod h1:5W2xD1RspED5o8YsWQXVCued0rvSQ+mT+I5cxcmMvtA=
Expand All @@ -96,6 +98,7 @@ github.com/stretchr/testify v1.7.0/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/
github.com/stretchr/testify v1.7.1/go.mod h1:6Fq8oRcR53rry900zMqJjRRixrwX3KX962/h/Wwjteg=
github.com/stretchr/testify v1.8.0 h1:pSgiaMZlXftHpm5L7V1+rVB+AZJydKsMxsQBIJw4PKk=
github.com/stretchr/testify v1.8.0/go.mod h1:yNjHg4UonilssWZ8iaSj1OCr/vHnekPRkoO+kdMU+MU=
github.com/stretchr/testify v1.9.0/go.mod h1:r2ic/lqez/lEtzL7wO/rwa5dbSLXVDPFyf8C91i36aY=
github.com/ugorji/go v1.1.7/go.mod h1:kZn38zHttfInRq0xu/PH0az30d+z6vm202qpg1oXVMw=
github.com/ugorji/go v1.2.7/go.mod h1:nF9osbDWLy6bDVv/Rtoh6QgnvNDpmCalQV5urGCCS6M=
github.com/ugorji/go/codec v1.1.7/go.mod h1:Ax+UKWsSmolVDwsd+7N3ZtXu+yMGCf907BLYF3GoBXY=
Expand Down
Loading
Loading