Skip to content

There can be more than Notion and Miro. AFFiNE(pronounced [ə‘fain]) is a next-gen knowledge base that brings planning, sorting and creating all together. Privacy first, open-source, customizable and ready to use.

feat: upload code coverage report

DarkSky65652d0d06a0
diff --git a/.github/workflows/tests.yml b/.github/workflows/tests.yml
index 00ce55b51c..e288457c1c 100644
--- a/.github/workflows/tests.yml
+++ b/.github/workflows/tests.yml
@@ -33,8 +33,8 @@ jobs:
- name: Install Playwright browsers
run: npx playwright install chromium
- # - name: Run E2E tests
- # run: pnpm run test:e2e
+ - name: Run E2E tests
+ run: pnpm run test:coverage
# env:
# NEXT_PUBLIC_FIREBASE_API_KEY: ${{ secrets.NEXT_PUBLIC_FIREBASE_API_KEY }}
# NEXT_PUBLIC_FIREBASE_AUTH_DOMAIN: ${{ secrets.NEXT_PUBLIC_FIREBASE_AUTH_DOMAIN }}
@@ -44,5 +44,14 @@ jobs:
# NEXT_PUBLIC_FIREBASE_APP_ID: ${{ secrets.NEXT_PUBLIC_FIREBASE_APP_ID }}
# NEXT_PUBLIC_FIREBASE_MEASUREMENT_ID: ${{ secrets.NEXT_PUBLIC_FIREBASE_MEASUREMENT_ID }}
+ - name: Upload e2e test coverage results
+ uses: codecov/codecov-action@v3
+ with:
+ token: ${{ secrets.CODECOV_TOKEN }}
+ files: ./.coverage/lcov.info
+ flags: e2etest
+ name: affine
+ fail_ci_if_error: true
+
- name: Run Unit tests
run: pnpm run test:unit
diff --git a/.vscode/settings.json b/.vscode/settings.json
index 166b0206c0..6f191e6a9d 100644
--- a/.vscode/settings.json
+++ b/.vscode/settings.json
@@ -10,5 +10,11 @@
"pnpm",
"selfhosted",
"testid"
- ]
+ ],
+ "explorer.fileNesting.patterns": {
+ "*.js": "${capture}.js.map, ${capture}.min.js, ${capture}.d.ts, ${capture}.d.ts.map",
+ "package.json": ".browserslist*, .circleci*, .codecov, .commitlint*, .cz-config.js, .czrc, .dlint.json, .dprint.json, .editorconfig, .eslint*, .firebase*, .flowconfig, .github*, .gitlab*, .gitpod*, .huskyrc*, .jslint*, .lighthouserc.*, .lintstagedrc*, .markdownlint*, .mocha*, .node-version, .nodemon*, .npm*, .nvmrc, .pm2*, .pnp.*, .pnpm*, .prettier*, .releaserc*, .sentry*, .stackblitz*, .styleci*, .stylelint*, .tazerc*, .textlint*, .tool-versions, .travis*, .versionrc*, .vscode*, .watchman*, .xo-config*, .yamllint*, .yarnrc*, Procfile, api-extractor.json, apollo.config.*, appveyor*, ava.config.*, azure-pipelines*, bower.json, build.config.*, commitlint*, crowdin*, cypress.*, dangerfile*, dlint.json, dprint.json, firebase.json, grunt*, gulp*, histoire.config.*, jasmine.*, jenkins*, jest.config.*, jsconfig.*, karma*, lerna*, lighthouserc.*, lint-staged*, nest-cli.*, netlify*, nodemon*, nx.*, package-lock.json, package.nls*.json, phpcs.xml, playwright.config.*, pm2.*, pnpm*, prettier*, pullapprove*, puppeteer.config.*, pyrightconfig.json, release-tasks.sh, renovate*, rollup.config.*, stylelint*, tsconfig.*, tsdoc.*, tslint*, tsup.config.*, turbo*, typedoc*, unlighthouse*, vercel*, vetur.config.*, vitest.config.*, webpack*, workspace.json, xo.config.*, yarn*, babel.*, .babelrc, project.json",
+ "Cargo.toml": "Cargo.lock",
+ "README.md": "LICENSE, CHANGELOG.md, CODE_OF_CONDUCT.md, CONTRIBUTING.md"
+ }
}
diff --git a/package.json b/package.json
index 93cc6a1021..102f2fa4fc 100644
--- a/package.json
+++ b/package.json
@@ -15,8 +15,6 @@
"lint": "pnpm --filter @affine/app lint",
"test": "playwright test",
"test:coverage": "cross-env COVERAGE=true pnpm test && nyc report -t .nyc_output --report-dir .coverage --reporter=lcov",
- "test:dc": "pnpm --filter @affine/datacenter test",
- "test:e2e:codegen": "npx playwright codegen http://localhost:8080",
"test:unit": "playwright test --config=playwright.config.unit.ts",
"postinstall": "husky install",
"notify": "node --experimental-modules scripts/notify.mjs",