Skip to content

Commit

Permalink
📦 Update dependency chai to v5 (#167)
Browse files Browse the repository at this point in the history
Co-authored-by: renovate[bot] <29139614+renovate[bot]@users.noreply.github.com>
Co-authored-by: Daniel Rozenberg <rodaniel@google.com>
  • Loading branch information
renovate[bot] and danielrozenberg authored Jan 2, 2024
1 parent 2dea9ee commit 3234e38
Show file tree
Hide file tree
Showing 4 changed files with 45 additions and 138 deletions.
165 changes: 37 additions & 128 deletions package-lock.json

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.

6 changes: 3 additions & 3 deletions package.json
Original file line number Diff line number Diff line change
Expand Up @@ -34,8 +34,7 @@
"@types/lodash.debounce": "4.0.9",
"@typescript-eslint/eslint-plugin": "6.17.0",
"@typescript-eslint/parser": "6.17.0",
"chai": "4.3.10",
"chai-http": "4.4.0",
"chai": "5.0.0",
"eslint": "8.56.0",
"eslint-config-prettier": "9.1.0",
"eslint-plugin-chai-expect": "3.0.0",
Expand All @@ -46,6 +45,7 @@
"nock": "13.4.0",
"prettier": "3.1.1",
"sinon": "17.0.1",
"source-map": "0.7.4"
"source-map": "0.7.4",
"superagent": "8.1.2"
}
}
5 changes: 1 addition & 4 deletions test/_init-tests.js
Original file line number Diff line number Diff line change
Expand Up @@ -16,12 +16,9 @@

process.env.NODE_ENV = 'test';

import chai from 'chai';
import chaihttp from 'chai-http';
import * as chai from 'chai';
import sinon from 'sinon';

chai.use(chaihttp);

global.chai = chai;
global.expect = chai.expect;
global.sinon = sinon;
7 changes: 4 additions & 3 deletions test/e2e/test-errortracker.js
Original file line number Diff line number Diff line change
Expand Up @@ -19,6 +19,7 @@ import { StatusCodes } from 'http-status-codes';

import app from '../../app.js';
import nock from 'nock';
import superagent from 'superagent';

describe('Error Tracker Server', () => {
const makeQuery = (function () {
Expand Down Expand Up @@ -64,9 +65,9 @@ describe('Error Tracker Server', () => {
function makePostRequest(type) {
return function (referrer, query) {
const q = makeQuery(query);
return chai
.request(server)
.post('/r')
return superagent
.post(`http://127.0.0.1:${server.address().port}/r`)
.ok(() => true)
.type(type)
.set('Referer', referrer)
.set('User-Agent', userAgent)
Expand Down

0 comments on commit 3234e38

Please sign in to comment.