Skip to content

Commit 8c61cc6

Browse files
committed
Modify test describe block
1 parent 2bce185 commit 8c61cc6

6 files changed

+10
-10
lines changed

test/lib-http-proxy-common-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@ import { setupOutgoing, setupSocket } from '../lib/common';
22
import { parse } from 'url';
33
import { describe, expect, it } from 'vitest';
44

5-
describe('lib/http-proxy/common.ts', () => {
5+
describe('lib/common.ts', () => {
66
describe('#setupOutgoing', () => {
77
it('should setup the correct headers', () => {
88
const outgoing = {};

test/lib-http-proxy-passes-web-incoming-test.js

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import { createServer, get, request } from 'http';
77
import { describe, expect, it } from 'vitest';
88
import { waitForClosed } from './util';
99

10-
describe('lib/http-proxy/passes/web-incoming.ts', () => {
10+
describe('lib/passes/web-incoming.ts', () => {
1111
describe('#deleteLength', () => {
1212
it('should change `content-length` for DELETE requests', () => {
1313
const stubRequest = {
@@ -159,7 +159,7 @@ describe('#createProxy.web() using own http server', () => {
159159
source.emit('request', req, res);
160160
}, 100);
161161
});
162-
})
162+
});
163163

164164
proxyServer.listen('8081');
165165
source.listen('8080');
@@ -184,7 +184,7 @@ describe('#createProxy.web() using own http server', () => {
184184
hasContinue = true;
185185
req.write(postData);
186186
req.end();
187-
})
187+
});
188188

189189
await waitForClosed(proxyServer, source);
190190

@@ -508,7 +508,7 @@ describe('#createProxy.web() using own http server', () => {
508508
});
509509

510510
it('should proxy requests to multiple servers with different options', async () => {
511-
const proxy = createProxy({target: 'http://ignored:8080'});
511+
const proxy = createProxy({ target: 'http://ignored:8080' });
512512

513513
// proxies to two servers depending on url, rewriting the url as well
514514
// http://127.0.0.1:8080/s1/ -> http://127.0.0.1:8081/

test/lib-http-proxy-passes-web-outgoing-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -7,7 +7,7 @@ import {
77
} from '../lib/passes/web-outgoing';
88
import { beforeEach, describe, expect, it } from 'vitest';
99

10-
describe('lib/http-proxy/passes/web-outgoing.ts', () => {
10+
describe('lib/passes/web-outgoing.ts', () => {
1111
let testContext;
1212

1313
beforeEach(() => {

test/lib-http-proxy-passes-ws-incoming-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,7 @@
11
import { checkMethodAndHeader, XHeaders } from '../lib/passes/ws-incoming';
22
import { describe, expect, it } from 'vitest';
33

4-
describe('lib/http-proxy/passes/ws-incoming.ts', () => {
4+
describe('lib/passes/ws-incoming.ts', () => {
55
describe('#checkMethodAndHeader', () => {
66
it('should drop non-GET connections', () => {
77
let destroyCalled = false,

test/lib-http-proxy-test.js

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -21,14 +21,14 @@ Object.defineProperty(gen, 'port', {
2121
},
2222
});
2323

24-
describe('lib/http-proxy.js', () => {
24+
describe('lib/index.js', () => {
2525
describe('#createProxy', () => {
2626
it('should not throw without options', function () {
2727
createProxy();
2828
});
2929
it('should throw with empty options', function () {
3030
createProxy({});
31-
})
31+
});
3232

3333
it('should return an object otherwise', () => {
3434
const obj = createProxy({

test/lib-https-proxy-test.js

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -18,7 +18,7 @@ Object.defineProperty(gen, 'port', {
1818
},
1919
});
2020

21-
describe('lib/http-proxy.js', () => {
21+
describe('lib/index.js', () => {
2222
describe('HTTPS #createProxy', () => {
2323
describe('HTTPS to HTTP', () => {
2424
it('should proxy the request en send back the response', async () => {

0 commit comments

Comments
 (0)