Skip to content

stubbed child doesn't emit event when root #164

Open
@willkenson

Description

@willkenson

<template> <child-component v-on:customevent="customeventhandler"><div>slot content here</div></child-component></template>

(with component shallow mounted in jest)
wrapper.find('child-component-stub').vm.$emit('customevent');

the event doesn't fire.
however if i wrap the <child-component> in a <div> so it is not the root element, it works fine.

(the events also work fine on the actual page.. just not in jest)

is this a bug?

Metadata

Metadata

Assignees

No one assigned

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions