Skip to content

Commit 7fc7af3

Browse files
committed
rename env
1 parent 62b856b commit 7fc7af3

File tree

2 files changed

+4
-4
lines changed

2 files changed

+4
-4
lines changed

src/__tests__/fire-event.js

+1-1
Original file line numberDiff line numberDiff line change
@@ -231,7 +231,7 @@ test('fireEvent.update does not crash if non-input element is passed in', async
231231
})
232232

233233
test('fireEvent change/input should not throw warning when env is set', async () => {
234-
process.env.VTL_WARN_EVENT_UPDATE = 'false'
234+
process.env.WARN_EVENT_UPDATE = 'false'
235235
const {getByTestId} = render({
236236
template: `<input type="text" data-testid=test-input></input>`,
237237
})

src/vue-testing-library.js

+3-3
Original file line numberDiff line numberDiff line change
@@ -117,7 +117,7 @@ const changeOrInputEventCalledDirectly = (eventValue, eventKey) =>
117117

118118
Object.keys(dtlFireEvent).forEach(key => {
119119
fireEvent[key] = async (...args) => {
120-
if (process.env.VTL_WARN_EVENT_UPDATE === 'true' && changeOrInputEventCalledDirectly(args[1], key)) {
120+
if (process.env.WARN_EVENT_UPDATE === 'true' && changeOrInputEventCalledDirectly(args[1], key)) {
121121
console.warn(
122122
`Using "fireEvent.${key} may lead to unexpected results. Please use fireEvent.update() instead.`,
123123
)
@@ -188,8 +188,8 @@ if (typeof afterEach === 'function' && !process.env.VTL_SKIP_AUTO_CLEANUP) {
188188
})
189189
}
190190

191-
if (!process.env.VTL_WARN_EVENT_UPDATE) {
192-
process.env.VTL_WARN_EVENT_UPDATE = 'true';
191+
if (!process.env.WARN_EVENT_UPDATE) {
192+
process.env.WARN_EVENT_UPDATE = 'true';
193193
}
194194

195195
export * from '@testing-library/dom'

0 commit comments

Comments
 (0)