public class MethodRuleChain extends Object implements org.junit.rules.MethodRule
MethodRuleChain class provides a JUnit4 method rule that
allows ordering of other method rules.| Constructor and Description |
|---|
MethodRuleChain(List<org.junit.rules.MethodRule> rules)
Instantiates a new
MethodRuleChain object. |
| Modifier and Type | Method and Description |
|---|---|
org.junit.runners.model.Statement |
apply(org.junit.runners.model.Statement base,
org.junit.runners.model.FrameworkMethod method,
Object target) |
MethodRuleChain |
around(org.junit.rules.MethodRule enclosedRule)
Create a new
MethodRuleChain, which encloses the specified rule
with the rules of the current chain. |
static MethodRuleChain |
emptyChain()
Returns a
MethodRuleChain without a MethodRule. |
static MethodRuleChain |
outer(org.junit.rules.MethodRule outerRule)
Returns a
MethodRuleChain with a single MethodRule. |
public MethodRuleChain(List<org.junit.rules.MethodRule> rules)
MethodRuleChain object.rules - the non-null method rulespublic static MethodRuleChain emptyChain()
MethodRuleChain without a MethodRule. This
method may be the starting point of a chain.public static MethodRuleChain outer(org.junit.rules.MethodRule outerRule)
MethodRuleChain with a single MethodRule.
This method is the usual starting point of a chain.outerRule - the outer rule of the chainpublic MethodRuleChain around(org.junit.rules.MethodRule enclosedRule)
MethodRuleChain, which encloses the specified rule
with the rules of the current chain.enclosedRule - the rule to enclosepublic org.junit.runners.model.Statement apply(org.junit.runners.model.Statement base,
org.junit.runners.model.FrameworkMethod method,
Object target)
apply in interface org.junit.rules.MethodRuleMethodRule.apply(org.junit.runners.model.Statement, org.junit.runners.model.FrameworkMethod, java.lang.Object)Copyright (C) 2015-2017 The Helenus Driver Project Authors.