File tree Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Expand file tree Collapse file tree 2 files changed +11
-0
lines changed Original file line number Diff line number Diff line change @@ -67,6 +67,9 @@ interface Wrapper<V extends Vue> extends BaseWrapper {
6767 html ( ) : string
6868 text ( ) : string
6969 name ( ) : string
70+
71+ emitted ( ) : { [ name : string ] : Array < Array < any > > }
72+ emittedByOrder ( ) : Array < { name : string , args : Array < any > } >
7073}
7174
7275interface WrapperArray < V extends Vue > extends BaseWrapper {
Original file line number Diff line number Diff line change @@ -21,6 +21,14 @@ bool = wrapper.is(normalOptions)
2121bool = wrapper . isEmpty ( )
2222bool = wrapper . isVueInstance ( )
2323
24+ wrapper . vm . $emit ( 'hello' )
25+
26+ const emitted = wrapper . emitted ( )
27+ const arr : Array < any > = emitted . hello
28+
29+ const emittedByOrder = wrapper . emittedByOrder ( )
30+ const name : string = emittedByOrder [ 0 ] . name
31+
2432wrapper . update ( )
2533wrapper . setData ( { foo : 'bar' } )
2634wrapper . setMethods ( { checked : true } )
You can’t perform that action at this time.
0 commit comments