ExamGecko
Question list
Search
Search

Related questions











Question 82 - CTFL-2018 discussion

Report
Export

A money order system is designed to calculate the charge for a transfer

- Amounts from 1 to 1999 are charged EUR 10.

- Amounts from 2000 to 5000 are charged EUR 15

- Amounts below EUR 1 or above EUR 5000 are not accepted. Assume that only integer values can occur. Which of these sets of amounts covers all equivalence classes?

A.
0-1999-2000-5000
Answers
A.
0-1999-2000-5000
B.
1-2000-5001-10000
Answers
B.
1-2000-5001-10000
C.
0-100-2000-6000
Answers
C.
0-100-2000-6000
D.
99-1- 2000- 4999,99
Answers
D.
99-1- 2000- 4999,99
Suggested answer: C

Explanation:

The requirement given in

the image specifies

the charge for

a money transfer based on

the amount

of money transferred.

The amount can be anywhere from 1 to 5000 euros, with different charges applied for different ranges of amounts.

To test this requirement, we can use equivalence partitioning, which is a specification-based test technique that involves dividing the input or output values into groups or partitions that are expected to be treated in the same way by the system under test. For example, based on the requirement, we can identify the following equivalence partitions for the input amount:

EP1: Amount < 1 (invalid)

EP2: 1 <= Amount <= 1999 (valid, charge = 10 euros)

EP3: 2000 <= Amount <= 5000 (valid, charge = 15 euros)

EP4: Amount > 5000 (invalid)

The set of amounts that covers all equivalence partitions is C. 0-100-2000-6000. This set of amounts includes one value from each equivalence partition and ensures that all possible scenarios are tested. For example:

TC1: Amount = 0 -> Invalid input

TC2: Amount = 100 -> Valid input, charge = 10 euros

TC3: Amount = 2000 -> Valid input, charge = 15 euros

TC4: Amount = 6000 -> Invalid input

The other sets of amounts do not cover all equivalence partitions because they either include values that belong to the same partition or exclude values that belong to different partitions. For example:

A: 0-1999-2000-5000 -> This set of amounts does not cover all equivalence partitions because it includes two values that belong to EP2 (1999 and 2000) and excludes any value that belongs to EP3.

B: 1-2000-5001-10000 -> This set of amounts does not cover all equivalence partitions because it includes two values that belong to EP4 (5001 and 10000) and excludes any value that belongs to EP2.

D: 99-1-2000-4999.99 -> This set of amounts does not cover all equivalence partitions because it includes a value that is not an integer (4999.99), which violates the assumption that only integer values can occur.

You can find more information about equivalence partitioning in [A Study Guide to the ISTQB Foundation Level 2018 Syllabus], Chapter 4, Section 4.2.

asked 18/09/2024
George Kavvalakis
28 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first