0
0
Testing Fundamentalstesting~10 mins

Test execution reporting in Testing Fundamentals - Test Execution Trace

Choose your learning style9 modes available
Test Overview

This test checks if a simple login form accepts correct credentials and shows a welcome message. It verifies the login process and the final message display.

Test Code
Testing Fundamentals
def test_login_success():
    # Simulate opening the login page
    page = open_login_page()
    
    # Enter username and password
    page.find_element('username').send_keys('user1')
    page.find_element('password').send_keys('pass123')
    
    # Click the login button
    page.find_element('login_button').click()
    
    # Check if welcome message is displayed
    welcome_text = page.find_element('welcome_message').text
    assert welcome_text == 'Welcome, user1!', f"Expected welcome message not found, got: {welcome_text}"
Execution Trace - 8 Steps
StepActionSystem StateAssertionResult
1Test startsTest environment initialized, ready to open login page-PASS
2Open login pageLogin page loaded with username, password fields and login buttonCheck page loaded successfullyPASS
3Find username field and enter 'user1'Username field filled with 'user1'Verify username field contains 'user1'PASS
4Find password field and enter 'pass123'Password field filled with 'pass123'Verify password field contains 'pass123'PASS
5Find and click login buttonLogin button clicked, processing login-PASS
6Find welcome message elementWelcome message element found on pageVerify welcome message text equals 'Welcome, user1!'PASS
7Assertion checks welcome message textWelcome message text is 'Welcome, user1!'Assert welcome message text is correctPASS
8Test endsTest completed successfully-PASS
Failure Scenario
Failing Condition: Welcome message text does not match expected 'Welcome, user1!'
Execution Trace Quiz - 3 Questions
Test your understanding
What is the first action performed in the test execution?
AOpen login page
BEnter username
CClick login button
DCheck welcome message
Key Result
Always verify the final expected output or message after performing actions to confirm the test scenario passed.