diff --git a/build.gradle b/build.gradle index 7a71a6a5..211a2a74 100644 --- a/build.gradle +++ b/build.gradle @@ -27,7 +27,7 @@ dependencies { implementation 'org.apache.commons:commons-text:1.10.0' implementation 'org.apache.logging.log4j:log4j-core:2.19.0' - testCompileOnly files("${System.properties['user.home']}/BurpSuitePro/burpsuite_pro.jar") + testRuntimeOnly files("${System.properties['user.home']}/BurpSuitePro/burpsuite_pro.jar") } jar { diff --git a/src/test/java/Test.java b/src/test/java/Test.java index 998ff084..e2ec439c 100644 --- a/src/test/java/Test.java +++ b/src/test/java/Test.java @@ -1,5 +1,12 @@ +import java.lang.reflect.Method; + public class Test { public static void main(String[] args) { - burp.StartBurp.main(args); + try { + Method main = Class.forName("burp.StartBurp").getMethod("main", String[].class); + main.invoke(null, (Object) args); + }catch (Exception e){ + System.err.println("Cannot start burp. Check the burp jar is correctly included in the classpath."); + } } }