Best Practice approach for Test case writing
If there exists multiple variants of the same test case for example if the same test case had be executed for different countries or different lines of business where the input and output varies but overall steps of execution remains same then below approach i feel would be the better approaches can be used based on the underlying logic or the called programs.
Approach 1 – If the underlying Logic/program is same
Would be a better approach to write single test case if the steps planned to be executed are same with multiple variants with different inputs and outputs for each variant.
Since the underlying logic is same accross different variants just the inputs and outputs vary , if one variant fails other variants also fail so test case status will be same accross all variants so is the reporting of defect for that particular Test case
Approach 2 – If the underlying Logic/program is different
If the underlying logic/program is different though the steps are similar for different variants with different inputs and outputs better approach would be to split it as seperate test case.
Reason for this Logic A/Program A might fail but not Logic B/Program B then we would have better clarity on Test status reporting and Defect Management.
If we club all the variants into one then though one variant might pass due to failure of other variant overall test case status had be set to failure which is not the case which will give wrong indication
Hope it helps.