You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
pact broker client details: eg. pact-ruby-standalone CLI v 0.47.1
Expected behaviour
When a new version of the provider is created and no verification results are published yet, can-i-deploy used with --to should fail and say that there are missing verifications.
First, we create a new version of the provider and tag it:
Next, we want to make sure that this new version has passed verification and can be deployed:
pact-broker can-i-deploy --pacticipant "Example API" --version 4.5.8 --to main
The latter command should fail because there are no verification results for this version of the provider. So it should print something like the following and fail:
Computer says no ¯_(ツ)_/¯
CONSUMER | C.VERSION | PROVIDER | P.VERSION | SUCCESS? | RESULT#
------------|------------|-------------|-----------|----------|--------
Example App | 5556b81... | Example API | ??? | ??? |
Actual behaviour
can-i-deploy passes like there are no consumer to check at all:
Computer says yes \o/
There are no missing dependencies
Steps to reproduce
You can observe this behavior by creating the following docker-compose.yml file and running docker-compose up --exit-code-from test:
version: "3"services:
postgres:
image: postgres:13.3-alpinehealthcheck:
test: psql postgres --command "select 1" -U postgresenvironment:
POSTGRES_USER: postgresPOSTGRES_PASSWORD: postgresPOSTGRES_DB: postgrespact-broker:
image: pactfoundation/pact-broker:2.81.0.1ports:
- 9292:9292depends_on:
- postgresenvironment:
PACT_BROKER_PORT: 9292PACT_BROKER_DATABASE_URL: postgres://postgres:postgres@postgres/postgresPACT_BROKER_LOG_LEVEL: INFOPACT_BROKER_SQL_LOG_LEVEL: DEBUGentrypoint: | /bin/sh -c " sleep 5 # wait for PostgreSQL /pact_broker/entrypoint.sh "test:
image: pactfoundation/pact-cli:0.47.1.0depends_on:
- pact-brokerenvironment:
PACT_BROKER_BASE_URL: http://pact-broker:9292entrypoint: | /bin/sh -xc ' sleep 5 # wait for Pact Broker # First, check that can-i-deploy works fine for existing version pact-broker can-i-deploy --pacticipant "Example API" --version 4fdf20082263d4c5038355a3b734be1c0054d1e1 --to main || exit 1 # Second, create new version of pacticipant to be deployed pact-broker create-version-tag --pacticipant "Example API" --version 4.5.8 --tag rc1 --auto-create-version || exit 1 # Third, make sure that can-i-deploy fails for this new version when used against explicit consumer version pact-broker can-i-deploy --pacticipant "Example API" --version 4.5.8 --pacticipant "Example App" --version 5556b8149bf8bac76bc30f50a8a2dd4c22c85f30 # Fourth, check that can-i-deploy fails for this new version pact-broker can-i-deploy --pacticipant "Example API" --version 4.5.8 --to main && exit 1 '
The test image is the one reproducing the failure and its entrypoint shows the actual steps.
Relevant log files
The logs can be seen by running the docker-compose file.
The text was updated successfully, but these errors were encountered:
Pre issue-raising checklist
I have already (please mark the applicable with an
x
):Software versions
Expected behaviour
When a new version of the provider is created and no verification results are published yet, can-i-deploy used with
--to
should fail and say that there are missing verifications.First, we create a new version of the provider and tag it:
Next, we want to make sure that this new version has passed verification and can be deployed:
The latter command should fail because there are no verification results for this version of the provider. So it should print something like the following and fail:
Actual behaviour
can-i-deploy passes like there are no consumer to check at all:
Steps to reproduce
You can observe this behavior by creating the following
docker-compose.yml
file and runningdocker-compose up --exit-code-from test
:The
test
image is the one reproducing the failure and its entrypoint shows the actual steps.Relevant log files
The logs can be seen by running the docker-compose file.
The text was updated successfully, but these errors were encountered: