- Open your project in VSCode or Trae.
- Move the ./sample/.webtestpilot folder and put it in root of your project.
- Make sure .env file in project folder have keys for OPENAI_QQ_API_KEY= and BAML_LOG=warn.
- Install CLI tool and try it.
(These commands run on webtestpilot-extension folder)
# Get latest code
source setup.sh
powershell -ExecutionPolicy Bypass -File setup.ps1
# Start the browser
source browser.sh
powershell -ExecutionPolicy Bypass -File browser.ps1
# (Optional) if have not installed Playwright before
npx install playwright
# Install the tool using uv tool
uv tool install ieee-gui
# Check if it works (might have to restart shell)
gui-test --helpFurther reads: learn more about uv tool and publishing a package.
NOTE: Before running tests on real site, please login first (on the just-started browser).
gui-test "1.1.1 添加常用地址" --env production
gui-test /ctrip/manage-addresses --env production
gui-test 2.1.1 --env productionTo test on local: First, check the values in environment .webtestpilot/.environment/local.json, make sure it points to the right localhost in your machine i.e. http://localhost:5173. Then run the CLI.
You might need to make changes to the steps and expectations to fit your website's navigation.
gui-test /ctrip/manage-addresses --env localIn case of upgrades:
uv tool upgrade ieee-guiDONTs:
- Don't resize the browser.
- Try to not interfere with the agent browser session.
Login first if testing on real site for login-needed features.
How to write easy to work actions and expectations? Be specific.
- Good actions: be specific, if the agent still struggles, describe the element more (where it is, distinct features, ...).
- ✅ DOs: Click "City" dropdown, then choose "Shanghai" from dropdown list.
- ❌ DONTs: Fill out the form for me.
- Good expectations: be specific and check for feature you are implementing, which element to look for, which message to look for, ... Avoid ambiguous expectations. Also it can be left empty.
- ✅ DOs: A flight page with search form, list of flights and ... shows up.
- ❌ DONTs: Correct flight page shows up.
- Also try to use the same language used on the tested website. -> Leads to better screen understanding.