function objectContaining<T extends object>(expectedValue: T): T;
both these issues would be resolved, at the cost of complaining about partial objects, so bit of a tradeoff. Personally, I'd prefer to have typechecking in my tests and explicitly cast when required, rather than have everything mapped to any...
I'd be happy to do a PR if there was support for this idea... thoughts?
objectContaining is currently declared as:
Couple of drawbacks:
objectContaining
If the signature was changed to:
both these issues would be resolved, at the cost of complaining about partial objects, so bit of a tradeoff. Personally, I'd prefer to have typechecking in my tests and explicitly cast when required, rather than have everything mapped to any...
I'd be happy to do a PR if there was support for this idea... thoughts?