0
0
Testing Fundamentalstesting~20 mins

Test case components (steps, expected, actual) in Testing Fundamentals - Practice Problems & Coding Challenges

Choose your learning style9 modes available
Challenge - 5 Problems
🎖️
Test Case Mastery
Get all challenges correct to earn this badge!
Test your skills under time pressure!
🧠 Conceptual
intermediate
2:00remaining
Identify the correct expected result in a test case

You have a test case for a login feature. The test steps are:
1. Open the login page.
2. Enter valid username and password.
3. Click the login button.
What should be the expected result?

AThe user is redirected to the dashboard page.
BThe login button becomes disabled.
CThe system displays an error message about invalid credentials.
DThe username and password fields are cleared.
Attempts:
2 left
💡 Hint

Think about what should happen when valid credentials are entered.

assertion
intermediate
2:00remaining
Choose the correct actual result for a failed test

A test case checks if a search function returns results for a keyword. The expected result is:
Search results related to the keyword are displayed.
After running the test, the search page shows a message: 'No results found'. What is the actual result?

ASearch results related to the keyword are displayed.
BThe search page shows a message: 'No results found'.
CThe search button is disabled.
DThe page reloads without any message.
Attempts:
2 left
💡 Hint

The actual result is what you observe after running the test steps.

Predict Output
advanced
2:00remaining
What is the output of this test step log?

Consider this test step log snippet from an automated test:

1. Navigate to homepage
2. Click 'Sign Up' button
3. Enter email: 'user@example.com'
4. Click 'Submit'
5. Verify confirmation message

The test fails at step 5 with the message: 'Expected: "Thank you for signing up!" Actual: "Error: Email already exists."'. What is the test result?

ATest failed because the actual message differs from expected.
BTest passed because the confirmation message appeared.
CTest passed because the email was entered correctly.
DTest failed because the 'Submit' button was not clicked.
Attempts:
2 left
💡 Hint

Compare the expected and actual messages carefully.

🔧 Debug
advanced
2:00remaining
Find the missing component in this test case

Here is a test case outline for a password reset feature:

Test Steps:
1. Open the password reset page.
2. Enter registered email.
3. Click 'Reset Password'.

Which component is missing to make this a complete test case?

AActual result observed after running the test.
BTest case ID and author information.
CExpected result describing what should happen after clicking 'Reset Password'.
DTest data such as the registered email address.
Attempts:
2 left
💡 Hint

Think about what tells you if the test passed or failed.

framework
expert
2:00remaining
Which test case component best supports automated test reporting?

In an automated testing framework, which test case component is most critical for generating clear test reports that show pass or fail status?

ATest steps detailing each action to perform.
BExpected results defining the correct behavior.
CTest case description explaining the test purpose.
DActual results captured during test execution.
Attempts:
2 left
💡 Hint

Think about what the test runner records to decide pass or fail.