@react-foundry/fastify-dev-logger 0.1.9 → 0.2.0
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/jest.config.cjs +1 -1
- package/package.json +1 -1
- package/spec/index.js +2 -1
package/jest.config.cjs
CHANGED
package/package.json
CHANGED
package/spec/index.js
CHANGED
|
@@ -16,6 +16,7 @@ describe('fastifyDevLogger', () => {
|
|
|
16
16
|
write(chunk, _enc, cb) {
|
|
17
17
|
output.push(
|
|
18
18
|
stripColours(chunk.toString())
|
|
19
|
+
.replace(/^\r/, '')
|
|
19
20
|
.replace(/\n$/, '')
|
|
20
21
|
);
|
|
21
22
|
cb();
|
|
@@ -106,7 +107,7 @@ describe('fastifyDevLogger', () => {
|
|
|
106
107
|
it('outputs log level', () => expect(output[0]).toContain('info'));
|
|
107
108
|
it('outputs the time', () => expect(output[0]).toMatch(timeRegex));
|
|
108
109
|
it('outputs in the correct format', () => expect(output[0]).toMatch(new RegExp(
|
|
109
|
-
`^${timePattern} info \\(C3\\) \\| GET /path/to/resource - request completed; 200 OK \\(
|
|
110
|
+
`^${timePattern} info \\(C3\\) \\| GET /path/to/resource - request completed; 200 OK \\(1.07s\\)$`
|
|
110
111
|
)));
|
|
111
112
|
});
|
|
112
113
|
});
|