Verify context switching between main page and iframe
Preconditions (3)
Step 1: Open the web page URL
Step 2: Switch to the iframe using its id or name
Step 3: Click the button inside the iframe with id 'iframeButton'
Step 4: Verify that clicking the iframe button triggers expected behavior (e.g., a message appears)
Step 5: Switch back to the main page content
Step 6: Click the button on the main page with id 'mainButton'
Step 7: Verify that clicking the main page button triggers expected behavior (e.g., a different message appears)
✅ Expected Result: The test should successfully switch context to the iframe and back to the main page, clicking buttons in both contexts and verifying their behaviors.