[ 
http://jira.codehaus.org/browse/JBEHAVE-290?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
 ]

Mauro Talevi updated JBEHAVE-290:
---------------------------------

      Component/s: Core
    Fix Version/s: 3.0
                   2.5.7
         Assignee: Mauro Talevi

> Stack Overflow when parsing a scenario with a very long step
> ------------------------------------------------------------
>
>                 Key: JBEHAVE-290
>                 URL: http://jira.codehaus.org/browse/JBEHAVE-290
>             Project: JBehave
>          Issue Type: Bug
>          Components: Core
>    Affects Versions: 2.5.1
>         Environment: Windows
>            Reporter: Moss Collum
>            Assignee: Mauro Talevi
>             Fix For: 2.5.7, 3.0
>
>         Attachments: jbehave_long_step_stack_overflow_fix.patch
>
>
> A StackOverflowError occurs when the PatternScenarioParser parses a very long 
> step in a scenario. This happened to us when writing a Given step that 
> included a long table parameter.
> This seems to be caused by the well-known regex bug in Java 
> (http://bugs.sun.com/bugdatabase/view_bug.do?bug_id=6337993).  The 
> patternToPullOutSteps method specifies a pattern that contains an alternative 
> wrapped in a star, specifically "(.|\\s)*".
> We were able to use the same strategy as that used to fix JBEHAVE-242.
> One note about the included patch: the test we've added to 
> PatternScenarioParserBehaviour, shouldParseStoryWithVeryLongStep, can 
> sometimes pass incorrectly depending on the order in which the tests from 
> that class are run. If shouldParseLongStoryWithKeywordSplitScenarios runs 
> first, our test passes even without the fix applied. We weren't sure what to 
> do about this, but on our machine the tests reliably ran in the order in 
> which they were defined, so we just kept that one higher up in the file. 
> Possibly there are deeper issues to consider here.
> --Moss Collum and Jim Olsen

-- 
This message is automatically generated by JIRA.
-
If you think it was sent incorrectly contact one of the administrators: 
http://jira.codehaus.org/secure/Administrators.jspa
-
For more information on JIRA, see: http://www.atlassian.com/software/jira

        

---------------------------------------------------------------------
To unsubscribe from this list, please visit:

    http://xircles.codehaus.org/manage_email


Reply via email to