playwright: Add duration to test account creation request

There were some changes in Ethel recently, duration currently seems to be a required field. Ethel team works on a fix.

Default value for duration is 1 year so I've set it to that.
This commit is contained in:
regexowl 2025-07-31 10:58:05 +02:00 committed by Klara Simickova
parent d5321bb078
commit 1096c6d4fb

View file

@ -68,7 +68,7 @@ jobs:
export PLAYWRIGHT_USER=image-builder-playwright-$RANDOM
export PLAYWRIGHT_PASSWORD=image-builder-playwright-$(uuidgen)
# Step 1: Create a new empty account
curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/new -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\"}"
curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/new -d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\", \"duration\":\"1 year\"}"
# Step 2: Attach subscriptions to the new account
curl -k -X POST https://account-manager-stage.app.eng.rdu2.redhat.com/account/attach \
-d "{\"username\": \"$PLAYWRIGHT_USER\", \"password\":\"$PLAYWRIGHT_PASSWORD\", \"sku\":[\"RH00003\"],\"quantity\": 1}"