Skip to content

Conversation

mshabarov
Copy link
Contributor

Description

A second part of vaadin/testbench#1899, adds this new mixin interface for TestBench elements.

Type of change

  • Bugfix
  • Feature

Checklist

  • I have read the contribution guide: https://vaadin.com/docs/latest/contributing/overview
  • I have added a description following the guideline.
  • The issue is created in the corresponding repository and I have referenced it.
  • I have added tests to ensure my change is effective and works as intended.
  • New and existing tests are passing locally with my change.
  • I have performed self-review and corrected misspellings.
  • I have not completed some of the steps above and my pull request can be closed immediately.

Additional for Feature type of change

  • Enhancement / new feature was discussed in a corresponding GitHub issue and Acceptance Criteria were created.

@mshabarov mshabarov changed the title feat: Add HasValidatio mixin to TestBench elements feat: Add HasValidation mixin to TestBench elements Apr 23, 2025
@mshabarov mshabarov marked this pull request as draft April 23, 2025 09:53
@mshabarov
Copy link
Contributor Author

Converted to a draft as this needs tests.

mshabarov added 2 commits May 9, 2025 16:25
# Conflicts:
#	vaadin-text-field-flow-parent/vaadin-text-field-flow-integration-tests/src/test/java/com/vaadin/flow/component/textfield/tests/BigDecimalFieldPageIT.java
#	vaadin-text-field-flow-parent/vaadin-text-field-flow-integration-tests/src/test/java/com/vaadin/flow/component/textfield/tests/EmailFieldPageIT.java
#	vaadin-text-field-flow-parent/vaadin-text-field-flow-integration-tests/src/test/java/com/vaadin/flow/component/textfield/tests/IntegerFieldPageIT.java
#	vaadin-text-field-flow-parent/vaadin-text-field-flow-integration-tests/src/test/java/com/vaadin/flow/component/textfield/tests/NumberFieldPageIT.java
#	vaadin-text-field-flow-parent/vaadin-text-field-flow-integration-tests/src/test/java/com/vaadin/flow/component/textfield/tests/PasswordFieldPageIT.java
#	vaadin-text-field-flow-parent/vaadin-text-field-flow-integration-tests/src/test/java/com/vaadin/flow/component/textfield/tests/TextFieldPageIT.java
@mshabarov mshabarov requested a review from TatuLund May 9, 2025 13:33
@mshabarov
Copy link
Contributor Author

@TatuLund some tests that used "invalid", "required" and "errorMessage" properties directly have been recently removed.
I changed those tests that remained, do you think it's enough?

@mshabarov mshabarov marked this pull request as ready for review May 9, 2025 13:53
@TatuLund
Copy link
Contributor

TatuLund commented May 9, 2025

@TatuLund some tests that used "invalid", "required" and "errorMessage" properties directly have been recently removed. I changed those tests that remained, do you think it's enough?

Yes, coverage is ok.

@mshabarov mshabarov requested a review from TatuLund May 12, 2025 09:10
mshabarov added 2 commits May 12, 2025 13:49
…/test/java/com/vaadin/flow/component/crud/tests/EventHandlingIT.java
@mshabarov mshabarov requested a review from TatuLund May 12, 2025 12:43
@mshabarov
Copy link
Contributor Author

Sonar requested javadoc and redesign of AbstractValidationIT, I'd skip that 🙂

@mshabarov mshabarov enabled auto-merge (squash) May 13, 2025 17:56
Copy link

Quality Gate Failed Quality Gate failed

Failed conditions
D Maintainability Rating on New Code (required ≥ A)

See analysis details on SonarQube Cloud

Catch issues before they fail your Quality Gate with our IDE extension SonarQube for IDE

@mshabarov mshabarov merged commit 575d6a9 into main May 13, 2025
4 of 5 checks passed
@mshabarov mshabarov deleted the has-validation-mixin branch May 13, 2025 18:41
@vaadin-bot
Copy link
Collaborator

Hi @mshabarov and @mshabarov, when i performed cherry-pick to this commit to 23.6, i have encountered the following issue. Can you take a look and pick it manually?
Error Message:
Error: Command failed: git cherry-pick 575d6a9
error: could not apply 575d6a9... feat: Add HasValidation mixin to TestBench elements (#7327)
hint: After resolving the conflicts, mark them with
hint: "git add/rm ", then run
hint: "git cherry-pick --continue".
hint: You can instead skip this commit with "git cherry-pick --skip".
hint: To abort and get back to the state before "git cherry-pick",
hint: run "git cherry-pick --abort".

mshabarov added a commit that referenced this pull request May 14, 2025
---------

Co-authored-by: Tatu Lund <tatu@vaadin.com>

(cherry picked from commit 575d6a9)
mshabarov added a commit that referenced this pull request May 16, 2025
---------

Co-authored-by: Tatu Lund <tatu@vaadin.com>

(cherry picked from commit 575d6a9)
@vaadin-bot
Copy link
Collaborator

This ticket/PR has been released with Vaadin 24.8.0.alpha8 and is also targeting the upcoming stable 24.8.0 version.

@vaadin-bot
Copy link
Collaborator

This ticket/PR has been released with Vaadin 25.0.0-alpha1.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants