[new feature] Toast: add iconPrefix option (#3872)

This commit is contained in:
neverland
2019-07-17 10:34:02 +08:00
committed by GitHub
parent e653484f39
commit 1c09a44751
6 changed files with 24 additions and 2 deletions
+11
View File
@@ -60,6 +60,17 @@ test('icon prop', async () => {
expect(toast.$el.outerHTML).toMatchSnapshot();
});
test('icon-prefix prop', async () => {
const toast = Toast({
message: 'Message',
icon: 'star-o',
iconPrefix: 'my-icon'
});
await later();
expect(toast.$el.outerHTML).toMatchSnapshot();
});
test('clear toast', () => {
const toast1 = Toast();
expect(toast1.value).toBeTruthy();