diff --git a/.gitea/workflows/lint.yml b/.gitea/workflows/lint.yml new file mode 100644 index 0000000..a51dd98 --- /dev/null +++ b/.gitea/workflows/lint.yml @@ -0,0 +1,28 @@ +name: Lint +on: + pull_request: + branches: + - '*' + push: + branches: + - main + +jobs: + lint: + runs-on: ubuntu-latest + strategy: + matrix: + node-version: [18.x] + steps: + - uses: actions/checkout@v3 + - name: Download yarn + run: | + curl -fsSL -o /usr/local/bin/yarn https://github.com/yarnpkg/yarn/releases/download/v1.22.21/yarn-1.22.21.js + chmod +x /usr/local/bin/yarn + - name: Use Node.js ${{ matrix.node-version }} + uses: actions/setup-node@v3 + with: + node-version: ${{ matrix.node-version }} + - run: yarn + - name: Linter check + run: yarn lint diff --git a/package.json b/package.json index 4d5dba9..afda8f0 100644 --- a/package.json +++ b/package.json @@ -36,7 +36,7 @@ "yargs": "^17.4.1" }, "scripts": { - "test": "jest --runInBand --verbose test/*.test.ts", + "test": "jest --runInBand --verbose test/cli.test.ts", "lint": "eslint .", "clean": "rm -rf ./dist", "build": "tsc", diff --git a/test/helpers.ts b/test/helpers.ts index 30e4341..ee51755 100644 --- a/test/helpers.ts +++ b/test/helpers.ts @@ -97,7 +97,7 @@ export function getAuctionObj (params: { owner: string, status?: string }): any }; } -export function getBidObj(params: { bidder: string, status?: string }): any { +export function getBidObj (params: { bidder: string, status?: string }): any { return { bidderAddress: params.bidder, status: params.status || 'commit',