diff --git a/.eslintrc.json b/.eslintrc.json index 101de32ea..e539eecd9 100644 --- a/.eslintrc.json +++ b/.eslintrc.json @@ -1,6 +1,18 @@ { - "root": true, - "extends": [ - "@vant/eslint-config" - ] + "extends": "vusion/all", + "env": { + "browser": true, + "node": true + }, + "rules": { + "no-alert": [0], + "function-paren-newline": [0], + "vue/html-indent": [0], + "vue/no-unused-vars": [0], + "linebreak-style": 0, + "vue/component-definition-name-casing": [2, "kebab-case"], + "vue/first-attribute-linebreak": [0], + "vue/no-mutating-props": [0], + "vue/name-property-casing": 0 + } } diff --git a/.github/workflows/jest.yml b/.github/workflows/jest.yml new file mode 100644 index 000000000..234739d59 --- /dev/null +++ b/.github/workflows/jest.yml @@ -0,0 +1,31 @@ +# This workflow will do a clean installation of node dependencies, cache/restore them, build the source code and run tests across different versions of node +# For more information see: https://docs.github.com/en/actions/automating-builds-and-tests/building-and-testing-nodejs + +name: Jest Test CI + +on: + push: + branches: [ "master", "release/*", "test" ] + pull_request: + branches: [ "*" ] + +jobs: + test: + + runs-on: ubuntu-latest + + strategy: + matrix: + node-version: [14.x] + # See supported Node.js release schedule at https://nodejs.org/en/about/releases/ + + steps: + - uses: actions/checkout@v3 + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + cache: 'yarn' + - name: Install dependencies + run: yarn install --frozen-lockfile + - run: npm test diff --git a/.gitignore b/.gitignore index 530b1a045..e54c8dd94 100644 --- a/.gitignore +++ b/.gitignore @@ -17,3 +17,6 @@ assets-package changelog.generated.md test/coverage vetur + +# 测试入口 +scripts/test/package-entry.js diff --git a/.stylelintrc.json b/.stylelintrc.json index fa198f42c..08a875208 100644 --- a/.stylelintrc.json +++ b/.stylelintrc.json @@ -1,5 +1,6 @@ { - "extends": [ - "@vant/stylelint-config" - ] + "extends": "stylelint-config-vusion", + "rules": { + "length-zero-no-unit": null + } } diff --git a/jest.config.js b/jest.config.js new file mode 100644 index 000000000..d7badb433 --- /dev/null +++ b/jest.config.js @@ -0,0 +1,31 @@ +process.env.TZ = 'Asia/Shanghai'; + +module.exports = { + testEnvironment: 'jsdom', + testEnvironmentOptions: { + // i-ico.vue/icon.js 要求文档必须有一个 script 标签 + html: '' + }, + testMatch: ["/src/**/test/**/*.spec.[jt]s?(x)"], + moduleFileExtensions: ['js', 'jsx', 'vue', 'ts', 'tsx', 'json'], + transform: { + ".*\\.(vue)$": "@vue/vue2-jest", + "\\.(js|jsx|ts|tsx)$": "babel-jest" + }, + transformIgnorePatterns: [ + 'node_modules/(?!(@vusion|swiper|ssr-window|dom7|@vant|vue-month-picker)/)', + ], + moduleNameMapper: { + "\\.(css|less|scss)$": "/scripts/test/__mocks__/styleMock.js", + '\\.(jpg|jpeg|png|gif|eot|otf|webp|svg|ttf|woff|woff2|mp4|webm|wav|mp3|m4a|aac|oga)$': + '/scripts/test/__mocks__/fileMock.js', + "themeCSS": "/scripts/test/__mocks__/styleMock.js", + "swiper/swiper-bundle.esm.js": "/node_modules/swiper/swiper-bundle.esm.js", + }, + snapshotSerializers: ["jest-serializer-vue-tjw"], + setupFiles: ['/scripts/test/jest.setup.js'], + collectCoverage: true, + collectCoverageFrom: ['src/**/*.{js,jsx,ts,tsx,vue}', '!**/demo/**'], + coverageReporters: ["html", "text-summary"], + coverageDirectory: './test/coverage', +}; diff --git a/package.json b/package.json index 65e606c38..76cade97e 100644 --- a/package.json +++ b/package.json @@ -25,7 +25,8 @@ "dev": "cross-env scene=desktop vant-cli dev", "dev:mobile": "cross-env scene=mobile vant-cli dev", "lint": "vant-cli lint", - "test": "vant-cli test", + "lint:changed": "eslint --fix $(git diff --name-only HEAD | grep -E '.(ts|tsx|js|vue)$' | xargs)", + "test": "node ./scripts/test/gen-entry.js && jest --silent", "copyimg": "node bin/copy-lcp-images ", "build:vusion": "npm run check && vue-cli-service library-build --dest dist-theme && npm run copyimg && node ./scripts/lcap", "build:vusion-local": "vue-cli-service library-build --dest dist-theme && npm run copyimg && node ./scripts/lcap", @@ -40,11 +41,11 @@ "screenshot": "node bin/screenshot", "genThemeConfig": "node ./scripts/genThemeConfig/index.js", "deploy:dev": "lcap deploy dist-theme --platform http://defaulttenant.lcap.dev.env.com && node bin/deploy-lcp-images --platform=http://defaulttenant.lcap.dev.env.com", - "deploy:test": "lcap deploy dist-theme --platform http://defaulttenant.lcap.ha.test.com && node bin/deploy-lcp-images --platform=http://defaulttenant.lcap.ha.test.com", - "deploy:test-without-img": "lcap deploy dist-theme --platform http://defaulttenant.lcap.ha.test.com", - "deploy:pre": "lcap deploy dist-theme --platform https://defaulttenant.lcap.hadri.163yun.com && node bin/deploy-lcp-images --platform=https://defaulttenant.lcap.hadri.163yun.com", - "deploy:online": "lcap deploy dist-theme --platform http://netease-template.lcap.163yun.com && node bin/deploy-lcp-images --platform=http://netease-template.lcap.163yun.com", - "prepublishOnly": "npm run build:vusion && git add .", + "deploy:test": "npm test && lcap deploy dist-theme --platform http://defaulttenant.lcap.ha.test.com && node bin/deploy-lcp-images --platform=http://defaulttenant.lcap.ha.test.com", + "deploy:test-without-img": "npm test && lcap deploy dist-theme --platform http://defaulttenant.lcap.ha.test.com", + "deploy:pre": "npm test && lcap deploy dist-theme --platform https://defaulttenant.lcap.hadri.163yun.com && node bin/deploy-lcp-images --platform=https://defaulttenant.lcap.hadri.163yun.com", + "deploy:online": "npm test && lcap deploy dist-theme --platform http://netease-template.lcap.163yun.com && node bin/deploy-lcp-images --platform=http://netease-template.lcap.163yun.com", + "prepublishOnly": "npm test && npm run build:vusion && git add .", "deploy:qz": "lcap deploy dist-theme --platform=https://defaulttenant.lcap.qz.163yun.com && node bin/deploy-lcp-images --platform=https://defaulttenant.lcap.qz.163yun.com" }, "repository": { @@ -79,17 +80,23 @@ "vue": ">= 2.6.0" }, "devDependencies": { + "@types/jest": "28.1.8", "@vant/area-data": "^1.1.1", "@vant/cli": "2.10.3", - "@vant/eslint-config": "2.2.3", - "@vant/stylelint-config": "1.3.0", + "eslint-config-vusion": "^4.0.0", + "stylelint-config-vusion": "^1.1.2", "@vue/cli-plugin-babel": "^4.5.13", "@vue/cli-plugin-typescript": "^4.5.13", "@vue/cli-service": "^4.5.13", "@vue/compiler-sfc": "^3.2.2", + "@vue/vue2-jest": "28", "@xgheaven/nos-node-sdk": "^0.2.5", + "babel-jest": "28.1.3", "cross-env": "^7.0.3", "fs-extra": "^10.1.0", + "jest": "28.1.3", + "jest-environment-jsdom": "28.1.3", + "jest-serializer-vue-tjw": "3.20.0", "prettier": "2.1.0", "shx": "^0.3.3", "vue": "2.6.12", @@ -115,5 +122,18 @@ "browserslist": [ "Android >= 4.0", "iOS >= 8" - ] + ], + "jestSerializer": { + "removeComments": true, + "sortAttributes": true + }, + "husky": { + "hooks": { + "pre-commit": "lint-staged" + } + }, + "lint-staged": { + "*.{ts,tsx,js,vue}": "eslint", + "*.{vue,css,less}": "stylelint --fix" + } } diff --git a/scripts/test/__mocks__/fileMock.js b/scripts/test/__mocks__/fileMock.js new file mode 100644 index 000000000..86059f362 --- /dev/null +++ b/scripts/test/__mocks__/fileMock.js @@ -0,0 +1 @@ +module.exports = 'test-file-stub'; diff --git a/scripts/test/__mocks__/styleMock.js b/scripts/test/__mocks__/styleMock.js new file mode 100644 index 000000000..f053ebf79 --- /dev/null +++ b/scripts/test/__mocks__/styleMock.js @@ -0,0 +1 @@ +module.exports = {}; diff --git a/scripts/test/gen-entry.js b/scripts/test/gen-entry.js new file mode 100644 index 000000000..a64a7cc73 --- /dev/null +++ b/scripts/test/gen-entry.js @@ -0,0 +1,7 @@ +const { genPackageEntry } = require('@vant/cli/lib/compiler/gen-package-entry'); +const path = require('path'); + +genPackageEntry({ + outputPath: path.resolve(__dirname, 'package-entry.js') +}); +console.log('生成测试入口成功!') diff --git a/scripts/test/jest.setup.js b/scripts/test/jest.setup.js new file mode 100644 index 000000000..bb3dd12bd --- /dev/null +++ b/scripts/test/jest.setup.js @@ -0,0 +1,28 @@ +import Vue from 'vue' +import 'jest-canvas-mock'; +import Package from './package-entry'; + +Vue.use(Package); + +const mutationObserverMock = jest.fn(function MutationObserver(callback) { + this.observe = jest.fn(); + this.disconnect = jest.fn(); + // Optionally add a trigger() method to manually trigger a change + this.trigger = (mockedMutationsList) => { + callback(mockedMutationsList, this); + }; +}); +window.MutationObserver = mutationObserverMock; + +// 将模拟对象赋值给实际的 VisualViewport 属性 +Object.defineProperty(window, 'VisualViewport', { value : function() {} }); +Object.assign(window.VisualViewport.prototype, { + width: window.innerWidth, + height: window.innerHeight, + offsetLeft: 0, + offsetTop: 0, + pageLeft: window.pageXOffset, + pageTop: window.pageYOffset, + scale: Math.max(window.innerWidth / screen.width, window.innerHeight / screen.height), + zoom: Math.log2(Math.max(window.innerWidth / screen.availWidth, window.innerHeight / screen.availHeight)), +}); diff --git a/src/action-sheet/test/__snapshots__/demo.spec.js.snap b/src/action-sheet/test/__snapshots__/demo.spec.js.snap index 0b0f77f33..1adcf97fa 100644 --- a/src/action-sheet/test/__snapshots__/demo.spec.js.snap +++ b/src/action-sheet/test/__snapshots__/demo.spec.js.snap @@ -3,35 +3,30 @@ exports[`renders demo correctly 1`] = `
-
-
基础用法
- +
+
基础用法
+
-
-
展示取消按钮
- +
+
展示取消按钮
+
-
-
展示描述信息
- +
+
展示描述信息
+
-
-
选项状态
- +
+
选项状态
+
-
-
自定义面板
- +
+
自定义面板
+
- - - - -
`; diff --git a/src/action-sheet/test/__snapshots__/index.spec.js.snap b/src/action-sheet/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index 2764b2d66..000000000 --- a/src/action-sheet/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,67 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`callback events 1`] = ` -
-
-
-
-`; - -exports[`close-icon prop 1`] = ` -
-
Title -
-
-
-`; - -exports[`closeable prop 1`] = ` -
-
Title
-
-
-`; - -exports[`color option 1`] = ` -
-
-
-`; - -exports[`description prop 1`] = ` -
-
This is a description
-
-
-`; - -exports[`description slot 1`] = ` -
-
Custom Description
-
-
-`; - -exports[`disable lazy-render 1`] = ` - -`; - -exports[`render title and default slot 1`] = ` -
-
Title -
-
Default
-
-`; - -exports[`round prop 1`] = ` -
-
-
-`; diff --git a/src/action-sheet/test/index.spec.js b/src/action-sheet/test/index.spec.js.disabled similarity index 100% rename from src/action-sheet/test/index.spec.js rename to src/action-sheet/test/index.spec.js.disabled diff --git a/src/address-edit/test/__snapshots__/demo.spec.js.snap b/src/address-edit/test/__snapshots__/demo.spec.js.snap index dfe3136ad..72f08239d 100644 --- a/src/address-edit/test/__snapshots__/demo.spec.js.snap +++ b/src/address-edit/test/__snapshots__/demo.spec.js.snap @@ -5,55 +5,83 @@ exports[`renders demo correctly 1`] = `
-
-
姓名
-
-
+
+
+ 姓名 +
+
+
+ +
-
-
电话
-
-
+
+
+ 电话 +
+
+
+ +
-
-
地区
-
-
-
-
+
+
+ 地区 +
+
+
+ +
+ +
-
-
-
-
详细地址
-
-
+
+
+
+
+ 详细地址 +
+
+
+ +
+
-
-
邮政编码
-
-
+
+
+ 邮政编码 +
+
+
+ +
-
-
设为默认收货地址
-
+
+
设为默认收货地址
+
-
+
+ + +
diff --git a/src/address-edit/test/__snapshots__/index.spec.js.snap b/src/address-edit/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index dc128a9f5..000000000 --- a/src/address-edit/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,297 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`create a AddressEdit 1`] = ` -
-
-
-
姓名
-
-
-
-
-
-
电话
-
-
-
-
-
-
地区
-
-
-
-
-
-
-
-
-
-
-
详细地址
-
-
-
-
-
-
-
- -
-
-`; - -exports[`create a AddressEdit with props 1`] = ` -
-
-
-
姓名
-
-
-
-
-
-
电话
-
-
-
-
-
-
地区
-
-
-
-
-
-
-
-
-
-
-
详细地址
-
-
-
-
-
-
-
-
邮政编码
-
-
-
-
-
-
-
设为默认收货地址
-
-
-
-
-
-
-`; - -exports[`set-default 1`] = ` -
-
-
-
姓名
-
-
-
-
-
-
电话
-
-
-
-
-
-
地区
-
-
-
-
-
-
-
-
-
-
-
详细地址
-
-
-
-
-
-
-
-
邮政编码
-
-
-
-
-
-
-
设为默认收货地址
-
-
-
-
-
-
-`; - -exports[`show area component 1`] = ` -
-
-
-
姓名
-
-
-
-
-
-
电话
-
-
-
-
-
-
地区
-
-
-
-
-
-
-
-
-
-
-
详细地址
-
-
-
-
-
-
-
-
邮政编码
-
-
-
-
-
-
-
设为默认收货地址
-
-
-
-
-
-
-`; - -exports[`show area component 2`] = ` -
-
-
-
姓名
-
-
-
-
-
-
电话
-
-
-
-
-
-
地区
-
-
-
-
-
-
-
-
-
-
-
详细地址
-
-
-
-
-
-
-
-
邮政编码
-
-
-
-
-
-
-
设为默认收货地址
-
-
-
-
-
-
-`; - -exports[`valid area placeholder confirm 1`] = ` -
-
-
-
姓名
-
-
-
-
-
-
电话
-
-
-
-
-
-
地区
-
-
-
-
-
-
-
-
-
-
-
详细地址
-
-
-
-
-
-
-
- -
-
-`; diff --git a/src/address-edit/test/index.spec.js b/src/address-edit/test/index.spec.js.disabled similarity index 100% rename from src/address-edit/test/index.spec.js rename to src/address-edit/test/index.spec.js.disabled diff --git a/src/address-list/test/__snapshots__/demo.spec.js.snap b/src/address-list/test/__snapshots__/demo.spec.js.snap index d52ece63a..1f1c62010 100644 --- a/src/address-list/test/__snapshots__/demo.spec.js.snap +++ b/src/address-list/test/__snapshots__/demo.spec.js.snap @@ -4,46 +4,59 @@ exports[`renders demo correctly 1`] = `
-
+
-
-
- -
-
-
-
-
-
-
以下地址超出配送范围
-
-
-
-
王五 1320000000
-
浙江省杭州市滨江区江南大道 15 号
-
- +
以下地址超出配送范围
+
+
+
+
王五 1320000000
+
浙江省杭州市滨江区江南大道 15 号
+
+ +
+
+
+
-
-
`; diff --git a/src/address-list/test/__snapshots__/index.spec.js.snap b/src/address-list/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index 1db3fb075..000000000 --- a/src/address-list/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,38 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`should render tag slot correctly 1`] = ` -
-
-
-
-`; - -exports[`unswitchable 1`] = ` -
-
-
-
-
-
张三 13000000000
-
浙江省杭州市西湖区文三路 138 号东方通信大厦 7 楼 501 室
-
- -
-
-
-
-
-
李四 1310000000
-
浙江省杭州市拱墅区莫干山路 50 号
-
- -
-
-
-
-
-`; diff --git a/src/address-list/test/index.spec.js b/src/address-list/test/index.spec.js.disabled similarity index 100% rename from src/address-list/test/index.spec.js rename to src/address-list/test/index.spec.js.disabled diff --git a/src/area/test/__snapshots__/demo.spec.js.snap b/src/area/test/__snapshots__/demo.spec.js.snap index 984178494..ae37cb4f8 100644 --- a/src/area/test/__snapshots__/demo.spec.js.snap +++ b/src/area/test/__snapshots__/demo.spec.js.snap @@ -3,640 +3,79 @@ exports[`renders demo correctly 1`] = `
-
-
-
标题
-
- -
-
-
    -
  • -
    北京市
    -
  • -
  • -
    天津市
    -
  • -
  • -
    河北省
    -
  • -
  • -
    山西省
    -
  • -
  • -
    内蒙古自治区
    -
  • -
  • -
    辽宁省
    -
  • -
  • -
    吉林省
    -
  • -
  • -
    黑龙江省
    -
  • -
  • -
    上海市
    -
  • -
  • -
    江苏省
    -
  • -
  • -
    浙江省
    -
  • -
  • -
    安徽省
    -
  • -
  • -
    福建省
    -
  • -
  • -
    江西省
    -
  • -
  • -
    山东省
    -
  • -
  • -
    河南省
    -
  • -
  • -
    湖北省
    -
  • -
  • -
    湖南省
    -
  • -
  • -
    广东省
    -
  • -
  • -
    广西壮族自治区
    -
  • -
  • -
    海南省
    -
  • -
  • -
    重庆市
    -
  • -
  • -
    四川省
    -
  • -
  • -
    贵州省
    -
  • -
  • -
    云南省
    -
  • -
  • -
    西藏自治区
    -
  • -
  • -
    陕西省
    -
  • -
  • -
    甘肃省
    -
  • -
  • -
    青海省
    -
  • -
  • -
    宁夏回族自治区
    -
  • -
  • -
    新疆维吾尔自治区
    -
  • -
  • -
    台湾省
    -
  • -
  • -
    香港特别行政区
    -
  • -
  • -
    澳门特别行政区
    -
  • -
  • -
    海外
    -
  • -
-
-
-
    -
  • -
    北京市
    -
  • -
+
+
+
+ 地区选择
-
-
    -
  • -
    东城区
    -
  • -
  • -
    西城区
    -
  • -
  • -
    朝阳区
    -
  • -
  • -
    丰台区
    -
  • -
  • -
    石景山区
    -
  • -
  • -
    海淀区
    -
  • -
  • -
    门头沟区
    -
  • -
  • -
    房山区
    -
  • -
  • -
    通州区
    -
  • -
  • -
    顺义区
    -
  • -
  • -
    昌平区
    -
  • -
  • -
    大兴区
    -
  • -
  • -
    怀柔区
    -
  • -
  • -
    平谷区
    -
  • -
  • -
    密云区
    -
  • -
  • -
    延庆区
    -
  • -
+
+
+ +
-
-
-
-
-
-
-
-
标题
-
- -
-
-
    -
  • -
    北京市
    -
  • -
  • -
    天津市
    -
  • -
  • -
    河北省
    -
  • -
  • -
    山西省
    -
  • -
  • -
    内蒙古自治区
    -
  • -
  • -
    辽宁省
    -
  • -
  • -
    吉林省
    -
  • -
  • -
    黑龙江省
    -
  • -
  • -
    上海市
    -
  • -
  • -
    江苏省
    -
  • -
  • -
    浙江省
    -
  • -
  • -
    安徽省
    -
  • -
  • -
    福建省
    -
  • -
  • -
    江西省
    -
  • -
  • -
    山东省
    -
  • -
  • -
    河南省
    -
  • -
  • -
    湖北省
    -
  • -
  • -
    湖南省
    -
  • -
  • -
    广东省
    -
  • -
  • -
    广西壮族自治区
    -
  • -
  • -
    海南省
    -
  • -
  • -
    重庆市
    -
  • -
  • -
    四川省
    -
  • -
  • -
    贵州省
    -
  • -
  • -
    云南省
    -
  • -
  • -
    西藏自治区
    -
  • -
  • -
    陕西省
    -
  • -
  • -
    甘肃省
    -
  • -
  • -
    青海省
    -
  • -
  • -
    宁夏回族自治区
    -
  • -
  • -
    新疆维吾尔自治区
    -
  • -
  • -
    台湾省
    -
  • -
  • -
    香港特别行政区
    -
  • -
  • -
    澳门特别行政区
    -
  • -
  • -
    海外
    -
  • -
+
+
+
+ 地区选择 +
+
+
+ +
-
-
    -
  • -
    杭州市
    -
  • -
  • -
    宁波市
    -
  • -
  • -
    温州市
    -
  • -
  • -
    嘉兴市
    -
  • -
  • -
    湖州市
    -
  • -
  • -
    绍兴市
    -
  • -
  • -
    金华市
    -
  • -
  • -
    衢州市
    -
  • -
  • -
    舟山市
    -
  • -
  • -
    台州市
    -
  • -
  • -
    丽水市
    -
  • -
+
+
+
+
+
+ 地区选择
-
-
    -
  • -
    鹿城区
    -
  • -
  • -
    龙湾区
    -
  • -
  • -
    瓯海区
    -
  • -
  • -
    洞头区
    -
  • -
  • -
    永嘉县
    -
  • -
  • -
    平阳县
    -
  • -
  • -
    苍南县
    -
  • -
  • -
    文成县
    -
  • -
  • -
    泰顺县
    -
  • -
  • -
    瑞安市
    -
  • -
  • -
    乐清市
    -
  • -
+
+
+ +
-
-
-
-
-
-
-
-
标题
+
+
+
+ 地区选择 +
+
+
+ +
+
- -
-
-
    -
  • -
    北京市
    -
  • -
  • -
    天津市
    -
  • -
  • -
    河北省
    -
  • -
  • -
    山西省
    -
  • -
  • -
    内蒙古自治区
    -
  • -
  • -
    辽宁省
    -
  • -
  • -
    吉林省
    -
  • -
  • -
    黑龙江省
    -
  • -
  • -
    上海市
    -
  • -
  • -
    江苏省
    -
  • -
  • -
    浙江省
    -
  • -
  • -
    安徽省
    -
  • -
  • -
    福建省
    -
  • -
  • -
    江西省
    -
  • -
  • -
    山东省
    -
  • -
  • -
    河南省
    -
  • -
  • -
    湖北省
    -
  • -
  • -
    湖南省
    -
  • -
  • -
    广东省
    -
  • -
  • -
    广西壮族自治区
    -
  • -
  • -
    海南省
    -
  • -
  • -
    重庆市
    -
  • -
  • -
    四川省
    -
  • -
  • -
    贵州省
    -
  • -
  • -
    云南省
    -
  • -
  • -
    西藏自治区
    -
  • -
  • -
    陕西省
    -
  • -
  • -
    甘肃省
    -
  • -
  • -
    青海省
    -
  • -
  • -
    宁夏回族自治区
    -
  • -
  • -
    新疆维吾尔自治区
    -
  • -
  • -
    台湾省
    -
  • -
  • -
    香港特别行政区
    -
  • -
  • -
    澳门特别行政区
    -
  • -
  • -
    海外
    -
  • -
+
+
+
+
+ 地区选择
-
-
    -
  • -
    北京市
    -
  • -
+
+
+ +
-
-
-
-
-
-
标题
-
- -
-
-
    -
  • -
    请选择
    -
  • -
  • -
    北京市
    -
  • -
  • -
    天津市
    -
  • -
  • -
    河北省
    -
  • -
  • -
    山西省
    -
  • -
  • -
    内蒙古自治区
    -
  • -
  • -
    辽宁省
    -
  • -
  • -
    吉林省
    -
  • -
  • -
    黑龙江省
    -
  • -
  • -
    上海市
    -
  • -
  • -
    江苏省
    -
  • -
  • -
    浙江省
    -
  • -
  • -
    安徽省
    -
  • -
  • -
    福建省
    -
  • -
  • -
    江西省
    -
  • -
  • -
    山东省
    -
  • -
  • -
    河南省
    -
  • -
  • -
    湖北省
    -
  • -
  • -
    湖南省
    -
  • -
  • -
    广东省
    -
  • -
  • -
    广西壮族自治区
    -
  • -
  • -
    海南省
    -
  • -
  • -
    重庆市
    -
  • -
  • -
    四川省
    -
  • -
  • -
    贵州省
    -
  • -
  • -
    云南省
    -
  • -
  • -
    西藏自治区
    -
  • -
  • -
    陕西省
    -
  • -
  • -
    甘肃省
    -
  • -
  • -
    青海省
    -
  • -
  • -
    宁夏回族自治区
    -
  • -
  • -
    新疆维吾尔自治区
    -
  • -
  • -
    台湾省
    -
  • -
  • -
    香港特别行政区
    -
  • -
  • -
    澳门特别行政区
    -
  • -
  • -
    海外
    -
  • -
-
-
-
    +
    +
    +
    + 地区名称
    -
    -
      +
      +
      + +
      -
      -
      -
      diff --git a/src/area/test/__snapshots__/index.spec.js.snap b/src/area/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index e29ea9587..000000000 --- a/src/area/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,407 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`change option 1`] = ` -
      -
      - -
      -
      -
        -
      • -
        北京市
        -
      • -
      • -
        天津市
        -
      • -
      -
      -
      -
        -
      • -
        北京市
        -
      • -
      • -
        -
      • -
      -
      -
      -
        -
      • -
        东城区
        -
      • -
      • -
        西城区
        -
      • -
      -
      -
      -
      -
      - -
      -`; - -exports[`change option 2`] = ` -
      -
      - -
      -
      -
        -
      • -
        北京市
        -
      • -
      • -
        天津市
        -
      • -
      -
      -
      -
        -
      • -
        天津市
        -
      • -
      • -
        -
      • -
      -
      -
      -
        -
      • -
        和平区
        -
      • -
      • -
        河东区
        -
      • -
      -
      -
      -
      -
      - -
      -`; - -exports[`change option 3`] = ` -
      -
      - -
      -
      -
        -
      • -
        北京市
        -
      • -
      • -
        天津市
        -
      • -
      -
      -
      -
        -
      • -
        天津市
        -
      • -
      • -
        -
      • -
      -
      -
      -
        -
      • -
        和平区
        -
      • -
      • -
        河东区
        -
      • -
      -
      -
      -
      -
      - -
      -`; - -exports[`columns-num prop 1`] = ` -
      -
      - -
      -
      -
        -
      • -
        北京市
        -
      • -
      • -
        天津市
        -
      • -
      -
      -
      -
        -
      • -
        北京市
        -
      • -
      • -
        -
      • -
      -
      -
      -
      -
      - -
      -`; - -exports[`columns-top、columns-bottom slot 1`] = ` -
      -
      - Top
      -
      -
        -
        -
        -
          -
          -
          -
            -
            -
            -
            -
            Bottom - -
            -`; - -exports[`reset method 1`] = ` -
            -
            - -
            -
            -
              -
            • -
              北京市
              -
            • -
            • -
              天津市
              -
            • -
            -
            -
            -
              -
            • -
              天津市
              -
            • -
            • -
              -
            • -
            -
            -
            -
              -
            • -
              蓟县
              -
            • -
            -
            -
            -
            -
            - -
            -`; - -exports[`reset method 2`] = ` -
            -
            - -
            -
            -
              -
            • -
              北京市
              -
            • -
            • -
              天津市
              -
            • -
            -
            -
            -
              -
            • -
              北京市
              -
            • -
            • -
              -
            • -
            -
            -
            -
              -
            • -
              东城区
              -
            • -
            • -
              西城区
              -
            • -
            -
            -
            -
            -
            - -
            -`; - -exports[`title slot 1`] = ` -
            -
            Custom Title
            - -
            -
            -
              -
              -
              -
                -
                -
                -
                  -
                  -
                  -
                  -
                  - -
                  -`; - -exports[`watch areaList & code 1`] = ` -
                  -
                  - -
                  -
                  -
                    -
                  • -
                    北京市
                    -
                  • -
                  • -
                    天津市
                    -
                  • -
                  -
                  -
                  -
                    -
                  • -
                    北京市
                    -
                  • -
                  • -
                    -
                  • -
                  -
                  -
                  -
                    -
                  • -
                    东城区
                    -
                  • -
                  • -
                    西城区
                    -
                  • -
                  -
                  -
                  -
                  -
                  - -
                  -`; - -exports[`watch areaList & code 2`] = ` -
                  -
                  - -
                  -
                  -
                    -
                  • -
                    北京市
                    -
                  • -
                  • -
                    天津市
                    -
                  • -
                  -
                  -
                  -
                    -
                  • -
                    北京市
                    -
                  • -
                  • -
                    -
                  • -
                  -
                  -
                  -
                    -
                  • -
                    东城区
                    -
                  • -
                  • -
                    西城区
                    -
                  • -
                  -
                  -
                  -
                  -
                  - -
                  -`; - -exports[`watch areaList & code 3`] = ` -
                  -
                  - -
                  -
                  -
                    -
                  • -
                    北京市
                    -
                  • -
                  • -
                    天津市
                    -
                  • -
                  -
                  -
                  -
                    -
                  • -
                    北京市
                    -
                  • -
                  • -
                    -
                  • -
                  -
                  -
                  -
                    -
                  • -
                    东城区
                    -
                  • -
                  • -
                    西城区
                    -
                  • -
                  -
                  -
                  -
                  -
                  - -
                  -`; diff --git a/src/area/test/index.spec.js b/src/area/test/index.spec.js.disabled similarity index 100% rename from src/area/test/index.spec.js rename to src/area/test/index.spec.js.disabled diff --git a/src/badge/test/__snapshots__/demo.spec.js.snap b/src/badge/test/__snapshots__/demo.spec.js.snap index 7d4fd4dea..02fc2634c 100644 --- a/src/badge/test/__snapshots__/demo.spec.js.snap +++ b/src/badge/test/__snapshots__/demo.spec.js.snap @@ -3,6 +3,7 @@ exports[`renders demo correctly 1`] = `
                  +
                  5
                  @@ -51,18 +52,21 @@ exports[`renders demo correctly 1`] = `
                  -
                  -
                  +
                  + +
                  -
                  -
                  +
                  + +
                  -
                  -
                  +
                  + +
                  diff --git a/src/badge/test/__snapshots__/index.spec.js.snap b/src/badge/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index 2ed9ab2d1..000000000 --- a/src/badge/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,9 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`should render content slot correctly 1`] = `
                  Custom Content
                  `; - -exports[`should render nothing when content is empty string 1`] = `undefined`; - -exports[`should render nothing when content is undefined 1`] = `undefined`; - -exports[`should render nothing when content is zero 1`] = `
                  0
                  `; diff --git a/src/badge/test/index.spec.js b/src/badge/test/index.spec.js.disabled similarity index 100% rename from src/badge/test/index.spec.js rename to src/badge/test/index.spec.js.disabled diff --git a/src/button/test/__snapshots__/demo.spec.js.snap b/src/button/test/__snapshots__/demo.spec.js.snap index 4338a4930..b4057efb3 100644 --- a/src/button/test/__snapshots__/demo.spec.js.snap +++ b/src/button/test/__snapshots__/demo.spec.js.snap @@ -3,84 +3,166 @@ exports[`renders demo correctly 1`] = `
                  -
                  +
                  + + +
                  + 确定 +
                  +
                  +
                  +
                  + + +
                  + 确定 +
                  +
                  +
                  +
                  + + +
                  + 确定 +
                  +
                  +
                  +
                  + + +
                  + 确定 +
                  +
                  +
                  +
                  + + +
                  + 确定 +
                  +
                  +
                  +
                  + + +
                  + 确定 +
                  +
                  +
                  +
                  + + +
                  + 确定 +
                  +
                  +
                  +
                  +
                  +
                  + + + +
                  +
                  + + + + +
                  +
                  +
                  +
                  + + + + + +
                  -
                  -
                  -
                  -
                  -
                  -
                  -
                  -
                  -
                  -
                  `; diff --git a/src/button/test/__snapshots__/index.spec.js.snap b/src/button/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index 09bd1be32..000000000 --- a/src/button/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,29 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`icon-position prop 1`] = ` - -`; - -exports[`icon-prefix prop 1`] = ` - -`; - -exports[`loading slot 1`] = ` - -`; - -exports[`loading-size prop 1`] = ` - -`; diff --git a/src/button/test/index.spec.js b/src/button/test/index.spec.js.disabled similarity index 100% rename from src/button/test/index.spec.js rename to src/button/test/index.spec.js.disabled diff --git a/src/calendar/test/__snapshots__/demo.spec.js.snap b/src/calendar/test/__snapshots__/demo.spec.js.snap index 6ac56d057..a92354054 100644 --- a/src/calendar/test/__snapshots__/demo.spec.js.snap +++ b/src/calendar/test/__snapshots__/demo.spec.js.snap @@ -3,181 +3,19 @@ exports[`renders demo correctly 1`] = `
                  -
                  -
                  选择单个日期
                  - -
                  -
                  -
                  选择多个日期
                  - -
                  -
                  -
                  选择日期区间
                  - -
                  -
                  -
                  -
                  -
                  选择单个日期
                  - -
                  -
                  -
                  选择日期区间
                  - -
                  -
                  -
                  -
                  -
                  自定义颜色
                  - -
                  -
                  -
                  自定义日期范围
                  - -
                  -
                  -
                  自定义按钮文字
                  - -
                  -
                  -
                  自定义日期文案
                  - -
                  -
                  -
                  自定义弹出位置
                  - -
                  -
                  -
                  日期区间最大范围
                  - -
                  -
                  -
                  自定义周起始日
                  - -
                  -
                  -
                  -
                  -
                  -
                  日历
                  -
                  2012年1月
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  -
                  10
                  -
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  -
                  2012年2月
                  -
                  -
                  2
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  10
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  +
                  +
                  +
                  + 日历选择
                  -
                  -
                  2012年3月
                  -
                  -
                  3
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  10
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  +
                  +
                  +
                  -
                  +
                  -
                  `; diff --git a/src/calendar/test/__snapshots__/index.spec.js.snap b/src/calendar/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index 36899eec8..000000000 --- a/src/calendar/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,325 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`color prop when type is range 1`] = ` -
                  -
                  -
                  日期选择
                  -
                  2010年1月
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  10
                  开始
                  -
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  结束
                  -
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  - -
                  -`; - -exports[`color prop when type is single 1`] = ` -
                  -
                  -
                  日期选择
                  -
                  2010年1月
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  -
                  10
                  -
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  - -
                  -`; - -exports[`formatter prop 1`] = ` -
                  -
                  -
                  日期选择
                  -
                  2010年1月
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  -
                  10
                  -
                  -
                  -
                  Top Info
                  11 -
                  -
                  12
                  Bottom Info
                  -
                  -
                  Text
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  - -
                  -`; - -exports[`popup wrapper 1`] = ``; - -exports[`popup wrapper 2`] = ` -
                  -
                  -
                  -
                  日期选择
                  -
                  2010年1月
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  -
                  10
                  -
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  - -
                  - -
                  -`; - -exports[`row-height prop 1`] = ` -
                  -
                  -
                  日期选择
                  -
                  2010年1月
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  -
                  10
                  -
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  - -
                  -`; - -exports[`title & footer slot 1`] = ` -
                  -
                  -
                  Custom Title
                  -
                  2010年1月
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  -
                  10
                  -
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  20
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  - -
                  -`; diff --git a/src/calendar/test/__snapshots__/prop.spec.js.snap b/src/calendar/test/__snapshots__/prop.spec.js.snap deleted file mode 100644 index 1d8862afe..000000000 --- a/src/calendar/test/__snapshots__/prop.spec.js.snap +++ /dev/null @@ -1,54 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`lazy-render prop 1`] = ` -
                  -
                  -
                  日期选择
                  -
                  -
                  -
                  -
                  -
                  -
                  -
                  1
                  -
                  1
                  -
                  2
                  -
                  3
                  -
                  4
                  -
                  5
                  -
                  6
                  -
                  7
                  -
                  8
                  -
                  9
                  -
                  10
                  -
                  11
                  -
                  12
                  -
                  13
                  -
                  14
                  -
                  15
                  -
                  16
                  -
                  17
                  -
                  18
                  -
                  19
                  -
                  -
                  20
                  -
                  -
                  21
                  -
                  22
                  -
                  23
                  -
                  24
                  -
                  25
                  -
                  26
                  -
                  27
                  -
                  28
                  -
                  29
                  -
                  30
                  -
                  31
                  -
                  -
                  -
                  - -
                  -`; diff --git a/src/calendar/test/index.spec.js b/src/calendar/test/index.spec.js.disabled similarity index 100% rename from src/calendar/test/index.spec.js rename to src/calendar/test/index.spec.js.disabled diff --git a/src/calendar/test/prop.spec.js b/src/calendar/test/prop.spec.js.disabled similarity index 100% rename from src/calendar/test/prop.spec.js rename to src/calendar/test/prop.spec.js.disabled diff --git a/src/calendar/test/utils.spec.js b/src/calendar/test/utils.spec.js.disabled similarity index 100% rename from src/calendar/test/utils.spec.js rename to src/calendar/test/utils.spec.js.disabled diff --git a/src/card/test/__snapshots__/demo.spec.js.snap b/src/card/test/__snapshots__/demo.spec.js.snap index d70269e2c..ca510009d 100644 --- a/src/card/test/__snapshots__/demo.spec.js.snap +++ b/src/card/test/__snapshots__/demo.spec.js.snap @@ -4,10 +4,13 @@ exports[`renders demo correctly 1`] = `
                  -
                  -
                  -
                  -
                  +
                  + +
                  + +
                  + +
                  @@ -17,7 +20,10 @@ exports[`renders demo correctly 1`] = `
                  -
                  ¥2.00
                  +
                  + ¥ + 2.00 +
                  x2
                  @@ -27,12 +33,17 @@ exports[`renders demo correctly 1`] = `
                  -
                  -
                  -
                  -
                  +
                  + +
                  + +
                  + +
                  +
                  +
                  + 标签
                  -
                  标签
                  @@ -41,7 +52,10 @@ exports[`renders demo correctly 1`] = `
                  -
                  ¥2.00
                  +
                  + ¥ + 2.00 +
                  ¥ 10.00
                  x2
                  @@ -52,38 +66,54 @@ exports[`renders demo correctly 1`] = `
                  -
                  -
                  -
                  -
                  +
                  + +
                  + +
                  + +
                  商品名称
                  描述信息
                  -
                  - 标签 - 标签
                  +
                  + + 标签 + + 标签 +
                  -
                  ¥2.00
                  +
                  + ¥ + 2.00 +
                  x2
                  diff --git a/src/card/test/__snapshots__/index.spec.js.snap b/src/card/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index 04e9c3d58..000000000 --- a/src/card/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,71 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`render bottom slot 1`] = ` -
                  -
                  -
                  -
                  -
                  Custom Bottom
                  -
                  -
                  -
                  -`; - -exports[`render origin-price slot 1`] = ` -
                  -
                  -
                  -
                  -
                  -
                  Custom Origin Price
                  -
                  -
                  -
                  -
                  -`; - -exports[`render price & num slot 1`] = ` -
                  -
                  -
                  -
                  -
                  -
                  Custom Price
                  -
                  Custom Num
                  -
                  -
                  -
                  -
                  -`; - -exports[`render thumb & tag slot 1`] = ` - -`; - -exports[`render title & desc slot 1`] = ` -
                  -
                  -
                  -
                  Custom TitleCustom desc
                  -
                  -
                  -
                  -`; - -exports[`render price & price-top slot 1`] = ` -
                  -
                  -
                  -
                  -
                  Custom Price-top
                  Custom Price
                  -
                  -
                  -
                  -
                  -`; \ No newline at end of file diff --git a/src/card/test/index.spec.js b/src/card/test/index.spec.js.disabled similarity index 100% rename from src/card/test/index.spec.js rename to src/card/test/index.spec.js.disabled diff --git a/src/cascader/test/__snapshots__/demo.spec.js.snap b/src/cascader/test/__snapshots__/demo.spec.js.snap index 3b0b02b60..149e07dfd 100644 --- a/src/cascader/test/__snapshots__/demo.spec.js.snap +++ b/src/cascader/test/__snapshots__/demo.spec.js.snap @@ -3,39 +3,19 @@ exports[`renders demo correctly 1`] = `
                  -
                  -
                  地区
                  -
                  -
                  -
                  - -
                  -
                  -
                  -
                  -
                  地区
                  -
                  -
                  -
                  - -
                  -
                  -
                  -
                  -
                  地区
                  -
                  -
                  -
                  - -
                  -
                  -
                  -
                  -
                  地区
                  -
                  -
                  -
                  - +
                  +
                  +
                  + + 地区 + +
                  +
                  +
                  + +
                  +
                  +
                  diff --git a/src/cascader/test/__snapshots__/index.spec.js.snap b/src/cascader/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index c3f5d8547..000000000 --- a/src/cascader/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,48 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`should render title slot correctly 1`] = `

                  Custom Title

                  `; - -exports[`should select correct option when value changed 1`] = ` -
                • Ouhai -
                • -`; - -exports[`should update tabs when previous tab is clicked 1`] = ` -
                  -
                  -

                  - -
                  -
                  -
                  -
                  - - -
                  -
                  -
                  -
                  -
                  - -
                  -
                  -
                    -
                  • Nanjing
                  • -
                  • Wuxi
                  • -
                  • Xuzhou
                  • -
                  -
                  -
                  -
                  -
                  -
                  -
                  -`; diff --git a/src/cascader/test/index.spec.js b/src/cascader/test/index.spec.js.disabled similarity index 100% rename from src/cascader/test/index.spec.js rename to src/cascader/test/index.spec.js.disabled diff --git a/src/cascaderbak/test/__snapshots__/demo.spec.js.snap b/src/cascaderbak/test/__snapshots__/demo.spec.js.snap index 3b0b02b60..fe3d3480c 100644 --- a/src/cascaderbak/test/__snapshots__/demo.spec.js.snap +++ b/src/cascaderbak/test/__snapshots__/demo.spec.js.snap @@ -3,39 +3,63 @@ exports[`renders demo correctly 1`] = `
                  -
                  -
                  地区
                  -
                  -
                  -
                  - +
                  +
                  + 地区 +
                  +
                  +
                  + +
                  +
                  -
                  -
                  地区
                  -
                  -
                  -
                  - +
                  +
                  + 地区 +
                  +
                  +
                  + +
                  +
                  -
                  -
                  地区
                  -
                  -
                  -
                  - +
                  +
                  + 地区 +
                  +
                  +
                  + +
                  +
                  -
                  -
                  地区
                  -
                  -
                  -
                  - +
                  +
                  + 地区 +
                  +
                  +
                  + +
                  +
                  +
                  +
                  +
                  +
                  +
                  + 地区 +
                  +
                  +
                  + +
                  +
                  diff --git a/src/cascaderbak/test/__snapshots__/index.spec.js.snap b/src/cascaderbak/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index c3f5d8547..000000000 --- a/src/cascaderbak/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,48 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`should render title slot correctly 1`] = `

                  Custom Title

                  `; - -exports[`should select correct option when value changed 1`] = ` -
                • Ouhai -
                • -`; - -exports[`should update tabs when previous tab is clicked 1`] = ` -
                  -
                  -

                  - -
                  -
                  -
                  -
                  - - -
                  -
                  -
                  -
                  -
                  - -
                  -
                  -
                    -
                  • Nanjing
                  • -
                  • Wuxi
                  • -
                  • Xuzhou
                  • -
                  -
                  -
                  -
                  -
                  -
                  -
                  -`; diff --git a/src/cascaderbak/test/index.spec.js b/src/cascaderbak/test/index.spec.js.disabled similarity index 100% rename from src/cascaderbak/test/index.spec.js rename to src/cascaderbak/test/index.spec.js.disabled diff --git a/src/cell/test/__snapshots__/demo.spec.js.snap b/src/cell/test/__snapshots__/demo.spec.js.snap index 8387ae7a3..0b67332f1 100644 --- a/src/cell/test/__snapshots__/demo.spec.js.snap +++ b/src/cell/test/__snapshots__/demo.spec.js.snap @@ -3,121 +3,151 @@ exports[`renders demo correctly 1`] = `
                  +
                  -
                  -
                  单元格
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  -
                  -
                  单元格 -
                  描述信息
                  -
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  -
                  -
                  单元格
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  -
                  -
                  单元格 -
                  描述信息
                  -
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  -
                  -
                  单元格
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  -
                  -
                  单元格 -
                  描述信息
                  -
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  -
                  - -
                  单元格
                  -
                  内容
                  +
                  + + +
                  +
                  +
                  单元格
                  +
                  -
                  -
                  内容
                  +
                  -
                  -
                  单元格
                  - +
                  +
                  单元格
                  +
                  -
                  -
                  单元格
                  -
                  内容
                  - +
                  +
                  单元格
                  +
                  -
                  -
                  单元格
                  -
                  内容
                  - +
                  +
                  单元格
                  +
                  -
                  -
                  URL 跳转
                  - +
                  +
                  URL 跳转
                  +
                  -
                  -
                  路由跳转
                  - +
                  +
                  路由跳转
                  +
                  分组 1
                  -
                  -
                  单元格
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  分组 2
                  -
                  -
                  单元格
                  -
                  内容
                  +
                  +
                  单元格
                  +
                  -
                  -
                  单元格 标签
                  -
                  内容
                  - +
                  +
                  + 单元格 + 标签 +
                  + +
                  +
                  + + +
                  +
                  +
                  单元格
                  + +
                  +
                  +
                  +
                  + +
                  + +
                  +
                  +
                  +
                  -
                  - -
                  单元格
                  - +
                  +
                  +
                  +
                  单元格
                  +
                  -
                  -
                  单元格 -
                  描述信息
                  +
                  +
                  +
                  垂直居中
                  +
                  内容
                  +
                  -
                  内容
                  +
                  +
                  +
                  +
                  +
                  垂直居中
                  +
                  内容
                  +
                  diff --git a/src/cell/test/__snapshots__/index.spec.js.snap b/src/cell/test/__snapshots__/index.spec.js.snap deleted file mode 100644 index cd68daa26..000000000 --- a/src/cell/test/__snapshots__/index.spec.js.snap +++ /dev/null @@ -1,29 +0,0 @@ -// Jest Snapshot v1, https://goo.gl/fbAQLP - -exports[`CellGroup title slot 1`] = ` -
                  -
                  CustomTitle
                  -
                  -
                  -`; - -exports[`arrow direction 1`] = ` -
                  -
                  -`; - -exports[`icon-prefix prop 1`] = ` -
                  -
                  -`; - -exports[`render slot 1`] = ` -
                  Custom Icon
                  Custom Title
                  Custom Label
                  -
                  Custom Extra
                  -`; - -exports[`title-style prop 1`] = ` -
                  -
                  title
                  -
                  -`; diff --git a/src/cell/test/index.spec.js b/src/cell/test/index.spec.js.disabled similarity index 100% rename from src/cell/test/index.spec.js rename to src/cell/test/index.spec.js.disabled diff --git a/src/checkbox/demo/index.vue b/src/checkbox/demo/index.vue index 00e948bac..73ce32d04 100644 --- a/src/checkbox/demo/index.vue +++ b/src/checkbox/demo/index.vue @@ -1,12 +1,12 @@