From ccc5c5f631810d5f316efeec555b1b0995dee431 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=AD=99=E6=98=8A=E7=BF=94?= <673686754@qq.com> Date: Fri, 4 Jan 2019 13:07:39 +0800 Subject: [PATCH] unit test: d2-container-full-bs Former-commit-id: 283e7db715965f9a3bef2755bd885ea7edd8629b [formerly 283e7db715965f9a3bef2755bd885ea7edd8629b [formerly 283e7db715965f9a3bef2755bd885ea7edd8629b [formerly 283e7db715965f9a3bef2755bd885ea7edd8629b [formerly 4c20b5b7a5a86fb78bacb1ee3106032db07dd50b [formerly 63b3feba8b2ef8982c25697b53bbf4341925e290]]]]] Former-commit-id: 93ae445a627e3c17dcb2a8d5afebf19e58025fd4 Former-commit-id: 8880b3e9a48f09f6c0351b625224d4d31881fc3e Former-commit-id: 146e5ee8dbfeb2f6b0774d0b94482d3963bf2685 [formerly 5783bd169e1cc31b5ebc5e87dc2bf889cb428a80] Former-commit-id: 5bacf88c3d52084893f319c83db2f3bc1866e1bf Former-commit-id: 413ba702b7376ba92f233387f6a1146dc4f9402d Former-commit-id: f286c8987e4799a161b59209251400a2aa4037e1 Former-commit-id: bba6285faddc0a2f89e6f350fb0822271f8760ad Former-commit-id: a5e70c2b975db855bce46ad0dc1f2f25507d1981 --- tests/unit/d2-container-full-bs.spec.js | 55 +++++++++++++++++++++++++ 1 file changed, 55 insertions(+) create mode 100644 tests/unit/d2-container-full-bs.spec.js diff --git a/tests/unit/d2-container-full-bs.spec.js b/tests/unit/d2-container-full-bs.spec.js new file mode 100644 index 00000000..67464602 --- /dev/null +++ b/tests/unit/d2-container-full-bs.spec.js @@ -0,0 +1,55 @@ +import { mount } from '@vue/test-utils' +import D2ContainerFullBs from '@/components/d2-container/components/d2-container-full-bs.vue' + +describe('d2-container-full-bs.vue', () => { + // 存在且是Vue组件实例 + it('is a vue instance', () => { + const wrapper = mount(D2ContainerFullBs) + + expect(wrapper.exists()).toBeTruthy() + expect(wrapper.isVueInstance()).toBeTruthy() + }) + + // 包含特定类名 + it('contains specific classnames', () => { + const wrapper = mount(D2ContainerFullBs, { + slots: { + default: '