You are viewing a plain text version of this content. The canonical link for it is here.
Posted to dev@wicket.apache.org by Martijn Dashorst <ma...@gmail.com> on 2009/02/26 14:41:44 UTC

Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

I've added this test to a JIRA issue, but I can also commit it. That
would fail the build though...

I'm not certain what the way to go is to solve this particular issue.

A naive solution would be to just iterate through the threadlocal and
call detach on each page.

Can we (I) commit test cases for a bug without a solution?

Martijn


On Thu, Feb 26, 2009 at 2:31 PM, Martijn Dashorst (JIRA)
<ji...@apache.org> wrote:
>
>     [ https://issues.apache.org/jira/browse/WICKET-2130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
>
> Martijn Dashorst updated WICKET-2130:
> -------------------------------------
>
>    Attachment: wicket-2130.tgz
>
> this tarball creates a wicket test case in src/test/java/org/apache/wicket/wicket2130
>
> untar it in jdk-1.4/wicket
>
>
>> Pages stored in Session.touchedPages aren't detached when part of ModalWindow
>> -----------------------------------------------------------------------------
>>
>>                 Key: WICKET-2130
>>                 URL: https://issues.apache.org/jira/browse/WICKET-2130
>>             Project: Wicket
>>          Issue Type: Bug
>>          Components: wicket
>>    Affects Versions: 1.3.5, 1.4-RC2
>>            Reporter: Martijn Dashorst
>>             Fix For: 1.3.6, 1.4-RC3
>>
>>         Attachments: wicket-2130.tgz
>>
>>
>> Creating a ModalWindow with a Page causes the newly constructed page not to be detached.
>> The page is stored in Session.touchedPages, but that list isn't properly processed at the end of the request for detaching.
>> I'll try to create a testcase for this.
>
> --
> This message is automatically generated by JIRA.
> -
> You can reply to this email to add a comment to the issue online.
>
>



-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.3.5 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.

Re: Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

Posted by Igor Vaynberg <ig...@gmail.com>.
isnt that what i suggested? :)

-igor

On Fri, Feb 27, 2009 at 1:01 AM, Johan Compagner <jc...@gmail.com> wrote:
> Ahh and that page is not in a requesttarget at this time.
>
> So what we can do is not call page.detach() in requesttarget.detach()
> But everything just in touched pages. (requesttarget detach can just
> put the page in the touched pages  list to be sure)
>
> On 27/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
>> Wicket2130Page touchedPage = new Wicket2130Page();
>> CharSequence urlFor = RequestCycle.get().urlFor(touchedPage);
>>
>> This is called in creating a ModalWindow with a page as content.
>>
>> Martijn
>>
>> On Fri, Feb 27, 2009 at 8:53 AM, Johan Compagner <jc...@gmail.com>
>> wrote:
>>> I think we just need to check how it is possible that the page comes
>>> not detached in that map. That shouldnt be possible
>>>
>>> So what is the place that pushes it?
>>>
>>> On 26/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
>>>> I've added this test to a JIRA issue, but I can also commit it. That
>>>> would fail the build though...
>>>>
>>>> I'm not certain what the way to go is to solve this particular issue.
>>>>
>>>> A naive solution would be to just iterate through the threadlocal and
>>>> call detach on each page.
>>>>
>>>> Can we (I) commit test cases for a bug without a solution?
>>>>
>>>> Martijn
>>>>
>>>>
>>>> On Thu, Feb 26, 2009 at 2:31 PM, Martijn Dashorst (JIRA)
>>>> <ji...@apache.org> wrote:
>>>>>
>>>>>     [
>>>>> https://issues.apache.org/jira/browse/WICKET-2130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
>>>>> ]
>>>>>
>>>>> Martijn Dashorst updated WICKET-2130:
>>>>> -------------------------------------
>>>>>
>>>>>    Attachment: wicket-2130.tgz
>>>>>
>>>>> this tarball creates a wicket test case in
>>>>> src/test/java/org/apache/wicket/wicket2130
>>>>>
>>>>> untar it in jdk-1.4/wicket
>>>>>
>>>>>
>>>>>> Pages stored in Session.touchedPages aren't detached when part of
>>>>>> ModalWindow
>>>>>> -----------------------------------------------------------------------------
>>>>>>
>>>>>>                 Key: WICKET-2130
>>>>>>                 URL: https://issues.apache.org/jira/browse/WICKET-2130
>>>>>>             Project: Wicket
>>>>>>          Issue Type: Bug
>>>>>>          Components: wicket
>>>>>>    Affects Versions: 1.3.5, 1.4-RC2
>>>>>>            Reporter: Martijn Dashorst
>>>>>>             Fix For: 1.3.6, 1.4-RC3
>>>>>>
>>>>>>         Attachments: wicket-2130.tgz
>>>>>>
>>>>>>
>>>>>> Creating a ModalWindow with a Page causes the newly constructed page
>>>>>> not
>>>>>> to be detached.
>>>>>> The page is stored in Session.touchedPages, but that list isn't
>>>>>> properly
>>>>>> processed at the end of the request for detaching.
>>>>>> I'll try to create a testcase for this.
>>>>>
>>>>> --
>>>>> This message is automatically generated by JIRA.
>>>>> -
>>>>> You can reply to this email to add a comment to the issue online.
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Become a Wicket expert, learn from the best: http://wicketinaction.com
>>>> Apache Wicket 1.3.5 is released
>>>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>>>>
>>>
>>
>>
>>
>> --
>> Become a Wicket expert, learn from the best: http://wicketinaction.com
>> Apache Wicket 1.3.5 is released
>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>>
>

Re: Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

Posted by Martijn Dashorst <ma...@gmail.com>.
Sounds like a plan

Martijn

On Fri, Feb 27, 2009 at 10:01 AM, Johan Compagner <jc...@gmail.com> wrote:
> Ahh and that page is not in a requesttarget at this time.
>
> So what we can do is not call page.detach() in requesttarget.detach()
> But everything just in touched pages. (requesttarget detach can just
> put the page in the touched pages  list to be sure)
>
> On 27/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
>> Wicket2130Page touchedPage = new Wicket2130Page();
>> CharSequence urlFor = RequestCycle.get().urlFor(touchedPage);
>>
>> This is called in creating a ModalWindow with a page as content.
>>
>> Martijn
>>
>> On Fri, Feb 27, 2009 at 8:53 AM, Johan Compagner <jc...@gmail.com>
>> wrote:
>>> I think we just need to check how it is possible that the page comes
>>> not detached in that map. That shouldnt be possible
>>>
>>> So what is the place that pushes it?
>>>
>>> On 26/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
>>>> I've added this test to a JIRA issue, but I can also commit it. That
>>>> would fail the build though...
>>>>
>>>> I'm not certain what the way to go is to solve this particular issue.
>>>>
>>>> A naive solution would be to just iterate through the threadlocal and
>>>> call detach on each page.
>>>>
>>>> Can we (I) commit test cases for a bug without a solution?
>>>>
>>>> Martijn
>>>>
>>>>
>>>> On Thu, Feb 26, 2009 at 2:31 PM, Martijn Dashorst (JIRA)
>>>> <ji...@apache.org> wrote:
>>>>>
>>>>>     [
>>>>> https://issues.apache.org/jira/browse/WICKET-2130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
>>>>> ]
>>>>>
>>>>> Martijn Dashorst updated WICKET-2130:
>>>>> -------------------------------------
>>>>>
>>>>>    Attachment: wicket-2130.tgz
>>>>>
>>>>> this tarball creates a wicket test case in
>>>>> src/test/java/org/apache/wicket/wicket2130
>>>>>
>>>>> untar it in jdk-1.4/wicket
>>>>>
>>>>>
>>>>>> Pages stored in Session.touchedPages aren't detached when part of
>>>>>> ModalWindow
>>>>>> -----------------------------------------------------------------------------
>>>>>>
>>>>>>                 Key: WICKET-2130
>>>>>>                 URL: https://issues.apache.org/jira/browse/WICKET-2130
>>>>>>             Project: Wicket
>>>>>>          Issue Type: Bug
>>>>>>          Components: wicket
>>>>>>    Affects Versions: 1.3.5, 1.4-RC2
>>>>>>            Reporter: Martijn Dashorst
>>>>>>             Fix For: 1.3.6, 1.4-RC3
>>>>>>
>>>>>>         Attachments: wicket-2130.tgz
>>>>>>
>>>>>>
>>>>>> Creating a ModalWindow with a Page causes the newly constructed page
>>>>>> not
>>>>>> to be detached.
>>>>>> The page is stored in Session.touchedPages, but that list isn't
>>>>>> properly
>>>>>> processed at the end of the request for detaching.
>>>>>> I'll try to create a testcase for this.
>>>>>
>>>>> --
>>>>> This message is automatically generated by JIRA.
>>>>> -
>>>>> You can reply to this email to add a comment to the issue online.
>>>>>
>>>>>
>>>>
>>>>
>>>>
>>>> --
>>>> Become a Wicket expert, learn from the best: http://wicketinaction.com
>>>> Apache Wicket 1.3.5 is released
>>>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>>>>
>>>
>>
>>
>>
>> --
>> Become a Wicket expert, learn from the best: http://wicketinaction.com
>> Apache Wicket 1.3.5 is released
>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>>
>



-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.3.5 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.

Re: Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

Posted by Johan Compagner <jc...@gmail.com>.
Ahh and that page is not in a requesttarget at this time.

So what we can do is not call page.detach() in requesttarget.detach()
But everything just in touched pages. (requesttarget detach can just
put the page in the touched pages  list to be sure)

On 27/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
> Wicket2130Page touchedPage = new Wicket2130Page();
> CharSequence urlFor = RequestCycle.get().urlFor(touchedPage);
>
> This is called in creating a ModalWindow with a page as content.
>
> Martijn
>
> On Fri, Feb 27, 2009 at 8:53 AM, Johan Compagner <jc...@gmail.com>
> wrote:
>> I think we just need to check how it is possible that the page comes
>> not detached in that map. That shouldnt be possible
>>
>> So what is the place that pushes it?
>>
>> On 26/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
>>> I've added this test to a JIRA issue, but I can also commit it. That
>>> would fail the build though...
>>>
>>> I'm not certain what the way to go is to solve this particular issue.
>>>
>>> A naive solution would be to just iterate through the threadlocal and
>>> call detach on each page.
>>>
>>> Can we (I) commit test cases for a bug without a solution?
>>>
>>> Martijn
>>>
>>>
>>> On Thu, Feb 26, 2009 at 2:31 PM, Martijn Dashorst (JIRA)
>>> <ji...@apache.org> wrote:
>>>>
>>>>     [
>>>> https://issues.apache.org/jira/browse/WICKET-2130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
>>>> ]
>>>>
>>>> Martijn Dashorst updated WICKET-2130:
>>>> -------------------------------------
>>>>
>>>>    Attachment: wicket-2130.tgz
>>>>
>>>> this tarball creates a wicket test case in
>>>> src/test/java/org/apache/wicket/wicket2130
>>>>
>>>> untar it in jdk-1.4/wicket
>>>>
>>>>
>>>>> Pages stored in Session.touchedPages aren't detached when part of
>>>>> ModalWindow
>>>>> -----------------------------------------------------------------------------
>>>>>
>>>>>                 Key: WICKET-2130
>>>>>                 URL: https://issues.apache.org/jira/browse/WICKET-2130
>>>>>             Project: Wicket
>>>>>          Issue Type: Bug
>>>>>          Components: wicket
>>>>>    Affects Versions: 1.3.5, 1.4-RC2
>>>>>            Reporter: Martijn Dashorst
>>>>>             Fix For: 1.3.6, 1.4-RC3
>>>>>
>>>>>         Attachments: wicket-2130.tgz
>>>>>
>>>>>
>>>>> Creating a ModalWindow with a Page causes the newly constructed page
>>>>> not
>>>>> to be detached.
>>>>> The page is stored in Session.touchedPages, but that list isn't
>>>>> properly
>>>>> processed at the end of the request for detaching.
>>>>> I'll try to create a testcase for this.
>>>>
>>>> --
>>>> This message is automatically generated by JIRA.
>>>> -
>>>> You can reply to this email to add a comment to the issue online.
>>>>
>>>>
>>>
>>>
>>>
>>> --
>>> Become a Wicket expert, learn from the best: http://wicketinaction.com
>>> Apache Wicket 1.3.5 is released
>>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>>>
>>
>
>
>
> --
> Become a Wicket expert, learn from the best: http://wicketinaction.com
> Apache Wicket 1.3.5 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>

Re: Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

Posted by Martijn Dashorst <ma...@gmail.com>.
Wicket2130Page touchedPage = new Wicket2130Page();
CharSequence urlFor = RequestCycle.get().urlFor(touchedPage);

This is called in creating a ModalWindow with a page as content.

Martijn

On Fri, Feb 27, 2009 at 8:53 AM, Johan Compagner <jc...@gmail.com> wrote:
> I think we just need to check how it is possible that the page comes
> not detached in that map. That shouldnt be possible
>
> So what is the place that pushes it?
>
> On 26/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
>> I've added this test to a JIRA issue, but I can also commit it. That
>> would fail the build though...
>>
>> I'm not certain what the way to go is to solve this particular issue.
>>
>> A naive solution would be to just iterate through the threadlocal and
>> call detach on each page.
>>
>> Can we (I) commit test cases for a bug without a solution?
>>
>> Martijn
>>
>>
>> On Thu, Feb 26, 2009 at 2:31 PM, Martijn Dashorst (JIRA)
>> <ji...@apache.org> wrote:
>>>
>>>     [
>>> https://issues.apache.org/jira/browse/WICKET-2130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
>>> ]
>>>
>>> Martijn Dashorst updated WICKET-2130:
>>> -------------------------------------
>>>
>>>    Attachment: wicket-2130.tgz
>>>
>>> this tarball creates a wicket test case in
>>> src/test/java/org/apache/wicket/wicket2130
>>>
>>> untar it in jdk-1.4/wicket
>>>
>>>
>>>> Pages stored in Session.touchedPages aren't detached when part of
>>>> ModalWindow
>>>> -----------------------------------------------------------------------------
>>>>
>>>>                 Key: WICKET-2130
>>>>                 URL: https://issues.apache.org/jira/browse/WICKET-2130
>>>>             Project: Wicket
>>>>          Issue Type: Bug
>>>>          Components: wicket
>>>>    Affects Versions: 1.3.5, 1.4-RC2
>>>>            Reporter: Martijn Dashorst
>>>>             Fix For: 1.3.6, 1.4-RC3
>>>>
>>>>         Attachments: wicket-2130.tgz
>>>>
>>>>
>>>> Creating a ModalWindow with a Page causes the newly constructed page not
>>>> to be detached.
>>>> The page is stored in Session.touchedPages, but that list isn't properly
>>>> processed at the end of the request for detaching.
>>>> I'll try to create a testcase for this.
>>>
>>> --
>>> This message is automatically generated by JIRA.
>>> -
>>> You can reply to this email to add a comment to the issue online.
>>>
>>>
>>
>>
>>
>> --
>> Become a Wicket expert, learn from the best: http://wicketinaction.com
>> Apache Wicket 1.3.5 is released
>> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>>
>



-- 
Become a Wicket expert, learn from the best: http://wicketinaction.com
Apache Wicket 1.3.5 is released
Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.

Re: Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

Posted by Johan Compagner <jc...@gmail.com>.
I think we just need to check how it is possible that the page comes
not detached in that map. That shouldnt be possible

So what is the place that pushes it?

On 26/02/2009, Martijn Dashorst <ma...@gmail.com> wrote:
> I've added this test to a JIRA issue, but I can also commit it. That
> would fail the build though...
>
> I'm not certain what the way to go is to solve this particular issue.
>
> A naive solution would be to just iterate through the threadlocal and
> call detach on each page.
>
> Can we (I) commit test cases for a bug without a solution?
>
> Martijn
>
>
> On Thu, Feb 26, 2009 at 2:31 PM, Martijn Dashorst (JIRA)
> <ji...@apache.org> wrote:
>>
>>     [
>> https://issues.apache.org/jira/browse/WICKET-2130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel
>> ]
>>
>> Martijn Dashorst updated WICKET-2130:
>> -------------------------------------
>>
>>    Attachment: wicket-2130.tgz
>>
>> this tarball creates a wicket test case in
>> src/test/java/org/apache/wicket/wicket2130
>>
>> untar it in jdk-1.4/wicket
>>
>>
>>> Pages stored in Session.touchedPages aren't detached when part of
>>> ModalWindow
>>> -----------------------------------------------------------------------------
>>>
>>>                 Key: WICKET-2130
>>>                 URL: https://issues.apache.org/jira/browse/WICKET-2130
>>>             Project: Wicket
>>>          Issue Type: Bug
>>>          Components: wicket
>>>    Affects Versions: 1.3.5, 1.4-RC2
>>>            Reporter: Martijn Dashorst
>>>             Fix For: 1.3.6, 1.4-RC3
>>>
>>>         Attachments: wicket-2130.tgz
>>>
>>>
>>> Creating a ModalWindow with a Page causes the newly constructed page not
>>> to be detached.
>>> The page is stored in Session.touchedPages, but that list isn't properly
>>> processed at the end of the request for detaching.
>>> I'll try to create a testcase for this.
>>
>> --
>> This message is automatically generated by JIRA.
>> -
>> You can reply to this email to add a comment to the issue online.
>>
>>
>
>
>
> --
> Become a Wicket expert, learn from the best: http://wicketinaction.com
> Apache Wicket 1.3.5 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>

Re: Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

Posted by Timo Rantalaiho <Ti...@ri.fi>.
On Thu, 26 Feb 2009, Martijn Dashorst wrote:
> Can we (I) commit test cases for a bug without a solution?

Normally it might be better to leave them to jira but then
the nuisance is that they get out of sync with the rest of
the code.

In some cases on some projects we have committed failing 
test cases in situations where it has been obvious that the
bug must be fixed soon and the test has helped in it. The
way how to disable it depends on the test framework used, 
probably with JUnit 3 the best is to make the test method 
private, because then IDEs typically claim about unused 
method and you notice that something should be done.

Best wishes,
Timo


Re: Committing failing testcases Re: [jira] Updated: (WICKET-2130) Pages stored in Session.touchedPages aren't detached when part of ModalWindow

Posted by Juergen Donnerstag <ju...@gmail.com>.
I would prefer you don't commit it.Please attach a patch or quickstart
to the jira issue. Thanks.

Juergen

On Thu, Feb 26, 2009 at 2:41 PM, Martijn Dashorst
<ma...@gmail.com> wrote:
> I've added this test to a JIRA issue, but I can also commit it. That
> would fail the build though...
>
> I'm not certain what the way to go is to solve this particular issue.
>
> A naive solution would be to just iterate through the threadlocal and
> call detach on each page.
>
> Can we (I) commit test cases for a bug without a solution?
>
> Martijn
>
>
> On Thu, Feb 26, 2009 at 2:31 PM, Martijn Dashorst (JIRA)
> <ji...@apache.org> wrote:
>>
>>     [ https://issues.apache.org/jira/browse/WICKET-2130?page=com.atlassian.jira.plugin.system.issuetabpanels:all-tabpanel ]
>>
>> Martijn Dashorst updated WICKET-2130:
>> -------------------------------------
>>
>>    Attachment: wicket-2130.tgz
>>
>> this tarball creates a wicket test case in src/test/java/org/apache/wicket/wicket2130
>>
>> untar it in jdk-1.4/wicket
>>
>>
>>> Pages stored in Session.touchedPages aren't detached when part of ModalWindow
>>> -----------------------------------------------------------------------------
>>>
>>>                 Key: WICKET-2130
>>>                 URL: https://issues.apache.org/jira/browse/WICKET-2130
>>>             Project: Wicket
>>>          Issue Type: Bug
>>>          Components: wicket
>>>    Affects Versions: 1.3.5, 1.4-RC2
>>>            Reporter: Martijn Dashorst
>>>             Fix For: 1.3.6, 1.4-RC3
>>>
>>>         Attachments: wicket-2130.tgz
>>>
>>>
>>> Creating a ModalWindow with a Page causes the newly constructed page not to be detached.
>>> The page is stored in Session.touchedPages, but that list isn't properly processed at the end of the request for detaching.
>>> I'll try to create a testcase for this.
>>
>> --
>> This message is automatically generated by JIRA.
>> -
>> You can reply to this email to add a comment to the issue online.
>>
>>
>
>
>
> --
> Become a Wicket expert, learn from the best: http://wicketinaction.com
> Apache Wicket 1.3.5 is released
> Get it now: http://www.apache.org/dyn/closer.cgi/wicket/1.3.
>