JBehave
  1. JBehave
  2. JBEHAVE-791

After updating jbehave to 3.6.x failing test is shown as passing

    Details

    • Type: Bug Bug
    • Status: Open Open
    • Priority: Major Major
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:
      None
    • Environment:
      windows XP, jdk1.6, maven2.2.1, jbehave 3.5.4 and 3.6.7
    • Testcase included:
      yes
    • Patch Submitted:
      Yes
    • Number of attachments :
      1

      Description

      How to reproduce.

      1.Please open below maven project
      2.Run clean install --> everything passes
      3.Change jbehave spring version to 3.5.4
      5.Run clean install --> test fails

      In point 2, new version of jbehave is showing that failing test is passing. Even when there is explicit fail:
      Then c D and <D> (FAILED)
      (java.lang.AssertionError:
      Expected: is "C"
      got: "D"
      )

      Another thing is issue with whitespaces. When you remove MyStepMatcherThatIgnoresWhitespaces from configuration then story will fail as well.

      First issue is critical for us if we want to be up to date with jbehave. Second is also important to remove amount of our code.

      Thx

        Activity

        Hide
        Mauro Talevi added a comment -

        Not sure what the problem is here. When you upgrade from 3.5.4 to 3.6.7 a bug is fixed.

        Why do you say it's a critical issue for you?

        Show
        Mauro Talevi added a comment - Not sure what the problem is here. When you upgrade from 3.5.4 to 3.6.7 a bug is fixed. Why do you say it's a critical issue for you?
        Hide
        Maciej Madej added a comment -

        Let me rephrase:

        on jbehave 3.5.4 test failes --> correct behaviour
        on jbehave 3.6.7 test passess --> BUG

        Test is written in a way that it should fail.

        Show
        Maciej Madej added a comment - Let me rephrase: on jbehave 3.5.4 test failes --> correct behaviour on jbehave 3.6.7 test passess --> BUG Test is written in a way that it should fail.
        Hide
        Mauro Talevi added a comment -

        I've had a look at the attached project but I struggle to understand what the problem is. The story is not self-explanatory.

        I also don't really understand the role of the extra annotations you've introduced.

        Would you be able to express your use case with a failing self-explanatory scenario using the latest release? Please don't add any extensions to the existing components, unless strictly necessary.

        Show
        Mauro Talevi added a comment - I've had a look at the attached project but I struggle to understand what the problem is. The story is not self-explanatory. I also don't really understand the role of the extra annotations you've introduced. Would you be able to express your use case with a failing self-explanatory scenario using the latest release? Please don't add any extensions to the existing components, unless strictly necessary.
        Hide
        Maciej Madej added a comment -

        Ok, I'll try

        But I'm little bit suprised, project is quite small and is working quite with jbehave 3.5.4. When upgrading to 3.6.7 test is not failing.

        Annotations are introduced to pick only specific scenario from given story file, so that class can execute multi scenarios.

        Story is simplest I could come up with. I also do not understand why I cannot add extensions if API allows me?

        But never mind, I'll try to prepare more biginers example...

        Thx

        Show
        Maciej Madej added a comment - Ok, I'll try But I'm little bit suprised, project is quite small and is working quite with jbehave 3.5.4. When upgrading to 3.6.7 test is not failing. Annotations are introduced to pick only specific scenario from given story file, so that class can execute multi scenarios. Story is simplest I could come up with. I also do not understand why I cannot add extensions if API allows me? But never mind, I'll try to prepare more biginers example... Thx
        Hide
        Mauro Talevi added a comment -

        Apart from the use of extra annotations, which I can understand the scope, it's the story that really does not tell me what you're trying to verify.

        The following scenario is not what I call self-explanatory

        Scenario: abc1
        Meta:
        @def
        Given a
        When b
        Then c <C> and <D>

        Examples:

        C D
        C D
        C D
        C D
        C D
        C D
        C D
        C D
        Show
        Mauro Talevi added a comment - Apart from the use of extra annotations, which I can understand the scope, it's the story that really does not tell me what you're trying to verify. The following scenario is not what I call self-explanatory Scenario: abc1 Meta: @def Given a When b Then c <C> and <D> Examples: C D C D C D C D C D C D C D C D
        Hide
        Maciej Madej added a comment -

        Please take a look at implementation, there is simple assert there, I still do not understand what is complicated here. I can write more meaningful story with real-world example but that's not the case. The case here is fact that new jbehave is "swallowing" AsserionError and showing that test has passed.

        Show
        Maciej Madej added a comment - Please take a look at implementation, there is simple assert there, I still do not understand what is complicated here. I can write more meaningful story with real-world example but that's not the case. The case here is fact that new jbehave is "swallowing" AsserionError and showing that test has passed.
        Hide
        Maciej Madej added a comment -

        Something must have changed between 3.5.4 and 3.6.7 to introduce this behaviour. my extensions are very simple to grasp and understand

        Show
        Maciej Madej added a comment - Something must have changed between 3.5.4 and 3.6.7 to introduce this behaviour. my extensions are very simple to grasp and understand
        Hide
        Mauro Talevi added a comment -

        I'm sorry but your scenarios are far from straightforward to understand. I'm willing to help, but a more collaborative attitude would be most useful as well.

        In particular:

        • why are there 3 identical scenarios?
        • what's the point of having the examples tables as you've written them?

        I would appreciate the simplest possible scenario that reproduces the problem, with some comment on what is expected and why.

        Thanks

        Show
        Mauro Talevi added a comment - I'm sorry but your scenarios are far from straightforward to understand. I'm willing to help, but a more collaborative attitude would be most useful as well. In particular: why are there 3 identical scenarios? what's the point of having the examples tables as you've written them? I would appreciate the simplest possible scenario that reproduces the problem, with some comment on what is expected and why. Thanks
        Hide
        Maciej Madej added a comment -

        OK,

        I'll provide better example, simpler one. I just need some time.

        Will try to keep you posted.

        Thx

        Show
        Maciej Madej added a comment - OK, I'll provide better example, simpler one. I just need some time. Will try to keep you posted. Thx

          People

          • Assignee:
            Unassigned
            Reporter:
            Maciej Madej
          • Votes:
            0 Vote for this issue
            Watchers:
            2 Start watching this issue

            Dates

            • Created:
              Updated: