[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-24 Thread Martin Grigorov (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16098036#comment-16098036
 ] 

Martin Grigorov commented on WICKET-6420:
-

Unless you provide a test case demonstrating the problem this ticket will be 
closed as "Cannot reproduce".

You are welcome to join us...@wicket.apache.org to discuss anything Wicket 
related!
Less people are subscribed to JIRA notifications so more people will be able to 
help you and to learn from your use case at users@.

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-21 Thread Kamil (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16096549#comment-16096549
 ] 

Kamil commented on WICKET-6420:
---

[~mgrigorov] - yes, they indeed fail in DEV mode and do not fail in PROD mode.
What I want to say by this issue is:
"If page can not be rendered *properly* because of lack of markup - tests 
should fail *both* on PROD and DEV"

I'm open for discussion - what are the arguments for not failing test in PROD 
even if clearly page can not be rendered as desired?

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-13 Thread Martin Grigorov (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16085641#comment-16085641
 ] 

Martin Grigorov commented on WICKET-6420:
-

Actually they should fail in DEV mode because 
org.apache.wicket.settings.DebugSettings#getComponentUseCheck() is true there.
In PROD mode it is false and it would not fail

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-13 Thread Kamil (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16085547#comment-16085547
 ] 

Kamil commented on WICKET-6420:
---

Well, they *should* fail, because of lack of proper wicket:id in markup.
The question is why they fail in DEPLOYMENT (which is expected behavior) and 
*not* fail in DEVELOPMENT (although missing wicket:id in markup, which is 
clearly an error)

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-12 Thread Martin Grigorov (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16084247#comment-16084247
 ] 

Martin Grigorov commented on WICKET-6420:
-

I'll be able to tell when I see it failing.

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-12 Thread Kamil (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16084153#comment-16084153
 ] 

Kamil commented on WICKET-6420:
---

Ok, I changed mode to DEVELOPMENT:
{code}
public class WicketTestApplication extends WicketApplication {
@Override
public RuntimeConfigurationType getConfigurationType() {
return RuntimeConfigurationType.DEVELOPMENT;
}
}
{code}
And tests failed.

But still, [~mgrigorov] do you think that it is ok, that on DEPLOYMENT 
wicketTester.assertRenderedPage(MyPage.class); turns "GREEN" while clearly 
there are errors and page can not be rendered properly?


> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-12 Thread Kamil (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16083905#comment-16083905
 ] 

Kamil commented on WICKET-6420:
---

Ok, I changed mode to DEVELOPMENT:
{code}
public class WicketTestApplication extends WicketApplication {
@Override
public RuntimeConfigurationType getConfigurationType() {
return RuntimeConfigurationType.DEVELOPMENT;
}
}
{code}
but the tests still passed

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-12 Thread Kamil (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16083851#comment-16083851
 ] 

Kamil commented on WICKET-6420:
---

I'll check the documentation on how to run tests in "development mode" (I 
didn't change anything explicitly), but in the meantime - how to check (using 
wicketTester) that component rendered successfuly (because I believe that even 
on production this will cause some error or at least not render the component, 
right)?

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)


[jira] [Commented] (WICKET-6420) WicketTester asserts passes even though page not renders

2017-07-12 Thread Martin Grigorov (JIRA)

[ 
https://issues.apache.org/jira/browse/WICKET-6420?page=com.atlassian.jira.plugin.system.issuetabpanels:comment-tabpanel&focusedCommentId=16083825#comment-16083825
 ] 

Martin Grigorov commented on WICKET-6420:
-

It seems your application run in DEVELOPMENT mode and your tests in PRODUCTION 
mode.

> WicketTester asserts passes even though page not renders
> 
>
> Key: WICKET-6420
> URL: https://issues.apache.org/jira/browse/WICKET-6420
> Project: Wicket
>  Issue Type: Bug
>Affects Versions: 8.0.0-M6
>Reporter: Kamil
>
> I have a page
> {code}
> public class MyPage extends WebPage {
> @Override
> protected void onInitialize() {
> super.onInitialize();
> add(new AjaxLink("myButton") {
> @Override
> public void onClick(final AjaxRequestTarget target) {
> }
> });
> }
> }
> {code}
> markup:
> {code}
> 
> http://wicket.apache.org";>
> 
> 
> 
> 
> 
> {code}
> although when I enter the page in the browser, I get:
> {code}
> Last cause: The component(s) below failed to render. Possible reasons could 
> be that:
>   1) you have added a component in code but forgot to reference it in the 
> markup (thus the component will never be rendered)
> {code}
> these tests are passing:
> {code}
> @Test
> public void hasMyButton() throws Exception {
> //when
>   wicketTester.startPage(MyPage.class);
> //then
>   wicketTester.assertComponent("myButton", AjaxLink.class);
>   wicketTester.assertVisible("myButton");
> wicketTester.assertContains("myButton");
> wicketTester.assertNoErrorMessage();
> wicketTester.assertRenderedPage(MyPage.class);
> }
> {code}



--
This message was sent by Atlassian JIRA
(v6.4.14#64029)