Details
-
Type: New Feature
-
Status: Open
-
Priority: Minor
-
Resolution: Unresolved
-
Affects Version/s: None
-
Fix Version/s: None
-
Component/s: Core
-
Labels:None
-
Number of attachments :
Description
I would like to be able to add priority to my textual scenarios and should be available to the StoryReporter. This priority is used to tell in what order the different scenarios should be implemented.
E.g. if (in StoryReporter)
public void beforeScenario(String title);
is changed to
public void beforeScenario(String title, int priority);
The priority can be used to create a visual report (e.g. in HTML).
The priority can also be used to raise warnings if a high priority scenario is pending, while there is activity on scenarios with less priority.
Activity
Mauro Talevi
made changes -
Field | Original Value | New Value |
---|---|---|
Description |
I would like to be able to add priority to my textual scenarios and should be available to the ScenarioReporter. This priority is used to tell in what order the different scenarios should be implemented. E.g. if (in ScnearioReporter) public void beforeScenario(String title); is changed to public void beforeScenario(String title, int priority); The priority can be used to create a visual report (e.g. in HTML). The priority can also be used to raise warnings if a high priority scenario is pending, while there is activity on scenarios with less priority. |
I would like to be able to add priority to my textual scenarios and should be available to the StoryReporter. This priority is used to tell in what order the different scenarios should be implemented.
E.g. if (in StoryReporter) public void beforeScenario(String title); is changed to public void beforeScenario(String title, int priority); The priority can be used to create a visual report (e.g. in HTML). The priority can also be used to raise warnings if a high priority scenario is pending, while there is activity on scenarios with less priority. |
Component/s | Core [ 11086 ] |
Hmm, been thinking about this myself. Wouldn't it be nice to be able to label the scenarios themselves, too? That way, we could run them either in order, or with the most recent scenarios first, depending on what we're interested in. I'm thinking of files labelled things like:
1_5_i_can_win_the_game
1_6_the_game_can_be_a_draw
2_we_keep_score
etc.
That would also allow the scenarios to appear in a natural order in directory listing, which they don't at the moment.
One of the things we could do is to find all files which match the scenario file pattern in a directory, then match them up to the Java class. This would let us get round some of the annoying problems I've seen with case matching, too. Our Java classes wouldn't have the numbers on the front of them, obviously; they'd just be there to wire up the text files.
I guess it would be the JUnit runner that would have to change...?
(BTW, the act of concentrating on high priority stories is a cultural thing. I'm very wary of putting constraints into code to concentrate effort on fixing a problem that may have an underlying root cause.)