nus-cs2103-AY2021S1 / forum

20 stars 2 forks source link

Clarification on definition of boundary values #525

Closed chunyongg closed 3 years ago

chunyongg commented 3 years ago

Hi, I am a little confused over the definition of boundary values. For example:

Given an equivalence partition [1-10] inclusive, are the boundary values 1 and 10, or 0, 1, 2, 9, 10, 11 ?

damithc commented 3 years ago

Strictly speaking, the boundaries are 1 and 10. Picking test inputs based on BVA (i.e.., boundary value analysis) can give you 0, 1, 2, 9, 10, 11, (or even more values) depending on how many test cases you can afford. If you can afford only two values, you might end up picking 1 and 10 only.

itssodium commented 3 years ago

So when a question asks for boundary values the answer is 1 & 10?

damithc commented 3 years ago

So when a question asks for boundary values the answer is 1 & 10?

Yes.