From 820a68619272db29f9ccee790117bb49b08ebdb5 Mon Sep 17 00:00:00 2001 From: Volker Berlin Date: Wed, 1 Jan 2020 23:04:51 +0100 Subject: [PATCH] Unbox InvocationTargetException --- test/de/inetsoftware/jwebassembly/WasmRule.java | 7 +++++-- 1 file changed, 5 insertions(+), 2 deletions(-) diff --git a/test/de/inetsoftware/jwebassembly/WasmRule.java b/test/de/inetsoftware/jwebassembly/WasmRule.java index d9309c2..16b4d0e 100644 --- a/test/de/inetsoftware/jwebassembly/WasmRule.java +++ b/test/de/inetsoftware/jwebassembly/WasmRule.java @@ -1,5 +1,5 @@ /* - * Copyright 2017 - 2019 Volker Berlin (i-net software) + * Copyright 2017 - 2020 Volker Berlin (i-net software) * * Licensed under the Apache License, Version 2.0 (the "License"); * you may not use this file except in compliance with the License. @@ -26,6 +26,7 @@ import java.io.InputStream; import java.io.InputStreamReader; import java.io.OutputStreamWriter; import java.lang.ProcessBuilder.Redirect; +import java.lang.reflect.InvocationTargetException; import java.lang.reflect.Method; import java.net.URL; import java.nio.charset.StandardCharsets; @@ -394,10 +395,12 @@ public class WasmRule extends TemporaryFolder { actual = actualStr; } assertEquals( expected, actual ); + } catch( InvocationTargetException ex ) { + failed = true; + throwException( ex.getTargetException() ); } catch( Throwable ex ) { failed = true; throwException( ex ); - return; } }