最佳答案
The Jest docs do not demonstrate a way of asserting that no exception was thrown, only that one was.
expect(() => ...error...).toThrow(error)
How do I assert if one was not thrown?