Use Class.getDeclaredConstructor().newInstance()
See gh-21913
This commit is contained in:
committed by
Andy Wilkinson
parent
fbfb7df3e1
commit
507eb9498b
@@ -1,5 +1,5 @@
|
||||
/*
|
||||
* Copyright 2012-2019 the original author or authors.
|
||||
* Copyright 2012-2020 the original author or authors.
|
||||
*
|
||||
* Licensed under the Apache License, Version 2.0 (the "License");
|
||||
* you may not use this file except in compliance with the License.
|
||||
@@ -28,7 +28,7 @@ public class SummaryGeneratingListener extends ReflectiveWrapper {
|
||||
|
||||
public SummaryGeneratingListener(ClassLoader classLoader) throws Throwable {
|
||||
super(classLoader, "org.junit.platform.launcher.listeners.SummaryGeneratingListener");
|
||||
this.instance = this.type.newInstance();
|
||||
this.instance = this.type.getDeclaredConstructor().newInstance();
|
||||
}
|
||||
|
||||
public TestExecutionSummary getSummary() throws Throwable {
|
||||
|
||||
Reference in New Issue
Block a user