Skip to content
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

Fix #4599 - PR Checker build failing #4600

Merged
merged 1 commit into from
Oct 13, 2023

Conversation

FlipWarthog
Copy link
Contributor

Fix #4599 - PR Checker build failing

Creating as a draft to test the workflows

@vercel
Copy link

vercel bot commented Oct 12, 2023

The latest updates on your projects. Learn more about Vercel for Git ↗︎

1 Ignored Deployment
Name Status Preview Comments Updated (UTC)
primevue ⬜️ Ignored (Inspect) Visit Preview Oct 12, 2023 11:40pm

@FlipWarthog
Copy link
Contributor Author

@mertsincan I stole your comment from #4512 and included it in the main vitest config.

Comment on lines +83 to +85
if (event) {
event.preventDefault();
}
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Test was failing with event undefined due to the call on line 92.

@@ -79,6 +79,6 @@ describe('Button.vue', () => {
}
});

expect(wrapper.html()).toBe(`<button class="p-button p-component" type="button" data-pc-name="button" data-pc-section="root" data-pd-ripple="true"><span class="ml-2 font-bold">Default PrimeVue Button</span></button>`);
expect(wrapper.html()).toBe(`<button class="p-button p-component" type="button" data-pc-name="button" data-pc-section="root"><span class="ml-2 font-bold">Default PrimeVue Button</span></button>`);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Still investigating this. I think it's just a ripple config change?

Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Investigated, ripple is disabled in the default configs which the tests are using so this is a correct assert.

@@ -37,7 +37,7 @@ describe('Rating.vue', () => {
it('When star is clicked, onOptionClick method should triggered', async () => {
await wrapper.find('.p-rating-item').trigger('click');

expect(wrapper.find('.p-focus').exists()).toBe(true);
expect(wrapper.find('[data-p-focused="true"]').exists()).toBe(true);
Copy link
Contributor Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

p-focus is not added on click, just keyboard nav, so looking for the data attribute instead.

@FlipWarthog FlipWarthog marked this pull request as ready for review October 13, 2023 00:39
@tugcekucukoglu tugcekucukoglu merged commit eda7998 into primefaces:master Oct 13, 2023
2 checks passed
@FlipWarthog FlipWarthog deleted the test-fix branch October 13, 2023 15:58
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

PR Checker build failing
2 participants