hmm.
line 327 is:
int currentIndex = (int) Context.Session[wizardName +
"currentstepindex"];
so RedirectToNextStep is depending on a session variable
you can setup that session var on your mocked/stubbed/faked/jizzed/whadever
Context instance.
btw people. why is this thing in the Session? shouldn't Context.Items be a
better place for it?
On Mon, Sep 22, 2008 at 11:09 PM, Kristofer Goss <[EMAIL PROTECTED]> wrote:
> Hi Ken, I'm running from trunk build (build 1.1.948). I'm getting:
>
> System.NullReferenceException: Object reference not set to an instance of
> an object.
> at Castle.MonoRail.Framework.WizardStepPage.RedirectToNextStep(IDictionary
> queryStringParameters) in WizardStepPage.cs: line 327
> at Castle.MonoRail.Framework.WizardStepPage.RedirectToNextStep() in
> WizardStepPage.cs: line 307
>
> I'm assuming that since the action provider isn't involved within my test,
> it's failing to setup the expected session details used internally. Thanks
> again.
>
>
> On Mon, Sep 22, 2008 at 2:48 PM, Ken Egozi <[EMAIL PROTECTED]> wrote:
>
>> what's the stack trace on the null-ref that you get?
>> also, are you using trunk?
>>
>>
>> On Mon, Sep 22, 2008 at 8:53 PM, Kristofer Goss <[EMAIL PROTECTED]>wrote:
>>
>>> Hi, I'm wondering if anyone can recommend some sample code which
>>> demonstrates testing wizard steps? I've read the the following:
>>>
>>> http://using.castleproject.org/display/MR/TDDing+WizardSteps
>>>
>>> However, there is little documentation around the sample code and I'm
>>> encountering issues with invoking ProcessNextStep on my wizard step from
>>> within a fixture. It appears that some state in the session (I believe
>>> setup by the WizardActionProvider) is not present, resulting in null
>>> reference exceptions within the MR wizard step.
>>>
>>> I was hoping to find some additional sample code which might demonstrate
>>> testing wizard pages. Any help/links are greatly appreciated.
>>>
>>> Thanks,
>>>
>>> Kris
>>>
>>>
>>>
>>
>>
>> --
>> Ken Egozi.
>> http://www.kenegozi.com/blog
>> http://www.musicglue.com
>> http://www.castleproject.org
>> http://www.gotfriends.co.il
>>
>>
>>
>
> >
>
--
Ken Egozi.
http://www.kenegozi.com/blog
http://www.musicglue.com
http://www.castleproject.org
http://www.gotfriends.co.il
--~--~---------~--~----~------------~-------~--~----~
You received this message because you are subscribed to the Google Groups
"Castle Project Users" group.
To post to this group, send email to [email protected]
To unsubscribe from this group, send email to [EMAIL PROTECTED]
For more options, visit this group at
http://groups.google.com/group/castle-project-users?hl=en
-~----------~----~----~----~------~----~------~--~---