0
0
Testing Fundamentalstesting~10 mins

Risk-based testing in Testing Fundamentals - Interactive Code Practice

Choose your learning style9 modes available
Practice - 5 Tasks
Answer the questions below
1fill in blank
easy

Complete the code to define the main goal of risk-based testing.

Testing Fundamentals
risk_based_testing_goal = "Focus testing on areas with [1] risk"
Drag options to blanks, or click blank then click option'
Aaverage
Bhighest
Clowest
Dunknown
Attempts:
3 left
💡 Hint
Common Mistakes
Choosing 'lowest' risk which misses critical problems.
Confusing risk with unknown areas.
2fill in blank
medium

Complete the code to calculate risk as a product of impact and likelihood.

Testing Fundamentals
risk = impact [1] likelihood
Drag options to blanks, or click blank then click option'
A*
B/
C-
D+
Attempts:
3 left
💡 Hint
Common Mistakes
Adding impact and likelihood instead of multiplying.
Dividing impact by likelihood which does not represent risk.
3fill in blank
hard

Fix the error in the code that selects test cases based on risk threshold.

Testing Fundamentals
selected_tests = [test for test in tests if test.risk [1] 5]
Drag options to blanks, or click blank then click option'
A<
B=
C===
D>
Attempts:
3 left
💡 Hint
Common Mistakes
Using '=' which is assignment, not comparison.
Using '==' which checks equality, not greater than.
4fill in blank
hard

Fill both blanks to create a dictionary of test cases with risk above threshold and their impact.

Testing Fundamentals
high_risk_tests = {test.name: test.[1] for test in tests if test.[2] > 7}
Drag options to blanks, or click blank then click option'
Aimpact
Blikelihood
Crisk
Dpriority
Attempts:
3 left
💡 Hint
Common Mistakes
Using likelihood instead of impact for values.
Filtering by impact instead of risk.
5fill in blank
hard

Fill all three blanks to create a list of test names with risk above 6 and likelihood above 3.

Testing Fundamentals
selected = [test.[1] for test in tests if test.[2] > 6 and test.[3] > 3]
Drag options to blanks, or click blank then click option'
Aname
Brisk
Clikelihood
Dimpact
Attempts:
3 left
💡 Hint
Common Mistakes
Using impact instead of likelihood in the condition.
Selecting risk instead of name in the output.