1.7 KiB
1.7 KiB
UI Test Prompt Template
Use this prompt when asking an agent to add or modify SportsTime UI tests.
You are updating SportsTime UI tests.
Goal
- [Describe the behavior to test or fix.]
Scope
- Update/add tests under
SportsTimeUITests/Tests/. - Reuse page objects in
SportsTimeUITests/Framework/Screens.swift. - Reuse shared setup in
SportsTimeUITests/Framework/BaseUITestCase.swift. - Reuse existing
TestFlowswhere possible.
Required Changes
- [List test suites to modify.]
- [List new test names.]
- [List selectors/page-object methods to add if needed.]
Constraints
- Do not add raw sleeps unless strictly necessary.
- Prefer
waitForExistenceOrFailandwaitUntilHittable. - Keep tests deterministic with current local test data.
- Keep existing naming style (
testF###_...,testP###_..., etc.).
Validation
Run these before finishing:
- Targeted class or test:
xcodebuild test-without-building -project SportsTime.xcodeproj -scheme SportsTime -destination 'platform=iOS Simulator,name=iPhone 17,OS=26.2' -parallel-testing-enabled NO -only-testing:SportsTimeUITests/<SuiteOrTest>
- Full UI suite:
xcodebuild test-without-building -project SportsTime.xcodeproj -scheme SportsTime -destination 'platform=iOS Simulator,name=iPhone 17,OS=26.2' -parallel-testing-enabled NO -only-testing:SportsTimeUITests
- If requested, full scheme:
xcodebuild test-without-building -project SportsTime.xcodeproj -scheme SportsTime -destination 'platform=iOS Simulator,name=iPhone 17,OS=26.2' -parallel-testing-enabled NO
Output Format
- Summarize files changed.
- Summarize root causes fixed.
- Include exact commands run and pass/fail outcomes.
- Call out any remaining flaky behavior or follow-up work.