[improvement] Actionsheet: add index param for select event (#2917)

This commit is contained in:
neverland
2019-03-07 20:59:46 +08:00
committed by GitHub
parent c9e578c0cf
commit bfa8f38585
4 changed files with 6 additions and 5 deletions
+2 -1
View File
@@ -33,7 +33,8 @@ test('callback events', () => {
expect(callback.mock.calls.length).toBe(1);
expect(onCancel.mock.calls.length).toBeTruthy();
expect(onInput.mock.calls[0][0]).toBeFalsy();
expect(onSelect.mock.calls[0][0]).toBeTruthy();
expect(onSelect.mock.calls[0][0].name).toEqual('Option');
expect(onSelect.mock.calls[0][1]).toEqual(0);
expect(onSelect.mock.calls[0][1]).toBeFalsy();
expect(wrapper).toMatchSnapshot();
});