federation: wait for the asynchronous star to land

The check races with the propagation of the star from one forge to the
other. It must wait for it to land instead.
This commit is contained in:
Earl Warren 2024-07-07 09:55:43 +02:00
parent 631262b3b9
commit ad5790b566
No known key found for this signature in database
GPG key ID: 0579CB2928A78A00

View file

@ -1,6 +1,9 @@
TMPDIR=$(mktemp -d) TMPDIR=$(mktemp -d)
trap "rm -fr $TMPDIR" EXIT trap "rm -fr $TMPDIR" EXIT
source $SCENARIO_DIR/../../lib/lib.sh
function star_count() { function star_count() {
local curl=$1 local curl=$1
local host_port=$2 local host_port=$2
@ -41,4 +44,4 @@ $ONE_CURL api_json -X PUT $ONE_HOST_PORT/api/v1/user/starred/root/test
# check that both repo have 1 star # check that both repo have 1 star
# #
star_count $ONE_CURL $ONE_HOST_PORT 1 star_count $ONE_CURL $ONE_HOST_PORT 1
star_count $TWO_CURL $TWO_HOST_PORT 1 retry star_count $TWO_CURL $TWO_HOST_PORT 1