Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion src/__tests__/validate-plugin.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,7 +16,7 @@ test('can validate using plugin', async () => {
)

// Assert error messages are not in the DOM when rendering the component.
expect(queryByTestId('username-errors')).toBeNull()
expect(queryByTestId('username-errors')).not.toBeInTheDocument()

const usernameInput = getByPlaceholderText('Username...')
await fireEvent.touch(usernameInput)
Expand Down
2 changes: 1 addition & 1 deletion src/__tests__/vue-i18n.js
Original file line number Diff line number Diff line change
Expand Up @@ -36,5 +36,5 @@ test('renders translations', async () => {

expect(getByText('こんにちは')).toBeInTheDocument()

expect(queryByText('Hello')).toBeNull()
expect(queryByText('Hello')).not.toBeInTheDocument()
})
8 changes: 6 additions & 2 deletions types/index.d.ts
Original file line number Diff line number Diff line change
Expand Up @@ -46,12 +46,16 @@ export interface RenderOptions<V extends Vue, S = {}>
baseElement?: Element
}

export type ConfigurationCallback<V extends Vue> = (
type ConfigurationArgs = [
localVue: typeof Vue,
// eslint-disable-next-line @typescript-eslint/no-explicit-any
store: Store<any>,
router: Router,
) => Partial<ThisTypedMountOptions<V>> | void
]

export type ConfigurationCallback<V extends Vue> =
| ((...args: ConfigurationArgs) => Partial<ThisTypedMountOptions<V>>)
| ((...args: ConfigurationArgs) => void)

export function render<V extends Vue>(
TestComponent: VueClass<V> | ComponentOptions<V>,
Expand Down