Closed quockhanh closed 1 year ago
@veebs @vothaison
For the current test-case-file content model, there is parameters?: string[]
Should we use it instead of create new dataset
property? (to contain list of dataset id)
Yes - let's use the parameters property.
We also should delete the Add Routine
button. Don't need it if routine is just another action.
When a test case calls one test routine (A) with two datasets and a second test routine (B) with five datasets:
Adding Test Routines
When a test routine with more datasets than are already present in the test case is added to a test case, create additional test case data scenarios and cycle through the existing test routine datasets to populate the additional data combos.
For example, in the scenario above there are five datasets in play for the test case, with the data combos being (A1, B1), (A2, B2), (A1, B3), (A2, B4) and (A1, B5). The test case then calls a third test routine (C) that has 7 datasets defined, meaning our data combos become (A1, B1, C1), (A2, B2, C2), (A1, B3, C3), (A2, B4, C4), (A1, B5, C5), (A2, B1, C6) and (A1, B2, C7).
Adding a dataset to a test routine
The same logic appplies when an extra dataset is added to a test routine - test cases that reference the test routine with the "All" specifier are auto-synched to account for that extra dataset. For example, using the same scenario as above the data scenarios in play are (A1, B1), (A2, B2), (A1, B3), (A2, B4) and (A1, B5):
Scenario 1 - An extra dataset is added to test routine A
In this case the dataset combos are adjusted to (A1, B1), (A2, B2), (A3, B3), (A1, B4) and (A2, B5). The side effect of this is that several data combinations are adjusted, but this a natural byproduct of the dataset cycling methodology and is intended.
Scenario 2 - An extra dataset is added to test routine B
In this case the dataset combos are adjusted to (A1, B1), (A2, B2), (A1, B3), (A2, B4), (A1, B5) and (A2, B6). The existing data combinations are not impacted but the data combination count increases from 5 to 6.
Deleting test routines and deleting datasets
When a test routine is deleted or a test routine's dataset is deleted the same type of logic as described above is applied. The data combinations for test cases that reference the deleted test routine or dataset are adjusted. Using (A1, B1), (A2, B2), (A1, B3), (A2, B4) and (A1, B5) again as the starting point:
Scenario 1 - Test Routine A is deleted
The data combos are (B1), (B2), (B3), (B4) and (B5). If test routine B was deleted instead our data combos would be (A1), (A2).
Scenario 2 - Dataset B3 is deleted
The data combos are (A1, B1), (A2, B2), (A1, B4), (A2, B5).
@brogreenmoon
This work item is about to redesign (UI) for multiple dataset selection in test case editor. We just change code at TestCaseEditor area
Any change related to 'Run test' dialog should be in separated /other ticket, to figure out the possibility or technical design before any implementation
Implemented:
and validated Run Test Routine functionality.
This is current UI of test case editor, when we add new test routine
(Red is normal test step, then Blue is routine step)
The problem of this design is, those kind of steps / rows are different together (4 column vs 2 column), and we cannot migrate when implement Grid UI as #118 . I would like to structure them into grid layout right now (same column / row / type)
Solution: expected UI should look like
RoutineName[DataSet1Name, DataSet2Name] // if enough space RoutineName[DataSet1Name, DataSet2Name .... // if not enough space, when user hover this area, then display full text in a tooltip
About data model, it should be: