forwardemail / forwardemail/supertest

Util.inspect Depth not deep enough

Open
#578 1 comment 0 reactions 0 assignees View on GitHub
Dominant language
JavaScript
Stars
14.4k
Forks
782
PR merge metrics
No merged PRs in 30d

Description

I was testing the response bodies of my API and came across the problem that the more deeply nested objects were not being parsed.

I would get the following,

```
{
id: 1,
title: 'Tech Lead',
createdAt: '2019-05-19T07:56:54.307Z',
updatedAt: '2019-05-19T07:56:54.307Z',
Attempts: [
{
id: 1,
status: 'Pending',
createdAt: '2019-05-19T07:56:54.307Z',
updatedAt: '2019-05-19T07:56:54.307Z',
UserId: 1,
InterviewId: 1,
User: [Object]
}
]
}
```

Note the `User: [Object]` which should be my full User object.

I've made changes to `util.inspect` so that all deeply nested objects will now show properly.
E.g, `util.inspect(body, { depth: null });`

See [PR](https://github.com/visionmedia/supertest/pull/577)

Contributor guide

Open the contributing guide

Assessment

This issue has not been assessed yet.

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.