aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/junitparams/internal/InvokeNonParameterisedMethod.java
blob: a4256a29e85fd46b476a40fd7773375db2d3633c (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
package junitparams.internal;

import org.junit.runners.model.FrameworkMethod;
import org.junit.runners.model.Statement;

/**
 * JUnit invoker for non-parameterised test methods
 */
public class InvokeNonParameterisedMethod extends Statement {

    private final FrameworkMethod testMethod;
    private final Object testClass;

    InvokeNonParameterisedMethod(FrameworkMethod testMethod, Object testClass) {
        this.testMethod = testMethod;
        this.testClass = testClass;
    }

    @Override
    public void evaluate() throws Throwable {
        testMethod.invokeExplosively(testClass);
    }

}