ExamGecko
Question list
Search
Search

Related questions











Question 32 - CTFL-2018 discussion

Report
Export

A booking system for a city bus service prices its fares according to the time of travel:

* Peak-time tariff starts at 0600 and finishes at 1000 am

* Off-peak tariff applies during all other times of service

* The bus service does not operate between 2300 and the start of the next day's peak service

Note that all times mentioned are inclusive.

When applying the equivalence partitioning test design technique, which of the following options, shows test case inputs that each fall into a different equivalence partition?

A.
0600, 1000, 1200
Answers
A.
0600, 1000, 1200
B.
1001, 1300, 2259
Answers
B.
1001, 1300, 2259
C.
0100, 0800, 2200
Answers
C.
0100, 0800, 2200
D.
2400, 1000, 2301
Answers
D.
2400, 1000, 2301
Suggested answer: D

Explanation:

2400, 1000, 2301 are test case inputs that each fall into a different equivalence partition1.Equivalence partitioning is a black box test design technique that divides the input domain of a system into partitions of equivalent data2.Each partition should contain data that is expected to be treated the same by the system2.Therefore, only one test case input from each partition is needed to test the system's behaviour2. In this question, the input domain of the system is the time of travel, which can be divided into three partitions based on the fare rules:

Peak-time tariff: This partition contains all the times between 0600 and 1000 (inclusive), which are subject to a higher fare.

Off-peak tariff: This partition contains all the times between 1001 and 2259 (inclusive), which are subject to a lower fare.

No service: This partition contains all the times between 2300 and 0559 (inclusive), which are not valid for travel.

Therefore, to test the system's behaviour for each partition, we need to choose one test case input from each partition. Among the options given in this question, only D contains one test case input from each partition. 2400 belongs to the no service partition, 1000 belongs to the peak-time tariff partition, and 2301 belongs to the off-peak tariff partition. Therefore, D is the correct answer.

asked 18/09/2024
Peter Lam
42 questions
User
Your answer:
0 comments
Sorted by

Leave a comment first