testing-library / vue-testing-library

🦎 Simple and complete Vue.js testing utilities that encourage good testing practices.
http://testing-library.com/vue
MIT License
1.08k stars 110 forks source link

feat: update Vue 2 version to use @testing-library/dom v8 #284

Closed oskarols closed 1 year ago

oskarols commented 2 years ago

Hi! πŸ‘‹ I was told here that a contribution to bump @testing-library/dom to v8 would be happily received, so here I am πŸ˜„

I realize I'm opening this against the wrong branch; there doesn't seem to be one for the Vue 2 version that continues from v5.8.3. Maybe you can assist me with what to do here?


This updates the version of @testing-library/dom from v7 to v8 for Vue 2.x.

Issues

oskarols commented 1 year ago

ping @afontcu ^ πŸ˜„

saifahn commented 1 year ago

@oskarols

I'm curious - why did you end up closing this PR?

@afontcu

Is there any possibility of this being merged and released in a new v5 version of Vue Testing Library? Our team would like to use the current option in queries to help us build more accessible components with corresponding tests πŸ™‚

afontcu commented 1 year ago

hi @saifahn! I don't have the bandwidth to work on that, but it should be possible by branching off latest v5 tag (https://github.com/testing-library/vue-testing-library/tree/v5.8.3) and submitting a PR there πŸ‘

oskarols commented 1 year ago

@saifahn Understandably this didn't get any attention and we couldn't wait, so we used the resolutions field in Yarn to override the @testing-library/dom version.

saifahn commented 1 year ago

@afontcu

Thanks for getting back to me! I actually created a fork branching off the v5.8.3 tag and made a commit. I was in the middle of making a PR when I noticed that I couldn't make a PR back to that tag - I can only compare the changes:

image

This makes sense because the tag simply points to a commit and is not something that can be updated. Perhaps we could make a separate branch that starts at the same point as v5.8.3 that could be used to track the v5 version and be used for releasing the v5 version?

If you agree with this approach, then we could reopen this PR and point it at that branch, seeing as the changes are the same as what I have done in my fork/branch as well. Looking forward to hearing your thoughts πŸ™‚

@oskarols

Thanks for sharing your workaround. It looks like overrides may be what we may have to go with in npm if it comes to it.

saifahn commented 1 year ago

@afontcu

Tagging you in case this slipped under the radar. As stated above, I didn't make a PR because even after forking the v5.8.3 tag.

I wonder if you have any thoughts on my proposal? πŸ˜„

afontcu commented 1 year ago

hey!

Perhaps we could make a separate branch that starts at the same point as v5.8.3 that could be used to track the v5 version and be used for releasing the v5 version?

Yeah, that sounds about right. I think it should be called 5.x, so that semantic-release is able to pick it up as a follow-up branch for v5

saifahn commented 1 year ago

Great!

Do you think you could create the branch in this repository from the 5.8.3 tag? (Seeing as I don't have those permissions πŸ˜„)

Then I can open a PR that will merge into that branch. (Or we could reopen this PR pointing there)

Thanks!

afontcu commented 1 year ago

hey @saifahn! this should be available in v5.9!

saifahn commented 1 year ago

@afontcu Thanks so much for the update πŸ’œ