CLI: strange logging in execute tests
Nobody has claimed this yet.
- Dominant language
- TypeScript
- Stars
- 21
- Forks
- 23
- Avg merge
- 1d 22h
- Merged PRs (30d)
- 17
Description
This is a reminder to look into some strange logging issues in the cli/test/execute/excecute.test.ts
// TODO if I pass a mock logger into the handler, the handler then
// goes and creates a real logger and passes it to the runtinme, which
// causes all sorts of logging
// Why isn't that affecting other tests?
// Why do I need this special handling here?
I also notice that even though logger.error is being called, the logger doesn't seem to register it. Certainly mockLogger._find isn't finding it. This might be a json logger thing?
Contributor guide
No contributing guide indexed for this repository
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Research direction
Start by running the tests in cli/test/execute/excecute.test.ts and read the TODO about the mock logger, handler, runtime, and JSON logger. Trace why a real logger is created and why mockLogger._find does not see logger.error. Done means the execute tests have predictable logging and can assert the error call without unwanted real logging.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- typescript
- Domain
- cli, testing-qa
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Needs clarification
- Newbie friendliness
- 35/100