Skip to content

Commit

Permalink
chore: Updated dependencies.
Browse files Browse the repository at this point in the history
  • Loading branch information
ShogunPanda committed Nov 23, 2022
1 parent 929ddf4 commit 84401d2
Show file tree
Hide file tree
Showing 5 changed files with 17 additions and 17 deletions.
18 changes: 9 additions & 9 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -37,25 +37,25 @@
"postpublish": "git push origin && git push origin -f --tags"
},
"dependencies": {
"acquerello": "^1.0.11",
"acquerello": "^1.0.12",
"hdr-histogram-js": "^3.0.0",
"table": "^6.8.0"
"table": "^6.8.1"
},
"devDependencies": {
"@cowtech/eslint-config": "^8.7.5",
"@cowtech/eslint-config": "^8.8.0",
"@swc/cli": "^0.1.57",
"@swc/core": "^1.3.7",
"@types/node": "^18.8.4",
"@swc/core": "^1.3.19",
"@types/node": "^18.11.9",
"@types/sinon": "^10.0.13",
"@types/tap": "^15.0.7",
"c8": "^7.12.0",
"chokidar": "^3.5.3",
"prettier": "^2.7.1",
"prettier": "^2.8.0",
"proxyquire": "^2.1.3",
"sinon": "^14.0.1",
"tap": "^16.3.0",
"sinon": "^14.0.2",
"tap": "^16.3.2",
"ts-node": "^10.9.1",
"typescript": "^4.8.4"
"typescript": "^4.9.3"
},
"engines": {
"node": ">=14.15.0"
Expand Down
4 changes: 2 additions & 2 deletions src/models.ts
Original file line number Diff line number Diff line change
Expand Up @@ -64,7 +64,7 @@ export interface Context {
iterations: number
errorThreshold: number
print: boolean | PrintOptions
tests: Array<[string, TestFunction | Test]>
tests: [string, TestFunction | Test][]
results: Results
current: number
callback: Callback
Expand All @@ -75,7 +75,7 @@ export interface Context {

export interface WorkerContext {
path: string
tests: Array<[string, TestFunction | Test]>
tests: [string, TestFunction | Test][]
index: number
iterations: number
warmup: boolean
Expand Down
8 changes: 4 additions & 4 deletions src/print.ts
Original file line number Diff line number Diff line change
Expand Up @@ -14,9 +14,9 @@ interface PrintInfo {
compared: string
}

let currentLogger: (message: string, ...params: Array<any>) => void = console.log
let currentLogger: (message: string, ...params: any[]) => void = console.log

export function setLogger(logger: (message: string, ...params: Array<any>) => void): void {
export function setLogger(logger: (message: string, ...params: any[]) => void): void {
currentLogger = logger
}

Expand All @@ -28,7 +28,7 @@ export function printResults(results: Results, colors: boolean, compare: boolean
let compared = ''
let standardErrorPadding = 0

const entries: Array<PrintInfo> = Object.entries(results)
const entries: PrintInfo[] = Object.entries(results)
.sort((a, b) => (!a[1].success ? -1 : b[1].mean - a[1].mean))
.map(([name, result]) => {
if (!result.success) {
Expand Down Expand Up @@ -72,7 +72,7 @@ export function printResults(results: Results, colors: boolean, compare: boolean

let currentColor = 0

const rows: Array<Array<string>> = entries.map(entry => {
const rows: string[][] = entries.map(entry => {
if (entry.error) {
const row = [
styler(`{{gray}}${entry.name}{{-}}`),
Expand Down
2 changes: 1 addition & 1 deletion test/fixture/sample.ts
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ const subject =
cronometro(
{
single() {
subject.replace(pattern, m => replacements[m])
subject.replaceAll(pattern, m => replacements[m])
},
multiple() {
subject.replaceAll('1', 'a').replaceAll('2', 'b').replaceAll('3', 'c')
Expand Down
2 changes: 1 addition & 1 deletion test/print.test.ts
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ import { setLogger } from '../src/print.js'

function removeStyle(source: string): string {
// eslint-disable-next-line no-control-regex
return source.replace(/\u001B\[\d+m/g, '')
return source.replaceAll(/\u001B\[\d+m/g, '')
}

const loggerSpy = sinon.spy()
Expand Down

0 comments on commit 84401d2

Please sign in to comment.