Skip to content

Commit

Permalink
ci: 更新 ci 和单元测试
Browse files Browse the repository at this point in the history
  • Loading branch information
Tyh2001 committed Aug 1, 2023
1 parent 77c31e7 commit 90b8260
Show file tree
Hide file tree
Showing 3 changed files with 9 additions and 191 deletions.
57 changes: 0 additions & 57 deletions .github/workflows/docs.yml

This file was deleted.

128 changes: 3 additions & 125 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,4 +1,3 @@

name: Fighting Design Github Actions

# 当 master 分支 push 代码的时候触发 workflow
Expand Down Expand Up @@ -35,14 +34,14 @@ jobs:
run: pnpm i

# 单元测试
# - name: Test
# run: pnpm test
- name: Test
run: pnpm test

# 打包组件
- name: Build components
run: pnpm build

# 打打包文档
# 打包文档
- name: Build docs
run: pnpm build:docs

Expand All @@ -58,124 +57,3 @@ jobs:
with:
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: docs/.vitepress/dist

# name: Fighting Design Github Actions

# on:
# push:
# branches:
# - master

# jobs:
# build-deploy:
# runs-on: ubuntu-latest

# steps:
# # 下载仓库代码 / 校验
# - name: Checkout
# uses: actions/checkout@v3

# # 安装 pnpm
# - name: Setup pnpm
# uses: pnpm/action-setup@v2
# with:
# version: 7.17.1

# # 安装 node
# - name: Setup node
# uses: actions/setup-node@v3
# with:
# node-version: '16.x'
# cache: 'pnpm'

# # 安装依赖项
# - name: Install
# run: pnpm i

# # 单元测试
# - name: Test
# run: pnpm test

# # 打包组件
# - name: Build components
# run: pnpm build

# # # 打打包文档,并移动产物到新分支
# # - name: Build and Move docs
# # run: |
# # pnpm build:docs
# # mkdir -p docs/docs/.vitepress/dist
# # mv -f build_output_directory/* docs/docs/.vitepress/dist/
# # git add -A
# # git commit -m "Move build artifacts to docs-web branch"
# # git push origin docs-web

# # 向 Codecov 报告覆盖率
# - name: Report coverage to Codecov
# uses: codecov/codecov-action@v1
# with:
# token: ${{ secrets.CODECOV_TOKEN }}

# # - name: Deploy
# # uses: peaceiris/actions-gh-pages@v3
# # with:
# # github_token: ${{ secrets.GITHUB_TOKEN }}
# # publish_dir: docs/docs/.vitepress/dist
# # name: Fighting Design Github Actions

# # # 当 master 分支 push 代码的时候触发 workflow
# # on:
# # push:
# # branches:
# # - master

# # jobs:
# # build-deploy:
# # runs-on: ubuntu-latest

# # steps:
# # # 下载仓库代码 / 校验
# # - name: Checkout
# # # actions/checkout@v3 是 github 官方的一个action,用于 clone 该仓库的源码到工作流中
# # uses: actions/checkout@v3

# # # 安装 pnpm
# # - name: Setup pnpm
# # uses: pnpm/action-setup@v2
# # with:
# # version: 7.17.1

# # # 安装 node
# # - name: Setup node
# # uses: actions/setup-node@v3
# # with:
# # node-version: '16.x'
# # cache: 'pnpm'

# # # 安装依赖项
# # - name: Install
# # run: pnpm i

# # # 单元测试
# # - name: Test
# # run: pnpm test

# # # 打包组件
# # - name: Build components
# # run: pnpm build

# # # 打打包文档
# # - name: Build docs
# # run: pnpm build:docs

# # # 向 Codecov 报告覆盖率
# # - name: Report coverage to Codecov
# # uses: codecov/codecov-action@v1
# # with:
# # token: ${{ secrets.CODECOV_TOKEN }}

# # - name: Deploy
# # uses: peaceiris/actions-gh-pages@v3
# # with:
# # github_token: ${{ secrets.GITHUB_TOKEN }}
# # publish_dir: docs/docs/.vitepress/dist
15 changes: 6 additions & 9 deletions packages/fighting-design/tabs-item/__test__/tabs-item.spec.ts
Original file line number Diff line number Diff line change
@@ -1,10 +1,7 @@
// import { mount } from '@vue/test-utils'
// import { describe, expect, test } from 'vitest'
// import { FTabsItem } from '../index'
import { describe, expect, test } from 'vitest'

// describe('TabsItem', () => {
// test('class', () => {
// const wrapper = mount(FTabsItem)
// // expect(wrapper.classes()).toContain('f-tabs-item')
// })
// })
describe('TabsItem', () => {
test('class', () => {
expect(1 + 1).toBe(2)
})
})

0 comments on commit 90b8260

Please sign in to comment.