-
Notifications
You must be signed in to change notification settings - Fork 164
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Do not warn about no @Theme in views when in npm mode #6065
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 1 unresolved discussion, 0 of 1 LGTMs obtained (waiting on @manolo)
flow-server/src/main/java/com/vaadin/flow/component/internal/UIInternals.java, line 652 at r1 (raw file):
assert viewLocation != null; if (getSession().getConfiguration().isCompatibilityMode()) {
This fails in some tests with a NPE as session configuration is not set for the tests when using new MockUI()
.
java.lang.NullPointerException
at com.vaadin.flow.component.internal.UIInternals.showRouteTarget(UIInternals.java:652)
2d2e528
to
5b9ef99
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 1 unresolved discussion, 0 of 1 LGTMs obtained (waiting on @caalador)
flow-server/src/main/java/com/vaadin/flow/component/internal/UIInternals.java, line 652 at r1 (raw file):
Previously, caalador wrote…
This fails in some tests with a NPE as session configuration is not set for the tests when using
new MockUI()
.java.lang.NullPointerException at com.vaadin.flow.component.internal.UIInternals.showRouteTarget(UIInternals.java:652)
Yep, Done
5b9ef99
to
5005c11
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador and @manolo)
flow-server/src/test/java/com/vaadin/tests/util/AlwaysLockedVaadinSession.java, line 11 at r2 (raw file):
super(service); lock(); if (service != null && service.getDeploymentConfiguration() != null) {
This has a problem that we set the deploymentConfiguration in other methods of the MockUI. They should now be changed to getDeploymentConfiguration().setXYZ() instead of using setDeploymentConfiguration
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 1 of 1 files at r1, 1 of 1 files at r2.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador and @manolo)
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador)
flow-server/src/test/java/com/vaadin/tests/util/AlwaysLockedVaadinSession.java, line 11 at r2 (raw file):
Previously, caalador wrote…
This has a problem that we set the deploymentConfiguration in other methods of the MockUI. They should now be changed to getDeploymentConfiguration().setXYZ() instead of using setDeploymentConfiguration
right, I’m diving how to deal with this.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador and @manolo)
flow-server/src/test/java/com/vaadin/tests/util/AlwaysLockedVaadinSession.java, line 11 at r2 (raw file):
Previously, manolo (Manuel Carrasco Moñino) wrote…
right, I’m diving how to deal with this.
MockUI could just always set a new MockDeploymentConfiguration()
to the session if none is there and for the mode changes use the MockDeploymentConfiguration.setCompatibilityMode(boolean)
instead of playing with a mock instance.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador and @manolo)
flow-server/src/test/java/com/vaadin/tests/util/AlwaysLockedVaadinSession.java, line 11 at r2 (raw file):
Previously, caalador wrote…
MockUI could just always set a
new MockDeploymentConfiguration()
to the session if none is there and for the mode changes use theMockDeploymentConfiguration.setCompatibilityMode(boolean)
instead of playing with a mock instance.
Also instead of a VaadinService mock it should set a new MockVaadinServletService()
5005c11
to
46ff0d2
Compare
46ff0d2
to
e19bfda
Compare
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador)
flow-server/src/test/java/com/vaadin/tests/util/AlwaysLockedVaadinSession.java, line 11 at r2 (raw file):
Previously, caalador wrote…
Also instead of a VaadinService mock it should set a
new MockVaadinServletService()
MockUI
already have static methods for creating them, but they cannot be used in failing tests because they need RouterTestUI
instead, and other tests do not use the MockUI
Adjusted the failing tests so as they set correctly the configuration object before
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador)
flow-server/src/test/java/com/vaadin/tests/util/AlwaysLockedVaadinSession.java, line 11 at r2 (raw file):
Previously, manolo (Manuel Carrasco Moñino) wrote…
MockUI
already have static methods for creating them, but they cannot be used in failing tests because they needRouterTestUI
instead, and other tests do not use theMockUI
Adjusted the failing tests so as they set correctly the configuration object before
BTW, I added a test for checking that theme is not computed in npm
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewable status: 2 unresolved discussions, 0 of 1 LGTMs obtained (waiting on @caalador)
flow-server/src/test/java/com/vaadin/tests/util/AlwaysLockedVaadinSession.java, line 11 at r2 (raw file):
Previously, manolo (Manuel Carrasco Moñino) wrote…
BTW, I added a test for checking that theme is not computed in npm
Done.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Reviewed 4 of 4 files at r3.
Reviewable status: complete! all discussions resolved, 1 of 1 LGTMs obtained
This change is