Skip to content

Commit 8053d74

Browse files
committed
feat: align tag name with release version, added testcases
1 parent 203da05 commit 8053d74

16 files changed

Lines changed: 6367 additions & 1112 deletions

.github/workflows/node-build.yml

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -53,10 +53,10 @@ jobs:
5353
with:
5454
fetch-depth: 0
5555

56-
- name: Get version and create tag
56+
- name: Get version from package.json and check tag
5757
id: version
5858
run: |
59-
VERSION="0.1.$(date +%Y%m%d)-$(git rev-parse --short HEAD)"
59+
VERSION=$(jq -r .version package.json)
6060
echo "VERSION=${VERSION}" >> $GITHUB_OUTPUT
6161
echo "TAG_NAME=v${VERSION}" >> $GITHUB_OUTPUT
6262
if git tag -l "v${VERSION}" | grep -q "v${VERSION}"; then

jest.config.js

Lines changed: 24 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,24 @@
1+
/** @type {import('jest').Config} */
2+
module.exports = {
3+
preset: 'ts-jest',
4+
testEnvironment: 'node',
5+
roots: ['<rootDir>/src'],
6+
testMatch: ['**/__tests__/**/*.test.ts', '**/*.test.ts'],
7+
moduleNameMapper: {
8+
'^@/rapida/(.*)$': '<rootDir>/src/$1',
9+
},
10+
collectCoverageFrom: [
11+
'src/**/*.ts',
12+
'!src/**/*.d.ts',
13+
'!src/clients/protos/**',
14+
],
15+
coverageDirectory: 'coverage',
16+
coverageReporters: ['text', 'lcov', 'html'],
17+
verbose: true,
18+
testPathIgnorePatterns: ['/node_modules/', '/dist/'],
19+
transform: {
20+
'^.+\\.tsx?$': ['ts-jest', {
21+
tsconfig: 'tsconfig.json',
22+
}],
23+
},
24+
};

0 commit comments

Comments
 (0)