Skip to content

Commit 0119d24

Browse files
committed
Allow propsData (mark as breaking change)
1 parent ceb8172 commit 0119d24

File tree

1 file changed

+6
-3
lines changed

1 file changed

+6
-3
lines changed

src/vue-testing-library.js

Lines changed: 6 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,9 +56,12 @@ function render(
5656
additionalOptions = configurationCb(vuexStore, router)
5757
}
5858

59-
if (!mountOptions.propsData && !!mountOptions.props) {
60-
mountOptions.propsData = mountOptions.props
61-
delete mountOptions.props
59+
// If `propsData` is provided, rename it to `props`
60+
// Since this is gonna be a breaking channge, we can remove the
61+
// whole thing.
62+
if (!mountOptions.props && !!mountOptions.propsData) {
63+
mountOptions.props = mountOptions.propsData
64+
delete mountOptions.propsData
6265
}
6366

6467
const wrapper = mount(TestComponent, {

0 commit comments

Comments
 (0)