- 
        Couldn't load subscription status. 
- Fork 18
Open
Description
It seams that framwork doesn't provide any way to check that tested code throws exception of specific kind. I guess test code can use try/catch, do fail if rich the end of try and do assertions in the catch clause. However this seams clunky and won't give correct nice message in case of failure.
I think the syntax for exceptions could be: expect(MyException::class).thrownBy {...}
If thrownBy returns the exception following code can validate details about it (message, cause, etc.).
Alternative syntax may be expect {...}.throws(MyException::class).
Tzrlk
Metadata
Metadata
Assignees
Labels
No labels