Commit 3c580424 authored by Kelvin Fichter's avatar Kelvin Fichter

fix(ci): run tests for common-ts

Tests for common-ts were not being executed in CI because the command
being triggered was "yarn test:coverage" and this command was a noop for
common-ts. Also fixes a bug in the tests that wasn't caught by CI
because of this.
parent 3d915fa9
...@@ -518,6 +518,10 @@ jobs: ...@@ -518,6 +518,10 @@ jobs:
patterns: packages patterns: packages
# Note: The below needs to be manually configured whenever we # Note: The below needs to be manually configured whenever we
# add a new package to CI. # add a new package to CI.
- run:
name: Check common-ts
command: npx depcheck
working_directory: packages/common-ts
- run: - run:
name: Check contracts name: Check contracts
command: npx depcheck command: npx depcheck
......
ignores: [
"@babel/eslint-parser",
"@typescript-eslint/parser",
"eslint-plugin-import",
"eslint-plugin-unicorn",
"eslint-plugin-jsdoc",
"eslint-plugin-prefer-arrow",
"eslint-plugin-react",
"@typescript-eslint/eslint-plugin",
"eslint-config-prettier",
"eslint-plugin-prettier"
]
...@@ -17,7 +17,7 @@ ...@@ -17,7 +17,7 @@
"lint": "yarn lint:fix && yarn lint:check", "lint": "yarn lint:fix && yarn lint:check",
"pre-commit": "lint-staged", "pre-commit": "lint-staged",
"test": "ts-mocha test/*.spec.ts", "test": "ts-mocha test/*.spec.ts",
"test:coverage": "echo 'no coverage'" "test:coverage": "nyc ts-mocha test/*.spec.ts && nyc merge .nyc_output coverage.json"
}, },
"keywords": [ "keywords": [
"optimism", "optimism",
...@@ -48,8 +48,7 @@ ...@@ -48,8 +48,7 @@
"pino": "^6.11.3", "pino": "^6.11.3",
"pino-multi-stream": "^5.3.0", "pino-multi-stream": "^5.3.0",
"pino-sentry": "^0.7.0", "pino-sentry": "^0.7.0",
"prom-client": "^13.1.0", "prom-client": "^13.1.0"
"qs": "^6.10.5"
}, },
"devDependencies": { "devDependencies": {
"@ethersproject/abstract-provider": "^5.7.0", "@ethersproject/abstract-provider": "^5.7.0",
......
...@@ -3,11 +3,11 @@ import request from 'supertest' ...@@ -3,11 +3,11 @@ import request from 'supertest'
import chai = require('chai') import chai = require('chai')
const expect = chai.expect const expect = chai.expect
import { Logger, Metrics, createMetricsServer } from '../src' import { Logger, LegacyMetrics, createMetricsServer } from '../src'
describe('Metrics', () => { describe('Metrics', () => {
it('shoud serve metrics', async () => { it('shoud serve metrics', async () => {
const metrics = new Metrics({ const metrics = new LegacyMetrics({
prefix: 'test_metrics', prefix: 'test_metrics',
}) })
const registry = metrics.registry const registry = metrics.registry
......
...@@ -17871,13 +17871,6 @@ qs@^6.10.3, qs@^6.9.4: ...@@ -17871,13 +17871,6 @@ qs@^6.10.3, qs@^6.9.4:
dependencies: dependencies:
side-channel "^1.0.4" side-channel "^1.0.4"
qs@^6.10.5:
version "6.10.5"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.5.tgz#974715920a80ff6a262264acd2c7e6c2a53282b4"
integrity sha512-O5RlPh0VFtR78y79rgcgKK4wbAI0C5zGVLztOIdpWX6ep368q5Hv6XRxDvXuZ9q3C6v+e3n8UfZZJw7IIG27eQ==
dependencies:
side-channel "^1.0.4"
qs@^6.4.0, qs@^6.7.0: qs@^6.4.0, qs@^6.7.0:
version "6.10.1" version "6.10.1"
resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.1.tgz#4931482fa8d647a5aab799c5271d2133b981fb6a" resolved "https://registry.yarnpkg.com/qs/-/qs-6.10.1.tgz#4931482fa8d647a5aab799c5271d2133b981fb6a"
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment