Not logged in.  Login/Logout/Register | List snippets | | Create snippet | Upload image | Upload data

5
LINES

< > BotCompany Repo | #1035391 // assertInnerExceptionOfType

JavaX fragment (include) [tags: use-pretranspiled]

Libraryless. Click here for Pure Java version (7944L/44K).

1  
static void nuLike assertInnerExceptionOfType(Class type, Runnable r) {
2  
  var e = assertFail(r);
3  
  if (!containsExceptionOfType(e, type))
4  
    fail("Exception " + e + " isn't of type " + type);
5  
}

Author comment

Began life as a copy of #1018505

download  show line numbers  debug dex  old transpilations   

Travelled to 2 computer(s): mowyntqkapby, mqqgnosmbjvj

No comments. add comment

Snippet ID: #1035391
Snippet name: assertInnerExceptionOfType
Eternal ID of this version: #1035391/1
Text MD5: e675c96bf4db423afc8619bed96ee324
Transpilation MD5: 6d59bde8bbc4d085015b8fe817ed39aa
Author: stefan
Category: javac
Type: JavaX fragment (include)
Public (visible to everyone): Yes
Archived (hidden from active list): No
Created/modified: 2022-05-05 16:44:06
Source code size: 198 bytes / 5 lines
Pitched / IR pitched: No / No
Views / Downloads: 119 / 172
Referenced in: [show references]