JBehave
  1. JBehave
  2. JBEHAVE-246

Improve terminology, the distinction between a story and a scenario

    Details

    • Number of attachments :
      0

      Description

      I think it's unfortunate that a scenario file contains several other scenarios. This leads to some ambiguities in the system, such as the meaning of a GivenScenario, and also in communication (is a scenario a collection or a scenario?).

      It also is somewhat a violation of the literal meaning of scenario - which by definition contains other stories or scenes, not scenarios.

      I think while the framework is still relatively young it would be worth addressing this design choice. Perhaps a scenario should contain stories, or something like that.

      The main concern is removing the ambiguity about what a scenario is.

        Activity

        Hide
        Mauro Talevi added a comment -

        A story is made of multiple scenarios, not the other way around. A scenario may depend on other scenarios as a precondition, hence the GivenScenarios keyword.

        That said, yours is a fair issue being raised as in JBehave 2.x the scenario is the central element, while upon retrospective placing it at story level might serve the purpose better. Most like this cannot be done without breaking backward compat, so we'll address it as part of 3.x.

        We still need to ensure that the the ability to execute a single scenario, i.e. a sequence of steps, without lots of unnecessary scaffolding around it, is satisfied.

        Show
        Mauro Talevi added a comment - A story is made of multiple scenarios, not the other way around. A scenario may depend on other scenarios as a precondition, hence the GivenScenarios keyword. That said, yours is a fair issue being raised as in JBehave 2.x the scenario is the central element, while upon retrospective placing it at story level might serve the purpose better. Most like this cannot be done without breaking backward compat, so we'll address it as part of 3.x. We still need to ensure that the the ability to execute a single scenario, i.e. a sequence of steps, without lots of unnecessary scaffolding around it, is satisfied.
        Mauro Talevi made changes -
        Field Original Value New Value
        Fix Version/s 3.0 [ 16302 ]
        Mauro Talevi made changes -
        Assignee Mauro Talevi [ maurotalevi ]
        Hide
        Mauro Talevi added a comment -

        Terminology in the Java classes in 3.x has been completely overhauled, shifting from Scenario to Story to reflect what was de facto already the case in 2.x.

        So e.g.

        RunnableScenario -> RunnableStory
        JUnitScenario -> JUnitStory
        ScenarioRunner -> StoryRunner
        ... the list continues.

        The root package of the core module has also changed from org.jbehave.scenario to org.jbehave.core.

        Note that from a textual story point of view, almost nothing has changed, and textual input will be backward compatible, with the minor exception of the keyword GivenScenarios -> GivenStories.

        Details on how to ensure a smooth migration path on:

        http://jbehave.org/reference/latest/migrating-from-2.x.html

        Show
        Mauro Talevi added a comment - Terminology in the Java classes in 3.x has been completely overhauled, shifting from Scenario to Story to reflect what was de facto already the case in 2.x. So e.g. RunnableScenario -> RunnableStory JUnitScenario -> JUnitStory ScenarioRunner -> StoryRunner ... the list continues. The root package of the core module has also changed from org.jbehave.scenario to org.jbehave.core. Note that from a textual story point of view, almost nothing has changed, and textual input will be backward compatible, with the minor exception of the keyword GivenScenarios -> GivenStories. Details on how to ensure a smooth migration path on: http://jbehave.org/reference/latest/migrating-from-2.x.html
        Mauro Talevi made changes -
        Status Open [ 1 ] Resolved [ 5 ]
        Resolution Fixed [ 1 ]
        Mauro Talevi made changes -
        Component/s Core [ 11086 ]
        Component/s Ant extension [ 11081 ]
        Component/s Maven Plugin [ 12482 ]
        Component/s Documentation [ 11085 ]

          People

          • Assignee:
            Mauro Talevi
            Reporter:
            James Ravn
          • Votes:
            0 Vote for this issue
            Watchers:
            0 Start watching this issue

            Dates

            • Created:
              Updated:
              Resolved: