Closed jessebmiller closed 3 years ago
Hey! :wave: @jessebmiller
To make jest
tests work with ts-standard
, you can put that config in your package.json
:
{
"ts-standard": {
"envs": ["jest"]
}
}
That being said, /* eslint-env jest */
should work, if not, that's more related to eslint
than standard
or ts-standard
.
Does that solve your issue?
Please reopen if this issue persists, closing as for now.
Version: "^10.0.0"
Problem
In my jest tests, I'm getting
'test' is not defined.
and'expect' is not defined.
I'd like to allow those globals in my jest files in the same way I do using standardjs by adding
/* eslint-env jest */
or listing the globals in the file/* globals test expect */
rather than allowing those globals in all files.Solution
Implement the behavior of standardjs as described here and here
I'd be willing to work on this, but I'd need a lot of help understanding this repo and how standardjs handles this.