diff options
Diffstat (limited to 'web_src/js/modules/toast.test.ts')
-rw-r--r-- | web_src/js/modules/toast.test.ts | 16 |
1 files changed, 16 insertions, 0 deletions
diff --git a/web_src/js/modules/toast.test.ts b/web_src/js/modules/toast.test.ts new file mode 100644 index 0000000000..b29e9a32bd --- /dev/null +++ b/web_src/js/modules/toast.test.ts @@ -0,0 +1,16 @@ +import {showInfoToast, showErrorToast, showWarningToast} from './toast.ts'; + +test('showInfoToast', async () => { + showInfoToast('success 😀', {duration: -1}); + expect(document.querySelector('.toastify')).toBeTruthy(); +}); + +test('showWarningToast', async () => { + showWarningToast('warning 😐', {duration: -1}); + expect(document.querySelector('.toastify')).toBeTruthy(); +}); + +test('showErrorToast', async () => { + showErrorToast('error 🙁', {duration: -1}); + expect(document.querySelector('.toastify')).toBeTruthy(); +}); |