test: remove real Vaadin components from vaadin-spring-tests#24958
Open
Artur- wants to merge 1 commit into
Open
test: remove real Vaadin components from vaadin-spring-tests#24958Artur- wants to merge 1 commit into
Artur- wants to merge 1 commit into
Conversation
The spring test modules pulled real Vaadin platform web components transitively, which dragged the whole @vaadin/* component npm closure into every frontend build. That made the it-tests job fail intermittently under the pnpm minimum-release-age guard whenever those components were freshly published, and it kept the tests dependent on components that Flow itself no longer uses. Replace the component usages with faux, Flow-owned equivalents that pull no component npm packages: - Swap the real vaadin-lumo-theme for flow-test-lumo (the stub Lumo class that satisfies Flow's @theme(name) classpath check) plus test-lumo-theme (the fake-lumo.css public resource). The real dependency also leaked in transitively through vaadin-test-spring-helpers, so the swap lives in the shared parent pom and covers every module at once. - Replace the vaadin Upload component in the four security-flow modules with a native Input(file) + UploadHandler that posts a raw XHR body with an X-Filename header (the servlets are not @MultipartConfig), matching the existing test-spring-common UploadView. - Drop the @vaadin/vaadin-themable-mixin import from the reload-time benchmark.js, building the global stylesheet from a plain string instead. - Remove the benchmark-directory-addons profile that pulled vaadin-core and third-party add-ons, and the now-unused component.version property. Unify the upload code the security apps duplicated: the loan-application upload UI moves to a shared LoanApplicationUpload helper in test-spring-helpers, and the browser file-transfer logic (setLocalFileDetector) becomes a uploadFileToNativeInput method on the shared AbstractSpringTest base, also reused by the existing test-spring-common UploadIT.
Contributor
|
mcollovati
reviewed
Jul 9, 2026
| </plugins> | ||
| </build> | ||
|
|
||
| <profiles> |
Collaborator
There was a problem hiding this comment.
I guess the dependencies were added to increase the startup class scanning effort. Removing all of them might somehow make the benchmark tests less effective.
Member
Author
There was a problem hiding this comment.
Yes but the benchmark would need to be outside the flow project if it tests the full platform
Collaborator
There was a problem hiding this comment.
Makes sense. Actually, it already runs only as a nightly CI build, not during PR validation.
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.



The spring test modules pulled real Vaadin platform web components transitively, which dragged the whole @vaadin/* component npm closure into every frontend build. That made the it-tests job fail intermittently under the pnpm minimum-release-age guard whenever those components were freshly published, and it kept the tests dependent on components that Flow itself no longer uses.
Replace the component usages with faux, Flow-owned equivalents that pull no component npm packages:
Unify the upload code the security apps duplicated: the loan-application upload UI moves to a shared LoanApplicationUpload helper in test-spring-helpers, and the browser file-transfer logic (setLocalFileDetector) becomes a uploadFileToNativeInput method on the shared AbstractSpringTest base, also reused by the existing test-spring-common UploadIT.