fix flaky test that only is flaky on postgres
This commit is contained in:
parent
a03fef847f
commit
e5c363397a
|
@ -29,10 +29,10 @@ if [[ "${1:-}" == "clean" ]]; then
|
|||
if [[ "${SPIFF_DATABASE_TYPE:-}" == "postgres" ]]; then
|
||||
if ! docker exec -it postgres-spiff psql -U spiffworkflow_backend spiffworkflow_backend_testing -c "select 1"; then
|
||||
docker run --name postgres-spiff -p 5432:5432 -e POSTGRES_PASSWORD=spiffworkflow_backend -e POSTGRES_USER=spiffworkflow_backend -e POSTGRES_DB=spiffworkflow_backend_testing -d postgres
|
||||
|
||||
sleep 4 # classy
|
||||
|
||||
# create other db
|
||||
fi
|
||||
if ! docker exec -it postgres-spiff psql -U spiffworkflow_backend spiffworkflow_backend_development -c "select 1"; then
|
||||
# create other db. spiffworkflow_backend_testing came with the docker run.
|
||||
docker exec -it postgres-spiff psql -U spiffworkflow_backend spiffworkflow_backend_testing -c "create database spiffworkflow_backend_development;"
|
||||
fi
|
||||
fi
|
||||
|
|
|
@ -188,8 +188,10 @@ class TestMessageService(BaseTest):
|
|||
process_instance_result = ProcessInstanceModel.query.all()
|
||||
|
||||
assert len(process_instance_result) == 3
|
||||
process_instance_receiver_one = process_instance_result[1]
|
||||
process_instance_receiver_two = process_instance_result[2]
|
||||
process_instance_receiver_one = ProcessInstanceModel.query.filter_by(process_model_identifier='message_receiver_one').first()
|
||||
assert process_instance_receiver_one is not None
|
||||
process_instance_receiver_two = ProcessInstanceModel.query.filter_by(process_model_identifier='message_receiver_two').first()
|
||||
assert process_instance_receiver_two is not None
|
||||
|
||||
# just make sure it's a different process instance
|
||||
assert (
|
||||
|
|
Loading…
Reference in New Issue