A B C D E F G H I J L M N O P R S T V W _
所有类 所有程序包
所有类 所有程序包
所有类 所有程序包
A
- aClass(Class<?>) - 类 中的静态方法org.junit.runner.Request
- Create a
Request
that, when processed, will run all the tests in a class. - addChild(Description) - 类 中的方法org.junit.runner.Description
- Add
Description
as a child of the receiver. - addDimension(int) - 错误 中的方法org.junit.internal.ArrayComparisonFailure
- addError(Throwable) - 类 中的方法org.junit.rules.ErrorCollector
- Adds a Throwable to the table.
- addFirstListener(RunListener) - 类 中的方法org.junit.runner.notification.RunNotifier
- Internal use only.
- addListener(RunListener) - 类 中的方法org.junit.runner.JUnitCore
- Add a listener to be notified as the tests run.
- addListener(RunListener) - 类 中的方法org.junit.runner.notification.RunNotifier
- Internal use only
- addToAnnotationLists(T, Map<Class<? extends Annotation>, List<T>>) - 类 中的静态方法org.junit.runners.model.TestClass
- after() - 类 中的方法org.junit.rules.ExternalResource
- Override to tear down your specific external resource.
- after() - 类 中的方法org.junit.rules.TemporaryFolder
- After - org.junit中的注释类型
- If you allocate external resources in a
Before
method you need to release them after the test runs. - AfterClass - org.junit中的注释类型
- If you allocate expensive external resources in a
BeforeClass
method you need to release them after all the tests in the class have run. - ALL - 类 中的静态变量org.junit.runner.manipulation.Filter
- A null
Filter
that passes all tests through. - AllMembersSupplier - org.junit.experimental.theories.internal中的类
- Supplies Theory parameters based on all public members of the target class.
- AllMembersSupplier(TestClass) - 类 的构造器org.junit.experimental.theories.internal.AllMembersSupplier
- Constructs a new supplier for
type
- allOf(Iterable<Matcher<? super T>>) - 类 中的静态方法org.hamcrest.core.AllOf
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Iterable<Matcher<? super T>>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>...) - 类 中的静态方法org.hamcrest.core.AllOf
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>...) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AllOf
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AllOf
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AllOf
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AllOf
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AllOf
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- allOf(Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ALL of the specified matchers.
- AllOf<T> - org.hamcrest.core中的类
- Calculates the logical conjunction of multiple matchers.
- AllOf(Iterable<Matcher<? super T>>) - 类 的构造器org.hamcrest.core.AllOf
- AllTests - org.junit.runners中的类
- Runner for use with JUnit 3.8.x-style AllTests classes (those that only implement a static
suite()
method). - AllTests(Class<?>) - 类 的构造器org.junit.runners.AllTests
- Only called reflectively.
- allUnassigned(Method, TestClass) - 类 中的静态方法org.junit.experimental.theories.internal.Assignments
- Returns a new assignment list for
testMethod
, with no params assigned. - and(Condition.Step<? super T, U>) - 类 中的方法org.hamcrest.Condition
- and(Matcher<? super T>) - 类 中的方法org.hamcrest.core.CombinableMatcher
- and(Matcher<? super X>) - 类 中的方法org.hamcrest.core.CombinableMatcher.CombinableBothMatcher
- Annotatable - org.junit.runners.model中的接口
- A model element that may have annotations.
- AnnotationsValidator - org.junit.validator中的类
- An
AnnotationsValidator
validates all annotations of a test class, including its annotated fields and methods. - AnnotationsValidator() - 类 的构造器org.junit.validator.AnnotationsValidator
- AnnotationValidator - org.junit.validator中的类
- Validates annotations on classes and methods.
- AnnotationValidator() - 类 的构造器org.junit.validator.AnnotationValidator
- AnnotationValidatorFactory - org.junit.validator中的类
- Creates instances of Annotation Validators.
- AnnotationValidatorFactory() - 类 的构造器org.junit.validator.AnnotationValidatorFactory
- any(Class<T>) - 类 中的静态方法org.hamcrest.core.IsInstanceOf
- Creates a matcher that matches when the examined object is an instance of the specified
type
, as determined by calling theClass.isInstance(Object)
method on that type, passing the the examined object. - any(Class<T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches when the examined object is an instance of the specified
type
, as determined by calling theClass.isInstance(Object)
method on that type, passing the the examined object. - anyOf(Iterable<Matcher<? super T>>) - 类 中的静态方法org.hamcrest.core.AnyOf
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Iterable<Matcher<? super T>>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<? super T>...) - 类 中的静态方法org.hamcrest.core.AnyOf
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<? super T>...) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AnyOf
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AnyOf
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AnyOf
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AnyOf
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.AnyOf
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- anyOf(Matcher<T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>, Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if the examined object matches ANY of the specified matchers.
- AnyOf<T> - org.hamcrest.core中的类
- Calculates the logical disjunction of multiple matchers.
- AnyOf(Iterable<Matcher<? super T>>) - 类 的构造器org.hamcrest.core.AnyOf
- anything() - 类 中的静态方法org.hamcrest.core.IsAnything
- Creates a matcher that always matches, regardless of the examined object.
- anything() - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that always matches, regardless of the examined object.
- anything(String) - 类 中的静态方法org.hamcrest.core.IsAnything
- Creates a matcher that always matches, regardless of the examined object, but describes itself with the specified
String
. - anything(String) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that always matches, regardless of the examined object, but describes itself with the specified
String
. - append(char) - 类 中的方法org.hamcrest.BaseDescription
- Append the char c to the description.
- append(char) - 类 中的方法org.hamcrest.StringDescription
- append(String) - 类 中的方法org.hamcrest.BaseDescription
- Append the String str to the description.
- append(String) - 类 中的方法org.hamcrest.StringDescription
- appendDescriptionOf(SelfDescribing) - 类 中的方法org.hamcrest.BaseDescription
- appendDescriptionOf(SelfDescribing) - 接口 中的方法org.hamcrest.Description
- Appends the description of a
SelfDescribing
value to this description. - appendDescriptionOf(SelfDescribing) - 类 中的方法org.hamcrest.Description.NullDescription
- appendList(String, String, String, Iterable<? extends SelfDescribing>) - 类 中的方法org.hamcrest.BaseDescription
- appendList(String, String, String, Iterable<? extends SelfDescribing>) - 接口 中的方法org.hamcrest.Description
- Appends a list of
SelfDescribing
objects to the description. - appendList(String, String, String, Iterable<? extends SelfDescribing>) - 类 中的方法org.hamcrest.Description.NullDescription
- appendText(String) - 类 中的方法org.hamcrest.BaseDescription
- appendText(String) - 接口 中的方法org.hamcrest.Description
- Appends some plain text to the description.
- appendText(String) - 类 中的方法org.hamcrest.Description.NullDescription
- appendValue(Object) - 类 中的方法org.hamcrest.BaseDescription
- appendValue(Object) - 接口 中的方法org.hamcrest.Description
- Appends an arbitary value to the description.
- appendValue(Object) - 类 中的方法org.hamcrest.Description.NullDescription
- appendValueList(String, String, String, Iterable<T>) - 类 中的方法org.hamcrest.BaseDescription
- appendValueList(String, String, String, Iterable<T>) - 接口 中的方法org.hamcrest.Description
- Appends a list of values to the description.
- appendValueList(String, String, String, Iterable<T>) - 类 中的方法org.hamcrest.Description.NullDescription
- appendValueList(String, String, String, T...) - 类 中的方法org.hamcrest.BaseDescription
- appendValueList(String, String, String, T...) - 接口 中的方法org.hamcrest.Description
- Appends a list of values to the description.
- appendValueList(String, String, String, T...) - 类 中的方法org.hamcrest.Description.NullDescription
- apply(I, Description) - 接口 中的方法org.hamcrest.Condition.Step
- apply(Object) - 类 中的方法org.junit.runner.manipulation.Filter
- Invoke with a
Runner
to cause all tests it intends to run to first be checked with the filter. - apply(Object) - 类 中的方法org.junit.runner.manipulation.Sorter
- Sorts the test in
runner
usingcomparator
- apply(Statement, Description) - 类 中的方法org.junit.rules.DisableOnDebug
- apply(Statement, Description) - 类 中的方法org.junit.rules.ExpectedException
- apply(Statement, Description) - 类 中的方法org.junit.rules.ExternalResource
- apply(Statement, Description) - 类 中的方法org.junit.rules.RuleChain
- Modifies the method-running
Statement
to implement this test-running rule. - apply(Statement, Description) - 类 中的方法org.junit.rules.Stopwatch
- apply(Statement, Description) - 接口 中的方法org.junit.rules.TestRule
- Modifies the method-running
Statement
to implement this test-running rule. - apply(Statement, Description) - 类 中的方法org.junit.rules.TestWatcher
- apply(Statement, Description) - 类 中的方法org.junit.rules.Timeout
- apply(Statement, Description) - 类 中的方法org.junit.rules.Verifier
- apply(Statement, FrameworkMethod, Object) - 接口 中的方法org.junit.rules.MethodRule
- Modifies the method-running
Statement
to implement an additional test-running rule. - apply(Statement, FrameworkMethod, Object) - 类 中的方法org.junit.rules.TestWatchman
- 已过时。
- around(TestRule) - 类 中的方法org.junit.rules.RuleChain
- Create a new
RuleChain
, which encloses thenextRule
with the rules of the currentRuleChain
. - ArrayComparisonFailure - org.junit.internal中的错误
- Thrown when two array elements differ
- ArrayComparisonFailure(String, AssertionError, int) - 错误 的构造器org.junit.internal.ArrayComparisonFailure
- Construct a new
ArrayComparisonFailure
with an error text and the array's dimension that was not equal - arrayEquals(String, Object, Object) - 类 中的方法org.junit.internal.ComparisonCriteria
- Asserts that two arrays are equal, according to the criteria defined by the concrete subclass.
- ArrayIterator - org.hamcrest.internal中的类
- ArrayIterator(Object) - 类 的构造器org.hamcrest.internal.ArrayIterator
- Assert - org.junit中的类
- A set of assertion methods useful for writing tests.
- Assert() - 类 的构造器org.junit.Assert
- Protect constructor since it is a static only class
- assertArrayEquals(boolean[], boolean[]) - 类 中的静态方法org.junit.Assert
- Asserts that two boolean arrays are equal.
- assertArrayEquals(byte[], byte[]) - 类 中的静态方法org.junit.Assert
- Asserts that two byte arrays are equal.
- assertArrayEquals(char[], char[]) - 类 中的静态方法org.junit.Assert
- Asserts that two char arrays are equal.
- assertArrayEquals(double[], double[], double) - 类 中的静态方法org.junit.Assert
- Asserts that two double arrays are equal.
- assertArrayEquals(float[], float[], float) - 类 中的静态方法org.junit.Assert
- Asserts that two float arrays are equal.
- assertArrayEquals(int[], int[]) - 类 中的静态方法org.junit.Assert
- Asserts that two int arrays are equal.
- assertArrayEquals(long[], long[]) - 类 中的静态方法org.junit.Assert
- Asserts that two long arrays are equal.
- assertArrayEquals(short[], short[]) - 类 中的静态方法org.junit.Assert
- Asserts that two short arrays are equal.
- assertArrayEquals(Object[], Object[]) - 类 中的静态方法org.junit.Assert
- Asserts that two object arrays are equal.
- assertArrayEquals(String, boolean[], boolean[]) - 类 中的静态方法org.junit.Assert
- Asserts that two boolean arrays are equal.
- assertArrayEquals(String, byte[], byte[]) - 类 中的静态方法org.junit.Assert
- Asserts that two byte arrays are equal.
- assertArrayEquals(String, char[], char[]) - 类 中的静态方法org.junit.Assert
- Asserts that two char arrays are equal.
- assertArrayEquals(String, double[], double[], double) - 类 中的静态方法org.junit.Assert
- Asserts that two double arrays are equal.
- assertArrayEquals(String, float[], float[], float) - 类 中的静态方法org.junit.Assert
- Asserts that two float arrays are equal.
- assertArrayEquals(String, int[], int[]) - 类 中的静态方法org.junit.Assert
- Asserts that two int arrays are equal.
- assertArrayEquals(String, long[], long[]) - 类 中的静态方法org.junit.Assert
- Asserts that two long arrays are equal.
- assertArrayEquals(String, short[], short[]) - 类 中的静态方法org.junit.Assert
- Asserts that two short arrays are equal.
- assertArrayEquals(String, Object[], Object[]) - 类 中的静态方法org.junit.Assert
- Asserts that two object arrays are equal.
- assertElementsEqual(Object, Object) - 类 中的方法org.junit.internal.ComparisonCriteria
- assertElementsEqual(Object, Object) - 类 中的方法org.junit.internal.ExactComparisonCriteria
- assertElementsEqual(Object, Object) - 类 中的方法org.junit.internal.InexactComparisonCriteria
- assertEmpty(List<Throwable>) - 异常错误 中的静态方法org.junit.runners.model.MultipleFailureException
- Asserts that a list of throwables is empty.
- assertEquals(double, double) - 类 中的静态方法org.junit.Assert
- 已过时。Use
assertEquals(double expected, double actual, double delta)
instead - assertEquals(double, double, double) - 类 中的静态方法org.junit.Assert
- Asserts that two doubles are equal to within a positive delta.
- assertEquals(float, float, float) - 类 中的静态方法org.junit.Assert
- Asserts that two floats are equal to within a positive delta.
- assertEquals(long, long) - 类 中的静态方法org.junit.Assert
- Asserts that two longs are equal.
- assertEquals(Object[], Object[]) - 类 中的静态方法org.junit.Assert
- 已过时。use assertArrayEquals
- assertEquals(Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects are equal.
- assertEquals(String, double, double) - 类 中的静态方法org.junit.Assert
- 已过时。Use
assertEquals(String message, double expected, double actual, double delta)
instead - assertEquals(String, double, double, double) - 类 中的静态方法org.junit.Assert
- Asserts that two doubles are equal to within a positive delta.
- assertEquals(String, float, float, float) - 类 中的静态方法org.junit.Assert
- Asserts that two floats are equal to within a positive delta.
- assertEquals(String, long, long) - 类 中的静态方法org.junit.Assert
- Asserts that two longs are equal.
- assertEquals(String, Object[], Object[]) - 类 中的静态方法org.junit.Assert
- 已过时。use assertArrayEquals
- assertEquals(String, Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects are equal.
- assertFalse(boolean) - 类 中的静态方法org.junit.Assert
- Asserts that a condition is false.
- assertFalse(String, boolean) - 类 中的静态方法org.junit.Assert
- Asserts that a condition is false.
- assertNotEquals(double, double, double) - 类 中的静态方法org.junit.Assert
- Asserts that two doubles are not equal to within a positive delta.
- assertNotEquals(float, float, float) - 类 中的静态方法org.junit.Assert
- Asserts that two floats are not equal to within a positive delta.
- assertNotEquals(long, long) - 类 中的静态方法org.junit.Assert
- Asserts that two longs are not equals.
- assertNotEquals(Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects are not equals.
- assertNotEquals(String, double, double, double) - 类 中的静态方法org.junit.Assert
- Asserts that two doubles are not equal to within a positive delta.
- assertNotEquals(String, float, float, float) - 类 中的静态方法org.junit.Assert
- Asserts that two floats are not equal to within a positive delta.
- assertNotEquals(String, long, long) - 类 中的静态方法org.junit.Assert
- Asserts that two longs are not equals.
- assertNotEquals(String, Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects are not equals.
- assertNotNull(Object) - 类 中的静态方法org.junit.Assert
- Asserts that an object isn't null.
- assertNotNull(String, Object) - 类 中的静态方法org.junit.Assert
- Asserts that an object isn't null.
- assertNotSame(Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects do not refer to the same object.
- assertNotSame(String, Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects do not refer to the same object.
- assertNull(Object) - 类 中的静态方法org.junit.Assert
- Asserts that an object is null.
- assertNull(String, Object) - 类 中的静态方法org.junit.Assert
- Asserts that an object is null.
- assertSame(Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects refer to the same object.
- assertSame(String, Object, Object) - 类 中的静态方法org.junit.Assert
- Asserts that two objects refer to the same object.
- assertThat(String, boolean) - 类 中的静态方法org.hamcrest.MatcherAssert
- assertThat(String, T, Matcher<? super T>) - 类 中的静态方法org.hamcrest.MatcherAssert
- assertThat(String, T, Matcher<? super T>) - 类 中的静态方法org.junit.Assert
- Asserts that
actual
satisfies the condition specified bymatcher
. - assertThat(T, Matcher<? super T>) - 类 中的静态方法org.hamcrest.MatcherAssert
- assertThat(T, Matcher<? super T>) - 类 中的静态方法org.junit.Assert
- Asserts that
actual
satisfies the condition specified bymatcher
. - assertTrue(boolean) - 类 中的静态方法org.junit.Assert
- Asserts that a condition is true.
- assertTrue(String, boolean) - 类 中的静态方法org.junit.Assert
- Asserts that a condition is true.
- Assignments - org.junit.experimental.theories.internal中的类
- A potentially incomplete list of value assignments for a method's formal parameters
- assignNext(PotentialAssignment) - 类 中的方法org.junit.experimental.theories.internal.Assignments
- asString(SelfDescribing) - 类 中的静态方法org.hamcrest.StringDescription
- Alias for
StringDescription.toString(SelfDescribing)
. - Assume - org.junit中的类
- A set of methods useful for stating assumptions about the conditions in which a test is meaningful.
- Assume() - 类 的构造器org.junit.Assume
- assumeFalse(boolean) - 类 中的静态方法org.junit.Assume
- The inverse of
Assume.assumeTrue(boolean)
. - assumeFalse(String, boolean) - 类 中的静态方法org.junit.Assume
- The inverse of
Assume.assumeTrue(String, boolean)
. - assumeNoException(String, Throwable) - 类 中的静态方法org.junit.Assume
- Attempts to halt the test and ignore it if Throwable
e
is notnull
. - assumeNoException(Throwable) - 类 中的静态方法org.junit.Assume
- Use to assume that an operation completes normally.
- assumeNotNull(Object...) - 类 中的静态方法org.junit.Assume
- If called with one or more null elements in
objects
, the test will halt and be ignored. - assumeThat(String, T, Matcher<T>) - 类 中的静态方法org.junit.Assume
- Call to assume that
actual
satisfies the condition specified bymatcher
. - assumeThat(T, Matcher<T>) - 类 中的静态方法org.junit.Assume
- Call to assume that
actual
satisfies the condition specified bymatcher
. - assumeTrue(boolean) - 类 中的静态方法org.junit.Assume
- If called with an expression evaluating to
false
, the test will halt and be ignored. - assumeTrue(String, boolean) - 类 中的静态方法org.junit.Assume
- If called with an expression evaluating to
false
, the test will halt and be ignored. - AssumptionViolatedException - org.junit中的异常错误
- An exception class used to implement assumptions (state in which a given test is meaningful and should or should not be executed).
- AssumptionViolatedException - org.junit.internal中的异常错误
- An exception class used to implement assumptions (state in which a given test is meaningful and should or should not be executed).
- AssumptionViolatedException(Object, Matcher<?>) - 异常错误 的构造器org.junit.internal.AssumptionViolatedException
- 已过时。Please use
AssumptionViolatedException
instead. - AssumptionViolatedException(String) - 异常错误 的构造器org.junit.AssumptionViolatedException
- An assumption exception with the given message only.
- AssumptionViolatedException(String) - 异常错误 的构造器org.junit.internal.AssumptionViolatedException
- 已过时。Please use
AssumptionViolatedException
instead. - AssumptionViolatedException(String, boolean, Object, Matcher<?>) - 异常错误 的构造器org.junit.internal.AssumptionViolatedException
- 已过时。Please use
AssumptionViolatedException
instead. - AssumptionViolatedException(String, Object, Matcher<?>) - 异常错误 的构造器org.junit.internal.AssumptionViolatedException
- 已过时。Please use
AssumptionViolatedException
instead. - AssumptionViolatedException(String, Throwable) - 异常错误 的构造器org.junit.AssumptionViolatedException
- An assumption exception with the given message and a cause.
- AssumptionViolatedException(String, Throwable) - 异常错误 的构造器org.junit.internal.AssumptionViolatedException
- 已过时。Please use
AssumptionViolatedException
instead. - AssumptionViolatedException(String, T, Matcher<T>) - 异常错误 的构造器org.junit.AssumptionViolatedException
- An assumption exception with a message with the given actual value and a matcher describing the expectation that failed.
- AssumptionViolatedException(T, Matcher<T>) - 异常错误 的构造器org.junit.AssumptionViolatedException
- An assumption exception with the given actual value and a matcher describing the expectation that failed.
B
- BaseDescription - org.hamcrest中的类
- A
Description
that is stored as a string. - BaseDescription() - 类 的构造器org.hamcrest.BaseDescription
- BaseMatcher<T> - org.hamcrest中的类
- BaseClass for all Matcher implementations.
- BaseMatcher() - 类 的构造器org.hamcrest.BaseMatcher
- before() - 类 中的方法org.junit.rules.ExternalResource
- Override to set up your specific external resource.
- before() - 类 中的方法org.junit.rules.TemporaryFolder
- Before - org.junit中的注释类型
- When writing tests, it is common to find that several tests need similar objects created before they can run.
- BeforeClass - org.junit中的注释类型
- Sometimes several tests need to share computationally expensive setup (like logging into a database).
- BlockJUnit4ClassRunner - org.junit.runners中的类
- Implements the JUnit 4 standard test case class model, as defined by the annotations in the org.junit package.
- BlockJUnit4ClassRunner(Class<?>) - 类 的构造器org.junit.runners.BlockJUnit4ClassRunner
- Creates a BlockJUnit4ClassRunner to run
klass
- BlockJUnit4ClassRunnerWithParameters - org.junit.runners.parameterized中的类
- A
BlockJUnit4ClassRunner
with parameters support. - BlockJUnit4ClassRunnerWithParameters(TestWithParameters) - 类 的构造器org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- BlockJUnit4ClassRunnerWithParametersFactory - org.junit.runners.parameterized中的类
- A
ParametersRunnerFactory
that createsBlockJUnit4ClassRunnerWithParameters
. - BlockJUnit4ClassRunnerWithParametersFactory() - 类 的构造器org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParametersFactory
- BooleanSupplier - org.junit.experimental.theories.internal中的类
- BooleanSupplier() - 类 的构造器org.junit.experimental.theories.internal.BooleanSupplier
- both(Matcher<? super LHS>) - 类 中的静态方法org.hamcrest.core.CombinableMatcher
- Creates a matcher that matches when both of the specified matchers match the examined object.
- both(Matcher<? super LHS>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches when both of the specified matchers match the examined object.
- both(Matcher<? super T>) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.both(Matcher)
instead. - build() - 类 中的方法org.junit.rules.Timeout.Builder
- Builds a
Timeout
instance using the values in this builder - builder() - 类 中的静态方法org.junit.rules.Timeout
- Returns a new builder for building an instance.
- Builder() - 类 的构造器org.junit.rules.Timeout.Builder
C
- canAcceptType(Class<?>) - 类 中的方法org.junit.experimental.theories.ParameterSignature
- canAcceptValue(Object) - 类 中的方法org.junit.experimental.theories.ParameterSignature
- canObtainExpectedTypeFrom(Method) - 类 中的方法org.hamcrest.internal.ReflectiveTypeFinder
- canPotentiallyAcceptType(Class<?>) - 类 中的方法org.junit.experimental.theories.ParameterSignature
- Categories - org.junit.experimental.categories中的类
- From a given set of test classes, runs only the classes and methods that are annotated with either the category given with the @IncludeCategory annotation, or a subtype of that category.
- Categories(Class<?>, RunnerBuilder) - 类 的构造器org.junit.experimental.categories.Categories
- Categories.CategoryFilter - org.junit.experimental.categories中的类
- Categories.ExcludeCategory - org.junit.experimental.categories中的注释类型
- Categories.IncludeCategory - org.junit.experimental.categories中的注释类型
- Category - org.junit.experimental.categories中的注释类型
- Marks a test class or test method as belonging to one or more categories of tests.
- categoryFilter(boolean, Set<Class<?>>, boolean, Set<Class<?>>) - 类 中的静态方法org.junit.experimental.categories.Categories.CategoryFilter
- CategoryFilter(boolean, Set<Class<?>>, boolean, Set<Class<?>>) - 类 的构造器org.junit.experimental.categories.Categories.CategoryFilter
- CategoryValidator - org.junit.experimental.categories中的类
- Validates that there are no errors in the use of the
Category
annotation. - CategoryValidator() - 类 的构造器org.junit.experimental.categories.CategoryValidator
- checkSucceeds(Callable<T>) - 类 中的方法org.junit.rules.ErrorCollector
- Adds to the table the exception, if any, thrown from
callable
. - checkThat(String, T, Matcher<T>) - 类 中的方法org.junit.rules.ErrorCollector
- Adds a failure with the given
reason
to the table ifmatcher
does not matchvalue
. - checkThat(T, Matcher<T>) - 类 中的方法org.junit.rules.ErrorCollector
- Adds a failure to the table if
matcher
does not matchvalue
. - childlessCopy() - 类 中的方法org.junit.runner.Description
- childrenInvoker(RunNotifier) - 类 中的方法org.junit.runners.ParentRunner
- Returns a
Statement
: CallParentRunner.runChild(Object, RunNotifier)
on each object returned byParentRunner.getChildren()
(subject to any imposed filter and sort) - classBlock(RunNotifier) - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- classBlock(RunNotifier) - 类 中的方法org.junit.runners.ParentRunner
- Constructs a
Statement
to run all of the tests in the test class. - classes() - 类 中的静态方法org.junit.experimental.ParallelComputer
- classes(Class<?>...) - 类 中的静态方法org.junit.runner.Request
- Create a
Request
that, when processed, will run all the tests in a set of classes with the defaultComputer
. - classes(Computer, Class<?>...) - 类 中的静态方法org.junit.runner.Request
- Create a
Request
that, when processed, will run all the tests in a set of classes. - Classes - org.junit.internal中的类
- Miscellaneous functions dealing with classes.
- Classes() - 类 的构造器org.junit.internal.Classes
- ClassRule - org.junit中的注释类型
- Annotates static fields that reference rules or methods that return them.
- classRules() - 类 中的方法org.junit.runners.ParentRunner
- classWithoutSuiteMethod(Class<?>) - 类 中的静态方法org.junit.runner.Request
- Create a
Request
that, when processed, will run all the tests in a class. - collectInitializationErrors(List<Throwable>) - 类 中的方法org.junit.experimental.theories.Theories
- collectInitializationErrors(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- collectInitializationErrors(List<Throwable>) - 类 中的方法org.junit.runners.ParentRunner
- Adds to
errors
a throwable for each problem noted with the test class (available fromParentRunner.getTestClass()
). - CombinableBothMatcher(Matcher<? super X>) - 类 的构造器org.hamcrest.core.CombinableMatcher.CombinableBothMatcher
- CombinableEitherMatcher(Matcher<? super X>) - 类 的构造器org.hamcrest.core.CombinableMatcher.CombinableEitherMatcher
- CombinableMatcher<T> - org.hamcrest.core中的类
- CombinableMatcher(Matcher<? super T>) - 类 的构造器org.hamcrest.core.CombinableMatcher
- CombinableMatcher.CombinableBothMatcher<X> - org.hamcrest.core中的类
- CombinableMatcher.CombinableEitherMatcher<X> - org.hamcrest.core中的类
- compare(Description, Description) - 类 中的方法org.junit.runner.manipulation.Sorter
- ComparisonCriteria - org.junit.internal中的类
- Defines criteria for finding two items "equal enough".
- ComparisonCriteria() - 类 的构造器org.junit.internal.ComparisonCriteria
- ComparisonFailure - org.junit中的错误
- Thrown when an
assertEquals(String, String)
fails. - ComparisonFailure(String, String, String) - 错误 的构造器org.junit.ComparisonFailure
- Constructs a comparison failure.
- Computer - org.junit.runner中的类
- Represents a strategy for computing runners and suites.
- Computer() - 类 的构造器org.junit.runner.Computer
- computeTestMethods() - 类 中的方法org.junit.experimental.theories.Theories
- computeTestMethods() - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Returns the methods that run tests.
- Condition<T> - org.hamcrest中的类
- A Condition implements part of a multi-step match.
- Condition.Step<I,O> - org.hamcrest中的接口
- containsString(String) - 类 中的静态方法org.hamcrest.core.StringContains
- containsString(String) - 类 中的静态方法org.hamcrest.CoreMatchers
- containsString(String) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.containsString(String)
instead. - CoreMatchers - org.hamcrest中的类
- CoreMatchers() - 类 的构造器org.hamcrest.CoreMatchers
- CouldNotGenerateValueException() - 异常错误 的构造器org.junit.experimental.theories.PotentialAssignment.CouldNotGenerateValueException
- CouldNotGenerateValueException(Throwable) - 异常错误 的构造器org.junit.experimental.theories.PotentialAssignment.CouldNotGenerateValueException
- CouldNotReadCoreException - org.junit.experimental.max中的异常错误
- Thrown when Max cannot read the MaxCore serialization
- CouldNotReadCoreException(Throwable) - 异常错误 的构造器org.junit.experimental.max.CouldNotReadCoreException
- Constructs
- create() - 类 中的方法org.junit.rules.TemporaryFolder
- for testing purposes only.
- createAnnotationValidator(ValidateWith) - 类 中的方法org.junit.validator.AnnotationValidatorFactory
- Creates the AnnotationValidator specified by the value in
ValidateWith
. - createFailOnTimeoutStatement(Statement) - 类 中的方法org.junit.rules.Timeout
- Creates a
Statement
that will run the givenstatement
, and timeout the operation based on the values configured in this rule. - createFilter(List<Class<?>>) - 类 中的方法org.junit.experimental.categories.ExcludeCategories
- Creates a
Filter
which is only passed by tests that are not categorized with any of the specified categories. - createFilter(List<Class<?>>) - 类 中的方法org.junit.experimental.categories.IncludeCategories
- Creates a
Filter
which is only passed by tests that are categorized with any of the specified categories. - createFilter(FilterFactoryParams) - 接口 中的方法org.junit.runner.FilterFactory
- Creates a
Filter
given aFilterFactoryParams
argument. - createListener() - 类 中的方法org.junit.runner.Result
- Internal use only.
- createRunnerForTestWithParameters(TestWithParameters) - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParametersFactory
- createRunnerForTestWithParameters(TestWithParameters) - 接口 中的方法org.junit.runners.parameterized.ParametersRunnerFactory
- Returns a runner for the specified
TestWithParameters
. - createSuiteDescription(Class<?>) - 类 中的静态方法org.junit.runner.Description
- Create a
Description
named aftertestClass
- createSuiteDescription(String, Serializable, Annotation...) - 类 中的静态方法org.junit.runner.Description
- Create a
Description
namedname
. - createSuiteDescription(String, Annotation...) - 类 中的静态方法org.junit.runner.Description
- Create a
Description
namedname
. - createTest() - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Returns a new fixture for running a test.
- createTest() - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- createTestClass(Class<?>) - 类 中的方法org.junit.runners.ParentRunner
- createTestDescription(Class<?>, String) - 类 中的静态方法org.junit.runner.Description
- Create a
Description
of a single test namedname
in the classclazz
. - createTestDescription(Class<?>, String, Annotation...) - 类 中的静态方法org.junit.runner.Description
- Create a
Description
of a single test namedname
in the classclazz
. - createTestDescription(String, String, Serializable) - 类 中的静态方法org.junit.runner.Description
- Create a
Description
of a single test namedname
in the classclazz
. - createTestDescription(String, String, Annotation...) - 类 中的静态方法org.junit.runner.Description
- Create a
Description
of a single test namedname
in the 'class' namedclassName
. - CustomMatcher<T> - org.hamcrest中的类
- Utility class for writing one off matchers.
- CustomMatcher(String) - 类 的构造器org.hamcrest.CustomMatcher
- CustomTypeSafeMatcher<T> - org.hamcrest中的类
- Utility class for writing one off matchers.
- CustomTypeSafeMatcher(String) - 类 的构造器org.hamcrest.CustomTypeSafeMatcher
D
- DataPoint - org.junit.experimental.theories中的注释类型
- Annotating an field or method with @DataPoint will cause the field value or the value returned by the method to be used as a potential parameter for theories in that class, when run with the
Theories
runner. - DataPoints - org.junit.experimental.theories中的注释类型
- Annotating an array or iterable-typed field or method with @DataPoints will cause the values in the array or iterable given to be used as potential parameters for theories in that class when run with the
Theories
runner. - DEFAULT - org.junit.runners.MethodSorters
- Sorts the test methods in a deterministic, but not predictable, order
- DEFAULT - 类 中的静态变量org.junit.internal.MethodSorter
- DEFAULT sort order
- delete() - 类 中的方法org.junit.rules.TemporaryFolder
- Delete all files and folders under the temporary folder.
- Describable - org.junit.runner中的接口
- Represents an object that can describe itself
- describe() - 类 中的方法org.junit.experimental.categories.Categories.CategoryFilter
- describe() - 类 中的方法org.junit.runner.manipulation.Filter
- Returns a textual description of this Filter
- describeChild(Runner) - 类 中的方法org.junit.runners.Suite
- describeChild(FrameworkMethod) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- describeChild(T) - 类 中的方法org.junit.runners.ParentRunner
- Returns a
Description
forchild
, which can be assumed to be an element of the list returned byParentRunner.getChildren()
- describedAs(String, Matcher<T>, Object...) - 类 中的静态方法org.hamcrest.core.DescribedAs
- Wraps an existing matcher, overriding its description with that specified.
- describedAs(String, Matcher<T>, Object...) - 类 中的静态方法org.hamcrest.CoreMatchers
- Wraps an existing matcher, overriding its description with that specified.
- DescribedAs<T> - org.hamcrest.core中的类
- Provides a custom description to another matcher.
- DescribedAs(String, Matcher<T>, Object[]) - 类 的构造器org.hamcrest.core.DescribedAs
- describeMismatch(Object, Description) - 类 中的方法org.hamcrest.BaseMatcher
- describeMismatch(Object, Description) - 类 中的方法org.hamcrest.core.DescribedAs
- describeMismatch(Object, Description) - 类 中的方法org.hamcrest.core.Is
- describeMismatch(Object, Description) - 类 中的方法org.hamcrest.DiagnosingMatcher
- describeMismatch(Object, Description) - 接口 中的方法org.hamcrest.Matcher
- Generate a description of why the matcher has not accepted the item.
- describeMismatch(Object, Description) - 类 中的方法org.hamcrest.TypeSafeDiagnosingMatcher
- describeMismatch(Object, Description) - 类 中的方法org.hamcrest.TypeSafeMatcher
- describeMismatchSafely(String, Description) - 类 中的方法org.hamcrest.core.SubstringMatcher
- describeMismatchSafely(T, Description) - 类 中的方法org.hamcrest.TypeSafeMatcher
- Subclasses should override this.
- describeTo(Description) - 类 中的方法org.hamcrest.core.AllOf
- describeTo(Description) - 类 中的方法org.hamcrest.core.AnyOf
- describeTo(Description) - 类 中的方法org.hamcrest.core.CombinableMatcher
- describeTo(Description) - 类 中的方法org.hamcrest.core.DescribedAs
- describeTo(Description) - 类 中的方法org.hamcrest.core.Every
- describeTo(Description) - 类 中的方法org.hamcrest.core.Is
- describeTo(Description) - 类 中的方法org.hamcrest.core.IsAnything
- describeTo(Description) - 类 中的方法org.hamcrest.core.IsCollectionContaining
- describeTo(Description) - 类 中的方法org.hamcrest.core.IsEqual
- describeTo(Description) - 类 中的方法org.hamcrest.core.IsInstanceOf
- describeTo(Description) - 类 中的方法org.hamcrest.core.IsNot
- describeTo(Description) - 类 中的方法org.hamcrest.core.IsNull
- describeTo(Description) - 类 中的方法org.hamcrest.core.IsSame
- describeTo(Description) - 类 中的方法org.hamcrest.core.SubstringMatcher
- describeTo(Description) - 类 中的方法org.hamcrest.CustomMatcher
- describeTo(Description) - 类 中的方法org.hamcrest.CustomTypeSafeMatcher
- describeTo(Description) - 类 中的方法org.hamcrest.FeatureMatcher
- describeTo(Description) - 类 中的方法org.hamcrest.internal.SelfDescribingValue
- describeTo(Description) - 接口 中的方法org.hamcrest.SelfDescribing
- Generates a description of the object.
- describeTo(Description) - 异常错误 中的方法org.junit.internal.AssumptionViolatedException
- Description - org.junit.runner中的类
- A
Description
describes a test which is to be run or has been run. - Description - org.hamcrest中的接口
- A description of a Matcher.
- Description.NullDescription - org.hamcrest中的类
- DiagnosingMatcher<T> - org.hamcrest中的类
- TODO(ngd): Document.
- DiagnosingMatcher() - 类 的构造器org.hamcrest.DiagnosingMatcher
- DisableOnDebug - org.junit.rules中的类
- The
DisableOnDebug
Rule allows you to label certain rules to be disabled when debugging. - DisableOnDebug(TestRule) - 类 的构造器org.junit.rules.DisableOnDebug
- Create a
DisableOnDebug
instance with the timeout specified in milliseconds.
E
- either(Matcher<? super LHS>) - 类 中的静态方法org.hamcrest.core.CombinableMatcher
- Creates a matcher that matches when either of the specified matchers match the examined object.
- either(Matcher<? super LHS>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches when either of the specified matchers match the examined object.
- either(Matcher<? super T>) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.either(Matcher)
instead. - elapsedTimeAsString(long) - 类 中的方法org.junit.internal.TextListener
- Returns the formatted string of the elapsed time.
- EMPTY - 类 中的静态变量org.junit.runner.Description
- Describes a Runner which runs no tests
- emptyRuleChain() - 类 中的静态方法org.junit.rules.RuleChain
- Returns a
RuleChain
without aTestRule
. - emptySuite() - 类 中的静态方法org.junit.runners.Suite
- Returns an empty suite.
- Enclosed - org.junit.experimental.runners中的类
- If you put tests in inner classes, Ant, for example, won't find them.
- Enclosed(Class<?>, RunnerBuilder) - 类 的构造器org.junit.experimental.runners.Enclosed
- Only called reflectively.
- endsWith(String) - 类 中的静态方法org.hamcrest.core.StringEndsWith
- endsWith(String) - 类 中的静态方法org.hamcrest.CoreMatchers
- EnumSupplier - org.junit.experimental.theories.internal中的类
- EnumSupplier(Class<?>) - 类 的构造器org.junit.experimental.theories.internal.EnumSupplier
- equals(Object) - 错误 中的方法org.junit.experimental.theories.internal.ParameterizedAssertionError
- equals(Object) - 类 中的方法org.junit.runner.Description
- equals(Object) - 类 中的方法org.junit.runners.model.FrameworkMethod
- equals(Object) - 类 中的方法org.junit.runners.model.TestClass
- equals(Object) - 类 中的方法org.junit.runners.parameterized.TestWithParameters
- equalTo(T) - 类 中的静态方法org.hamcrest.core.IsEqual
- Creates a matcher that matches when the examined object is logically equal to the specified
operand
, as determined by calling theObject.equals(java.lang.Object)
method on the examined object. - equalTo(T) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches when the examined object is logically equal to the specified
operand
, as determined by calling theObject.equals(java.lang.Object)
method on the examined object. - ErrorCollector - org.junit.rules中的类
- The ErrorCollector rule allows execution of a test to continue after the first problem is found (for example, to collect _all_ the incorrect rows in a table, and report them all at once):
- ErrorCollector() - 类 的构造器org.junit.rules.ErrorCollector
- errorReport(Class<?>, Throwable) - 类 中的静态方法org.junit.runner.Request
- Creates a
Request
that, when processed, will report an error for the given test class with the given cause. - evalSubstringOf(String) - 类 中的方法org.hamcrest.core.StringContains
- evalSubstringOf(String) - 类 中的方法org.hamcrest.core.StringEndsWith
- evalSubstringOf(String) - 类 中的方法org.hamcrest.core.StringStartsWith
- evalSubstringOf(String) - 类 中的方法org.hamcrest.core.SubstringMatcher
- evaluate() - 类 中的方法org.junit.experimental.theories.Theories.TheoryAnchor
- evaluate() - 类 中的方法org.junit.rules.RunRules
- evaluate() - 类 中的方法org.junit.runners.model.Statement
- Run the action, throwing a
Throwable
if anything goes wrong. - Every<T> - org.hamcrest.core中的类
- Every(Matcher<? super T>) - 类 的构造器org.hamcrest.core.Every
- everyItem(Matcher<T>) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.everyItem(Matcher)
instead. - everyItem(Matcher<U>) - 类 中的静态方法org.hamcrest.core.Every
- everyItem(Matcher<U>) - 类 中的静态方法org.hamcrest.CoreMatchers
- ExactComparisonCriteria - org.junit.internal中的类
- ExactComparisonCriteria() - 类 的构造器org.junit.internal.ExactComparisonCriteria
- exclude(boolean, Class<?>...) - 类 中的静态方法org.junit.experimental.categories.Categories.CategoryFilter
- exclude(Class<?>) - 类 中的静态方法org.junit.experimental.categories.Categories.CategoryFilter
- exclude(Class<?>...) - 类 中的静态方法org.junit.experimental.categories.Categories.CategoryFilter
- ExcludeCategories - org.junit.experimental.categories中的类
FilterFactory
to exclude categories.- ExcludeCategories() - 类 的构造器org.junit.experimental.categories.ExcludeCategories
- exit(int) - 接口 中的方法org.junit.internal.JUnitSystem
- 已过时。
- exit(int) - 类 中的方法org.junit.internal.RealSystem
- 已过时。
- expect(Class<? extends Throwable>) - 类 中的方法org.junit.rules.ExpectedException
- Verify that your code throws an exception that is an instance of specific
type
. - expect(Matcher<?>) - 类 中的方法org.junit.rules.ExpectedException
- Verify that your code throws an exception that is matched by a Hamcrest matcher.
- expectCause(Matcher<? extends Throwable>) - 类 中的方法org.junit.rules.ExpectedException
- Verify that your code throws an exception whose cause is matched by a Hamcrest matcher.
- expected() - 注释类型 中的方法org.junit.Test
- Optionally specify
expected
, a Throwable, to cause a test method to succeed if and only if an exception of the specified class is thrown by the method. - ExpectedException - org.junit.rules中的类
- The
ExpectedException
rule allows you to verify that your code throws a specific exception. - expectedTypeFrom(Method) - 类 中的方法org.hamcrest.internal.ReflectiveTypeFinder
- expectMessage(String) - 类 中的方法org.junit.rules.ExpectedException
- Verify that your code throws an exception whose message contains a specific text.
- expectMessage(Matcher<String>) - 类 中的方法org.junit.rules.ExpectedException
- Verify that your code throws an exception whose message is matched by a Hamcrest matcher.
- ExternalResource - org.junit.rules中的类
- A base class for Rules (like TemporaryFolder) that set up an external resource before a test (a file, socket, server, database connection, etc.), and guarantee to tear it down afterward:
- ExternalResource() - 类 的构造器org.junit.rules.ExternalResource
F
- Factory - org.hamcrest中的注释类型
- Marks a Hamcrest static factory method so tools recognise them.
- fail() - 类 中的静态方法org.junit.Assert
- Fails a test with no message.
- fail(String) - 类 中的静态方法org.junit.Assert
- Fails a test with the given message.
- failed(long, Throwable, Description) - 类 中的方法org.junit.rules.Stopwatch
- Invoked when a test fails
- failed(Throwable, Description) - 类 中的方法org.junit.rules.TestWatcher
- Invoked when a test fails
- failed(Throwable, FrameworkMethod) - 类 中的方法org.junit.rules.TestWatchman
- 已过时。Invoked when a test method fails
- Failure - org.junit.runner.notification中的类
- A
Failure
holds a description of the failed test and the exception that was thrown while running it. - Failure(Description, Throwable) - 类 的构造器org.junit.runner.notification.Failure
- Constructs a
Failure
with the given description and exception. - failureCount() - 类 中的方法org.junit.experimental.results.PrintableResult
- Returns the number of failures in this result.
- failureCountIs(int) - 类 中的静态方法org.junit.experimental.results.ResultMatchers
- Matches if there are
count
failures - fDelta - 类 中的变量org.junit.internal.InexactComparisonCriteria
- FeatureMatcher<T,U> - org.hamcrest中的类
- Supporting class for matching a feature of an object.
- FeatureMatcher(Matcher<? super U>, String, String) - 类 的构造器org.hamcrest.FeatureMatcher
- Constructor
- featureValueOf(T) - 类 中的方法org.hamcrest.FeatureMatcher
- Implement this to extract the interesting feature.
- filter(Filter) - 接口 中的方法org.junit.runner.manipulation.Filterable
- Remove tests that don't pass the parameter
filter
. - filter(Filter) - 类 中的方法org.junit.runners.ParentRunner
- Filter - org.junit.runner.manipulation中的类
- The canonical case of filtering is when you want to run a single test method in a class.
- Filter() - 类 的构造器org.junit.runner.manipulation.Filter
- Filterable - org.junit.runner.manipulation中的接口
- Runners that allow filtering should implement this interface.
- FilterFactory - org.junit.runner中的接口
- Extend this class to create a factory that creates
Filter
. - FilterFactory.FilterNotCreatedException - org.junit.runner中的异常错误
- Exception thrown if the
Filter
cannot be created. - FilterFactoryParams - org.junit.runner中的类
- FilterFactoryParams(Description, String) - 类 的构造器org.junit.runner.FilterFactoryParams
- FilterNotCreatedException(Exception) - 异常错误 的构造器org.junit.runner.FilterFactory.FilterNotCreatedException
- filterWith(Description) - 类 中的方法org.junit.runner.Request
- Returns a Request that only runs contains tests whose
Description
equalsdesiredDescription
- filterWith(Filter) - 类 中的方法org.junit.runner.Request
- Returns a Request that only contains those tests that should run when
filter
is applied - findDeepAnnotation(Class<T>) - 类 中的方法org.junit.experimental.theories.ParameterSignature
- findExpectedType(Class<?>) - 类 中的方法org.hamcrest.internal.ReflectiveTypeFinder
- finished() - 接口 中的方法org.junit.runners.model.RunnerScheduler
- Override to implement any behavior that must occur after all children have been scheduled (for example, waiting for them all to finish)
- finished(long, Description) - 类 中的方法org.junit.rules.Stopwatch
- Invoked when a test method finishes (whether passing or failing)
- finished(Description) - 类 中的方法org.junit.rules.TestWatcher
- Invoked when a test method finishes (whether passing or failing)
- finished(FrameworkMethod) - 类 中的方法org.junit.rules.TestWatchman
- 已过时。Invoked when a test method finishes (whether passing or failing)
- fireTestAssumptionFailed(Failure) - 类 中的方法org.junit.runner.notification.RunNotifier
- Invoke to tell listeners that an atomic test flagged that it assumed something false.
- fireTestFailure(Failure) - 类 中的方法org.junit.runner.notification.RunNotifier
- Invoke to tell listeners that an atomic test failed.
- fireTestFinished(Description) - 类 中的方法org.junit.runner.notification.RunNotifier
- Invoke to tell listeners that an atomic test finished.
- fireTestIgnored(Description) - 类 中的方法org.junit.runner.notification.RunNotifier
- Invoke to tell listeners that an atomic test was ignored.
- fireTestRunFinished(Result) - 类 中的方法org.junit.runner.notification.RunNotifier
- Do not invoke.
- fireTestRunStarted(Description) - 类 中的方法org.junit.runner.notification.RunNotifier
- Do not invoke.
- fireTestStarted(Description) - 类 中的方法org.junit.runner.notification.RunNotifier
- Invoke to tell listeners that an atomic test is about to start.
- FixMethodOrder - org.junit中的注释类型
- This class allows the user to choose the order of execution of the methods within a test class.
- forFolder(File) - 类 中的静态方法org.junit.experimental.max.MaxHistory
- forFolder(String) - 类 中的静态方法org.junit.experimental.max.MaxCore
- 已过时。use storedLocally()
- forValue(String, Object) - 类 中的静态方法org.junit.experimental.theories.PotentialAssignment
- FrameworkField - org.junit.runners.model中的类
- Represents a field on a test class (currently used only for Rules in
BlockJUnit4ClassRunner
, but custom runners can make other uses) - FrameworkMember<T extends FrameworkMember<T>> - org.junit.runners.model中的类
- Parent class for
FrameworkField
andFrameworkMethod
- FrameworkMember() - 类 的构造器org.junit.runners.model.FrameworkMember
- FrameworkMethod - org.junit.runners.model中的类
- Represents a method on a test class to be invoked at the appropriate point in test execution.
- FrameworkMethod(Method) - 类 的构造器org.junit.runners.model.FrameworkMethod
- Returns a new
FrameworkMethod
formethod
- FromDataPoints - org.junit.experimental.theories中的注释类型
- Annotating a parameter of a
@Theory
method with@FromDataPoints
will limit the datapoints considered as potential values for that parameter to just theDataPoints
with the given name.
G
- get(Object) - 类 中的方法org.junit.runners.model.FrameworkField
- Attempts to retrieve the value of this field on
target
- getActual() - 错误 中的方法org.junit.ComparisonFailure
- Returns the actual string value
- getActualValues(int, int) - 类 中的方法org.junit.experimental.theories.internal.Assignments
- getAllArguments() - 类 中的方法org.junit.experimental.theories.internal.Assignments
- getAnnotatedFields() - 类 中的方法org.junit.runners.model.TestClass
- Returns, efficiently, all the non-overridden fields in this class and its superclasses that are annotated.
- getAnnotatedFields(Class<? extends Annotation>) - 类 中的方法org.junit.runners.model.TestClass
- Returns, efficiently, all the non-overridden fields in this class and its superclasses that are annotated with
annotationClass
. - getAnnotatedFieldValues(Object, Class<? extends Annotation>, Class<T>) - 类 中的方法org.junit.runners.model.TestClass
- getAnnotatedMethods() - 类 中的方法org.junit.runners.model.TestClass
- Returns, efficiently, all the non-overridden methods in this class and its superclasses that are annotated}.
- getAnnotatedMethods(Class<? extends Annotation>) - 类 中的方法org.junit.runners.model.TestClass
- Returns, efficiently, all the non-overridden methods in this class and its superclasses that are annotated with
annotationClass
. - getAnnotatedMethodValues(Object, Class<? extends Annotation>, Class<T>) - 类 中的方法org.junit.runners.model.TestClass
- getAnnotation(Class<T>) - 类 中的方法org.junit.experimental.theories.ParameterSignature
- getAnnotation(Class<T>) - 类 中的方法org.junit.runner.Description
- getAnnotation(Class<T>) - 接口 中的方法org.junit.runners.model.Annotatable
- Returns the annotation on the model element of the given type, or @code{null}
- getAnnotation(Class<T>) - 类 中的方法org.junit.runners.model.FrameworkField
- getAnnotation(Class<T>) - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the annotation of type
annotationType
on this method, if one exists. - getAnnotation(Class<T>) - 类 中的方法org.junit.runners.model.TestClass
- getAnnotations() - 类 中的方法org.junit.experimental.theories.ParameterSignature
- getAnnotations() - 类 中的方法org.junit.runner.Description
- getAnnotations() - 接口 中的方法org.junit.runners.model.Annotatable
- Returns the model elements' annotations.
- getAnnotations() - 类 中的方法org.junit.runners.model.FrameworkField
- getAnnotations() - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the annotations on this method
- getAnnotations() - 类 中的方法org.junit.runners.model.TestClass
- Returns the annotations on this class
- getArgs() - 类 中的方法org.junit.runner.FilterFactoryParams
- getArgumentStrings(boolean) - 类 中的方法org.junit.experimental.theories.internal.Assignments
- getCauses() - 异常错误 中的方法org.junit.runners.model.InitializationError
- Returns one or more Throwables that led to this initialization error.
- getChildren() - 类 中的方法org.junit.runner.Description
- Gets the copy of the children of this
Description
. - getChildren() - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- getChildren() - 类 中的方法org.junit.runners.Parameterized
- getChildren() - 类 中的方法org.junit.runners.ParentRunner
- Returns a list of objects that define the children of this Runner.
- getChildren() - 类 中的方法org.junit.runners.Suite
- getClass(String) - 类 中的静态方法org.junit.internal.Classes
- Returns Class.forName for
className
using the current thread's class loader. - getClassName() - 类 中的方法org.junit.runner.Description
- getComparator() - 枚举 中的方法org.junit.runners.MethodSorters
- getConstructorArguments() - 类 中的方法org.junit.experimental.theories.internal.Assignments
- getDataPointsFields(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.AllMembersSupplier
- getDataPointsFields(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.SpecificDataPointsSupplier
- getDataPointsMethods(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.AllMembersSupplier
- getDataPointsMethods(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.SpecificDataPointsSupplier
- getDeclaredMethods(Class<?>) - 类 中的静态方法org.junit.internal.MethodSorter
- Gets declared methods of a class in a predictable order, unless @FixMethodOrder(MethodSorters.JVM) is specified.
- getDeclaringClass() - 类 中的方法org.junit.runners.model.FrameworkField
- getDeclaringClass() - 类 中的方法org.junit.runners.model.FrameworkMember
- getDeclaringClass() - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the class where the method is actually declared
- getDescription() - 类 中的方法org.junit.experimental.theories.PotentialAssignment
- getDescription() - 接口 中的方法org.junit.runner.Describable
- getDescription() - 类 中的方法org.junit.runner.notification.Failure
- getDescription() - 类 中的方法org.junit.runner.Runner
- getDescription() - 类 中的方法org.junit.runners.ParentRunner
- getDisplayName() - 类 中的方法org.junit.runner.Description
- getException() - 类 中的方法org.junit.runner.notification.Failure
- getExpected() - 错误 中的方法org.junit.ComparisonFailure
- Returns the expected string value
- getFailureCount() - 类 中的方法org.junit.runner.Result
- getFailures() - 类 中的方法org.junit.runner.Result
- getFailures() - 异常错误 中的方法org.junit.runners.model.MultipleFailureException
- getField() - 类 中的方法org.junit.runners.model.FrameworkField
- getIgnoreCount() - 类 中的方法org.junit.runner.Result
- getJavaClass() - 类 中的方法org.junit.runners.model.TestClass
- Returns the underlying Java class.
- getLookingForStuckThread() - 类 中的方法org.junit.rules.Timeout.Builder
- getLookingForStuckThread() - 类 中的方法org.junit.rules.Timeout
- Gets whether this
Timeout
will look for a stuck thread when the test times out. - getMessage() - 错误 中的方法org.junit.ComparisonFailure
- Returns "..." in place of common prefix and "..." in place of common suffix between expected and actual.
- getMessage() - 错误 中的方法org.junit.internal.ArrayComparisonFailure
- getMessage() - 异常错误 中的方法org.junit.internal.AssumptionViolatedException
- getMessage() - 类 中的方法org.junit.runner.notification.Failure
- Convenience method
- getMessage() - 异常错误 中的方法org.junit.runners.model.MultipleFailureException
- getMethod() - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the underlying Java method
- getMethodArguments() - 类 中的方法org.junit.experimental.theories.internal.Assignments
- getMethodName() - 类 中的方法org.junit.rules.TestName
- getMethodName() - 类 中的方法org.junit.runner.Description
- getModifiers() - 类 中的方法org.junit.runners.model.FrameworkField
- getModifiers() - 类 中的方法org.junit.runners.model.FrameworkMember
- getModifiers() - 类 中的方法org.junit.runners.model.FrameworkMethod
- getName() - 类 中的方法org.junit.runners.model.FrameworkField
- getName() - 类 中的方法org.junit.runners.model.FrameworkMember
- getName() - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the method's name
- getName() - 类 中的方法org.junit.runners.model.TestClass
- Returns the class's name.
- getName() - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- getName() - 类 中的方法org.junit.runners.parameterized.TestWithParameters
- getName() - 类 中的方法org.junit.runners.ParentRunner
- Returns a name used to describe this Runner
- getOnlyConstructor() - 类 中的方法org.junit.runners.model.TestClass
- Returns the only public constructor in the class, or throws an
AssertionError
if there are more or less than one. - getParameters() - 类 中的方法org.junit.runners.parameterized.TestWithParameters
- getReturnType() - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the return type of the method
- getRoot() - 类 中的方法org.junit.rules.TemporaryFolder
- getRunCount() - 类 中的方法org.junit.runner.Result
- getRunner() - 类 中的方法org.junit.runner.Request
- Returns a
Runner
for this Request - getRunner(RunnerBuilder, Class<?>) - 类 中的方法org.junit.experimental.ParallelComputer
- getRunner(RunnerBuilder, Class<?>) - 类 中的方法org.junit.runner.Computer
- Create a single-class runner for
testClass
, usingbuilder
- getRunnerAnnotations() - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- getRunnerAnnotations() - 类 中的方法org.junit.runners.ParentRunner
- getRunTime() - 类 中的方法org.junit.runner.Result
- getSingleDataPointFields(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.AllMembersSupplier
- getSingleDataPointFields(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.SpecificDataPointsSupplier
- getSingleDataPointMethods(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.AllMembersSupplier
- getSingleDataPointMethods(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.SpecificDataPointsSupplier
- getSuite(RunnerBuilder, Class<?>[]) - 类 中的方法org.junit.experimental.ParallelComputer
- getSuite(RunnerBuilder, Class<?>[]) - 类 中的方法org.junit.runner.Computer
- Create a suite for
classes
, building Runners withbuilder
. - getTestClass() - 类 中的方法org.junit.runner.Description
- getTestClass() - 类 中的方法org.junit.runners.parameterized.TestWithParameters
- getTestClass() - 类 中的方法org.junit.runners.ParentRunner
- Returns a
TestClass
object wrapping the class to be executed. - getTestHeader() - 类 中的方法org.junit.runner.notification.Failure
- getTestRules(Object) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- getTimeout() - 类 中的方法org.junit.rules.Timeout.Builder
- getTimeout() - 异常错误 中的方法org.junit.runners.model.TestTimedOutException
- Gets the time passed before the test was interrupted
- getTimeout(TimeUnit) - 类 中的方法org.junit.rules.Timeout
- Gets the timeout configured for this rule, in the given units.
- getTimeUnit() - 类 中的方法org.junit.rules.Timeout.Builder
- getTimeUnit() - 异常错误 中的方法org.junit.runners.model.TestTimedOutException
- Gets the time unit for the timeout value
- getTopLevelDescription() - 类 中的方法org.junit.runner.FilterFactoryParams
- getTrace() - 类 中的方法org.junit.runner.notification.Failure
- Convenience method
- getType() - 类 中的方法org.junit.experimental.theories.ParameterSignature
- getType() - 类 中的方法org.junit.runners.model.FrameworkField
- getType() - 类 中的方法org.junit.runners.model.FrameworkMember
- getType() - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the return type of the method
- getValue() - 类 中的方法org.junit.experimental.theories.PotentialAssignment
- getValueSources(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.AllMembersSupplier
- getValueSources(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.BooleanSupplier
- getValueSources(ParameterSignature) - 类 中的方法org.junit.experimental.theories.internal.EnumSupplier
- getValueSources(ParameterSignature) - 类 中的方法org.junit.experimental.theories.ParameterSupplier
- getValueSources(ParameterSignature) - 类 中的方法org.junit.experimental.theories.suppliers.TestedOnSupplier
- getVersion() - 类 中的方法org.junit.runner.JUnitCore
H
- handleAssertionErrors() - 类 中的方法org.junit.rules.ExpectedException
- 已过时。AssertionErrors are handled by default since JUnit 4.12. Just like in JUnit <= 4.10.
- handleAssumptionViolatedExceptions() - 类 中的方法org.junit.rules.ExpectedException
- 已过时。AssumptionViolatedExceptions are handled by default since JUnit 4.12. Just like in JUnit <= 4.10.
- handleAssumptionViolation(AssumptionViolatedException) - 类 中的方法org.junit.experimental.theories.Theories.TheoryAnchor
- handleDataPointSuccess() - 类 中的方法org.junit.experimental.theories.Theories.TheoryAnchor
- hasAnnotation(Class<? extends Annotation>) - 类 中的方法org.junit.experimental.theories.ParameterSignature
- hasFailureContaining(String) - 类 中的静态方法org.junit.experimental.results.ResultMatchers
- Matches if the result has one or more failures, and at least one of them contains
string
- hashCode() - 错误 中的方法org.junit.experimental.theories.internal.ParameterizedAssertionError
- hashCode() - 类 中的方法org.junit.runner.Description
- hashCode() - 类 中的方法org.junit.runners.model.FrameworkMethod
- hashCode() - 类 中的方法org.junit.runners.model.TestClass
- hashCode() - 类 中的方法org.junit.runners.parameterized.TestWithParameters
- hasItem(Matcher<? super T>) - 类 中的静态方法org.hamcrest.core.IsCollectionContaining
- hasItem(Matcher<? super T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- hasItem(Matcher<? super T>) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.hasItem(Matcher)
instead. - hasItem(T) - 类 中的静态方法org.hamcrest.core.IsCollectionContaining
- hasItem(T) - 类 中的静态方法org.hamcrest.CoreMatchers
- hasItem(T) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.hasItem(Object)
instead. - hasItems(Matcher<? super T>...) - 类 中的静态方法org.hamcrest.core.IsCollectionContaining
- hasItems(Matcher<? super T>...) - 类 中的静态方法org.hamcrest.CoreMatchers
- hasItems(Matcher<? super T>...) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.hasItems(Matcher...)
instead. - hasItems(T...) - 类 中的静态方法org.hamcrest.core.IsCollectionContaining
- hasItems(T...) - 类 中的静态方法org.hamcrest.CoreMatchers
- hasItems(T...) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- 已过时。Please use
CoreMatchers.hasItems(Object...)
instead. - hasNext() - 类 中的方法org.hamcrest.internal.ArrayIterator
- hasNext() - 类 中的方法org.hamcrest.internal.SelfDescribingValueIterator
- hasSingleFailureContaining(String) - 类 中的静态方法org.junit.experimental.results.ResultMatchers
- Matches if the result has exactly one failure, and it contains
string
I
- Ignore - org.junit中的注释类型
- Sometimes you want to temporarily disable a test or a group of tests.
- ignoredExceptions() - 注释类型 中的方法org.junit.experimental.theories.DataPoint
- ignoredExceptions() - 注释类型 中的方法org.junit.experimental.theories.DataPoints
- include(boolean, Class<?>...) - 类 中的静态方法org.junit.experimental.categories.Categories.CategoryFilter
- include(Class<?>) - 类 中的静态方法org.junit.experimental.categories.Categories.CategoryFilter
- include(Class<?>...) - 类 中的静态方法org.junit.experimental.categories.Categories.CategoryFilter
- IncludeCategories - org.junit.experimental.categories中的类
FilterFactory
to include categories.- IncludeCategories() - 类 的构造器org.junit.experimental.categories.IncludeCategories
- InexactComparisonCriteria - org.junit.internal中的类
- InexactComparisonCriteria(double) - 类 的构造器org.junit.internal.InexactComparisonCriteria
- InexactComparisonCriteria(float) - 类 的构造器org.junit.internal.InexactComparisonCriteria
- InitializationError - org.junit.runners.model中的异常错误
- Represents one or more problems encountered while initializing a Runner
- InitializationError(String) - 异常错误 的构造器org.junit.runners.model.InitializationError
- Construct a new
InitializationError
with one cause with messagestring
- InitializationError(Throwable) - 异常错误 的构造器org.junit.runners.model.InitializationError
- InitializationError(List<Throwable>) - 异常错误 的构造器org.junit.runners.model.InitializationError
- Construct a new
InitializationError
with one or more errorserrors
as causes - instanceOf(Class<?>) - 类 中的静态方法org.hamcrest.core.IsInstanceOf
- Creates a matcher that matches when the examined object is an instance of the specified
type
, as determined by calling theClass.isInstance(Object)
method on that type, passing the the examined object. - instanceOf(Class<?>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches when the examined object is an instance of the specified
type
, as determined by calling theClass.isInstance(Object)
method on that type, passing the the examined object. - intersect(Filter) - 类 中的方法org.junit.runner.manipulation.Filter
- Returns a new Filter that accepts the intersection of the tests accepted by this Filter and
second
- ints() - 注释类型 中的方法org.junit.experimental.theories.suppliers.TestedOn
- invokeExplosively(Object, Object...) - 类 中的方法org.junit.runners.model.FrameworkMethod
- Returns the result of invoking this method on
target
with parametersparams
. - is(Class<T>) - 类 中的静态方法org.hamcrest.core.Is
- 已过时。use isA(Class
type) instead. - is(Class<T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- 已过时。use isA(Class
type) instead. - is(Matcher<T>) - 类 中的静态方法org.hamcrest.core.Is
- Decorates another Matcher, retaining its behaviour, but allowing tests to be slightly more expressive.
- is(Matcher<T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Decorates another Matcher, retaining its behaviour, but allowing tests to be slightly more expressive.
- is(T) - 类 中的静态方法org.hamcrest.core.Is
- A shortcut to the frequently used
is(equalTo(x))
. - is(T) - 类 中的静态方法org.hamcrest.CoreMatchers
- A shortcut to the frequently used
is(equalTo(x))
. - Is<T> - org.hamcrest.core中的类
- Decorates another Matcher, retaining the behaviour but allowing tests to be slightly more expressive.
- Is(Matcher<T>) - 类 的构造器org.hamcrest.core.Is
- isA(Class<T>) - 类 中的静态方法org.hamcrest.core.Is
- A shortcut to the frequently used
is(instanceOf(SomeClass.class))
. - isA(Class<T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- A shortcut to the frequently used
is(instanceOf(SomeClass.class))
. - isANonStaticInnerClass() - 类 中的方法org.junit.runners.model.TestClass
- IsAnything<T> - org.hamcrest.core中的类
- A matcher that always returns
true
. - IsAnything() - 类 的构造器org.hamcrest.core.IsAnything
- IsAnything(String) - 类 的构造器org.hamcrest.core.IsAnything
- IsCollectionContaining<T> - org.hamcrest.core中的类
- IsCollectionContaining(Matcher<? super T>) - 类 的构造器org.hamcrest.core.IsCollectionContaining
- isComplete() - 类 中的方法org.junit.experimental.theories.internal.Assignments
- isDebugging() - 类 中的方法org.junit.rules.DisableOnDebug
- Returns
true
if the JVM is in debug mode. - isEmpty() - 类 中的方法org.junit.runner.Description
- IsEqual<T> - org.hamcrest.core中的类
- Is the value equal to another value, as tested by the
Object.equals(java.lang.Object)
invokedMethod? - IsEqual(T) - 类 的构造器org.hamcrest.core.IsEqual
- isException(Matcher<T>) - 类 中的静态方法org.junit.matchers.JUnitMatchers
- isIgnored(FrameworkMethod) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Evaluates whether
FrameworkMethod
s are ignored based on theIgnore
annotation. - isIgnored(T) - 类 中的方法org.junit.runners.ParentRunner
- Evaluates whether a child is ignored.
- IsInstanceOf - org.hamcrest.core中的类
- Tests whether the value is an instance of a class.
- IsInstanceOf(Class<?>) - 类 的构造器org.hamcrest.core.IsInstanceOf
- Creates a new instance of IsInstanceOf
- IsNot<T> - org.hamcrest.core中的类
- Calculates the logical negation of a matcher.
- IsNot(Matcher<T>) - 类 的构造器org.hamcrest.core.IsNot
- IsNull<T> - org.hamcrest.core中的类
- Is the value null?
- IsNull() - 类 的构造器org.hamcrest.core.IsNull
- isPublic() - 类 中的方法org.junit.runners.model.FrameworkMember
- Returns true if this member is public, false if not.
- isPublic() - 类 中的方法org.junit.runners.model.TestClass
- IsSame<T> - org.hamcrest.core中的类
- Is the value the same object as another value?
- IsSame(T) - 类 的构造器org.hamcrest.core.IsSame
- isShadowedBy(FrameworkField) - 类 中的方法org.junit.runners.model.FrameworkField
- isShadowedBy(FrameworkMethod) - 类 中的方法org.junit.runners.model.FrameworkMethod
- isStatic() - 类 中的方法org.junit.runners.model.FrameworkMember
- Returns true if this member is static, false if not.
- isSuccessful() - 类 中的静态方法org.junit.experimental.results.ResultMatchers
- Matches if the tests are all successful
- isSuite() - 类 中的方法org.junit.runner.Description
- isTest() - 类 中的方法org.junit.runner.Description
- isThrowable(Matcher<T>) - 类 中的静态方法org.junit.matchers.JUnitMatchers
J
- join(String, Object...) - 错误 中的静态方法org.junit.experimental.theories.internal.ParameterizedAssertionError
- join(String, Collection<Object>) - 错误 中的静态方法org.junit.experimental.theories.internal.ParameterizedAssertionError
- JUnit4 - org.junit.runners中的类
- Aliases the current default JUnit 4 class runner, for future-proofing.
- JUnit4(Class<?>) - 类 的构造器org.junit.runners.JUnit4
- Constructs a new instance of the default runner
- JUnitCore - org.junit.runner中的类
JUnitCore
is a facade for running tests.- JUnitCore() - 类 的构造器org.junit.runner.JUnitCore
- JUnitMatchers - org.junit.matchers中的类
- Convenience import class: these are useful matchers for use with the assertThat method, but they are not currently included in the basic CoreMatchers class from hamcrest.
- JUnitMatchers() - 类 的构造器org.junit.matchers.JUnitMatchers
- JUnitSystem - org.junit.internal中的接口
- JVM - org.junit.runners.MethodSorters
- Leaves the test methods in the order returned by the JVM.
L
- listener() - 类 中的方法org.junit.experimental.max.MaxHistory
M
- main(String...) - 类 中的静态方法org.junit.runner.JUnitCore
- Run the tests contained in the classes named in the
args
. - matchAny() - 注释类型 中的方法org.junit.experimental.categories.Categories.ExcludeCategory
- If true, the tests annotated with any of the categories in
Categories.ExcludeCategory.value()
do not run. - matchAny() - 注释类型 中的方法org.junit.experimental.categories.Categories.IncludeCategory
- If true, runs tests annotated with any of the categories in
Categories.IncludeCategory.value()
. - matched(T, Description) - 类 中的静态方法org.hamcrest.Condition
- Matcher<T> - org.hamcrest中的接口
- A matcher over acceptable values.
- MatcherAssert - org.hamcrest中的类
- MatcherAssert() - 类 的构造器org.hamcrest.MatcherAssert
- matches(Object) - 类 中的方法org.hamcrest.core.AnyOf
- matches(Object) - 类 中的方法org.hamcrest.core.DescribedAs
- matches(Object) - 类 中的方法org.hamcrest.core.Is
- matches(Object) - 类 中的方法org.hamcrest.core.IsAnything
- matches(Object) - 类 中的方法org.hamcrest.core.IsEqual
- matches(Object) - 类 中的方法org.hamcrest.core.IsNot
- matches(Object) - 类 中的方法org.hamcrest.core.IsNull
- matches(Object) - 类 中的方法org.hamcrest.core.IsSame
- matches(Object) - 类 中的方法org.hamcrest.DiagnosingMatcher
- matches(Object) - 接口 中的方法org.hamcrest.Matcher
- Evaluates the matcher for argument item.
- matches(Object) - 类 中的方法org.hamcrest.TypeSafeDiagnosingMatcher
- matches(Object) - 类 中的方法org.hamcrest.TypeSafeMatcher
- Methods made final to prevent accidental override.
- matches(Object, Description) - 类 中的方法org.hamcrest.core.AllOf
- matches(Object, Description) - 类 中的方法org.hamcrest.core.IsInstanceOf
- matches(Object, Description) - 类 中的方法org.hamcrest.DiagnosingMatcher
- matchesSafely(Iterable<? super T>, Description) - 类 中的方法org.hamcrest.core.IsCollectionContaining
- matchesSafely(Iterable<T>, Description) - 类 中的方法org.hamcrest.core.Every
- matchesSafely(String) - 类 中的方法org.hamcrest.core.SubstringMatcher
- matchesSafely(T) - 类 中的方法org.hamcrest.TypeSafeMatcher
- Subclasses should implement this.
- matchesSafely(T, Description) - 类 中的方法org.hamcrest.core.CombinableMatcher
- matchesSafely(T, Description) - 类 中的方法org.hamcrest.FeatureMatcher
- matchesSafely(T, Description) - 类 中的方法org.hamcrest.TypeSafeDiagnosingMatcher
- Subclasses should implement this.
- matching(Matcher<T>) - 类 中的方法org.hamcrest.Condition
- matching(Matcher<T>, String) - 类 中的方法org.hamcrest.Condition
- matchMethodDescription(Description) - 类 中的静态方法org.junit.runner.manipulation.Filter
- Returns a
Filter
that only runs the single method described bydesiredDescription
- MaxCore - org.junit.experimental.max中的类
- A replacement for JUnitCore, which keeps track of runtime and failure history, and reorders tests to maximize the chances that a failing test occurs early in the test run.
- MaxHistory - org.junit.experimental.max中的类
- Stores a subset of the history of each test: Last failure timestamp Duration of last execution
- method(Class<?>, String) - 类 中的静态方法org.junit.runner.Request
- Create a
Request
that, when processed, will run a single test. - methodBlock(FrameworkMethod) - 类 中的方法org.junit.experimental.theories.Theories
- methodBlock(FrameworkMethod) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Returns a Statement that, when executed, either returns normally if
method
passes, or throws an exception ifmethod
fails. - methodInvoker(FrameworkMethod, Object) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- MethodRule - org.junit.rules中的接口
- A MethodRule is an alteration in how a test method is run and reported.
- methods() - 类 中的静态方法org.junit.experimental.ParallelComputer
- MethodSorter - org.junit.internal中的类
- MethodSorters - org.junit.runners中的枚举
- Sort the methods into a specified execution order.
- millis(long) - 类 中的静态方法org.junit.rules.Timeout
- Creates a
Timeout
that will timeout a test after the given duration, in milliseconds. - MultipleFailureException - org.junit.runners.model中的异常错误
- Collects multiple
Throwable
s into one exception. - MultipleFailureException(List<Throwable>) - 异常错误 的构造器org.junit.runners.model.MultipleFailureException
N
- name() - 注释类型 中的方法org.junit.runners.Parameterized.Parameters
- Optional pattern to derive the test's name from the parameters.
- NAME_ASCENDING - org.junit.runners.MethodSorters
- Sorts the test methods by the method name, in lexicographic order, with
Method.toString()
used as a tiebreaker - NAME_ASCENDING - 类 中的静态变量org.junit.internal.MethodSorter
- Method name ascending lexicographic sort order, with
Method.toString()
as a tiebreaker - newFile() - 类 中的方法org.junit.rules.TemporaryFolder
- Returns a new fresh file with a random name under the temporary folder.
- newFile(String) - 类 中的方法org.junit.rules.TemporaryFolder
- Returns a new fresh file with the given name under the temporary folder.
- newFolder() - 类 中的方法org.junit.rules.TemporaryFolder
- Returns a new fresh folder with a random name under the temporary folder.
- newFolder(String) - 类 中的方法org.junit.rules.TemporaryFolder
- Returns a new fresh folder with the given name under the temporary folder.
- newFolder(String...) - 类 中的方法org.junit.rules.TemporaryFolder
- Returns a new fresh folder with the given name(s) under the temporary folder.
- next() - 类 中的方法org.hamcrest.internal.ArrayIterator
- next() - 类 中的方法org.hamcrest.internal.SelfDescribingValueIterator
- nextUnassigned() - 类 中的方法org.junit.experimental.theories.internal.Assignments
- none() - 类 中的静态方法org.junit.rules.ExpectedException
- Returns a rule that expects no exception to be thrown (identical to behavior without this rule).
- NONE - 接口 中的静态变量org.hamcrest.Description
- A description that consumes input but does nothing.
- not(Matcher<T>) - 类 中的静态方法org.hamcrest.core.IsNot
- Creates a matcher that wraps an existing matcher, but inverts the logic by which it will match.
- not(Matcher<T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that wraps an existing matcher, but inverts the logic by which it will match.
- not(T) - 类 中的静态方法org.hamcrest.core.IsNot
- A shortcut to the frequently used
not(equalTo(x))
. - not(T) - 类 中的静态方法org.hamcrest.CoreMatchers
- A shortcut to the frequently used
not(equalTo(x))
. - NOT_MATCHED - 类 中的静态变量org.hamcrest.Condition
- NoTestsRemainException - org.junit.runner.manipulation中的异常错误
- Thrown when a filter removes all tests from a runner.
- NoTestsRemainException() - 异常错误 的构造器org.junit.runner.manipulation.NoTestsRemainException
- notMatched() - 类 中的静态方法org.hamcrest.Condition
- notNullValue() - 类 中的静态方法org.hamcrest.core.IsNull
- A shortcut to the frequently used
not(nullValue())
. - notNullValue() - 类 中的静态方法org.hamcrest.CoreMatchers
- A shortcut to the frequently used
not(nullValue())
. - notNullValue(Class<T>) - 类 中的静态方法org.hamcrest.core.IsNull
- A shortcut to the frequently used
not(nullValue(X.class)).
- notNullValue(Class<T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- A shortcut to the frequently used
not(nullValue(X.class)).
- NULL - 类 中的静态变量org.junit.runner.manipulation.Sorter
- NULL is a
Sorter
that leaves elements in an undefined order - NullDescription() - 类 的构造器org.hamcrest.Description.NullDescription
- nullsAccepted() - 注释类型 中的方法org.junit.experimental.theories.Theory
- nullValue() - 类 中的静态方法org.hamcrest.core.IsNull
- Creates a matcher that matches if examined object is
null
. - nullValue() - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if examined object is
null
. - nullValue(Class<T>) - 类 中的静态方法org.hamcrest.core.IsNull
- Creates a matcher that matches if examined object is
null
. - nullValue(Class<T>) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches if examined object is
null
.
O
- or(Matcher<? super T>) - 类 中的方法org.hamcrest.core.CombinableMatcher
- or(Matcher<? super X>) - 类 中的方法org.hamcrest.core.CombinableMatcher.CombinableEitherMatcher
- org.hamcrest - 程序包 org.hamcrest
- The stable API defining Matcher and its associated interfaces and classes.
- org.hamcrest.core - 程序包 org.hamcrest.core
- Fundamental matchers of objects and values, and composite matchers.
- org.hamcrest.internal - 程序包 org.hamcrest.internal
- org.junit - 程序包 org.junit
- Provides JUnit core classes and annotations.
- org.junit.experimental - 程序包 org.junit.experimental
- org.junit.experimental.categories - 程序包 org.junit.experimental.categories
- org.junit.experimental.max - 程序包 org.junit.experimental.max
- org.junit.experimental.results - 程序包 org.junit.experimental.results
- org.junit.experimental.runners - 程序包 org.junit.experimental.runners
- org.junit.experimental.theories - 程序包 org.junit.experimental.theories
- org.junit.experimental.theories.internal - 程序包 org.junit.experimental.theories.internal
- org.junit.experimental.theories.suppliers - 程序包 org.junit.experimental.theories.suppliers
- org.junit.internal - 程序包 org.junit.internal
- org.junit.matchers - 程序包 org.junit.matchers
- Provides useful additional
Matcher
s for use with theAssert.assertThat(Object, org.hamcrest.Matcher)
statement - org.junit.rules - 程序包 org.junit.rules
- org.junit.runner - 程序包 org.junit.runner
- Provides classes used to describe, collect, run and analyze multiple tests.
- org.junit.runner.manipulation - 程序包 org.junit.runner.manipulation
- org.junit.runner.notification - 程序包 org.junit.runner.notification
- Provides information about a test run.
- org.junit.runners - 程序包 org.junit.runners
- Provides standard
Runner
implementations. - org.junit.runners.model - 程序包 org.junit.runners.model
- org.junit.runners.parameterized - 程序包 org.junit.runners.parameterized
- org.junit.validator - 程序包 org.junit.validator
- out() - 接口 中的方法org.junit.internal.JUnitSystem
- out() - 类 中的方法org.junit.internal.RealSystem
- outerRule(TestRule) - 类 中的静态方法org.junit.rules.RuleChain
- Returns a
RuleChain
with a singleTestRule
.
P
- ParallelComputer - org.junit.experimental中的类
- ParallelComputer(boolean, boolean) - 类 的构造器org.junit.experimental.ParallelComputer
- Parameterized - org.junit.runners中的类
- The custom runner
Parameterized
implements parameterized tests. - Parameterized(Class<?>) - 类 的构造器org.junit.runners.Parameterized
- Only called reflectively.
- Parameterized.Parameter - org.junit.runners中的注释类型
- Annotation for fields of the test class which will be initialized by the method annotated by
Parameters
. - Parameterized.Parameters - org.junit.runners中的注释类型
- Annotation for a method which provides parameters to be injected into the test class constructor by
Parameterized
. - Parameterized.UseParametersRunnerFactory - org.junit.runners中的注释类型
- Add this annotation to your test class if you want to generate a special runner.
- ParameterizedAssertionError - org.junit.experimental.theories.internal中的错误
- ParameterizedAssertionError(Throwable, String, Object...) - 错误 的构造器org.junit.experimental.theories.internal.ParameterizedAssertionError
- ParameterSignature - org.junit.experimental.theories中的类
- ParametersRunnerFactory - org.junit.runners.parameterized中的接口
- A
ParameterizedRunnerFactory
creates a runner for a singleTestWithParameters
. - ParametersSuppliedBy - org.junit.experimental.theories中的注释类型
- Annotating a
Theory
method parameter with @ParametersSuppliedBy causes it to be supplied with values from the namedParameterSupplier
when run as a theory by theTheories
runner. - ParameterSupplier - org.junit.experimental.theories中的类
- Abstract parent class for suppliers of input data points for theories.
- ParameterSupplier() - 类 的构造器org.junit.experimental.theories.ParameterSupplier
- ParentRunner<T> - org.junit.runners中的类
- Provides most of the functionality specific to a Runner that implements a "parent node" in the test tree, with children defined by objects of some data type
T
. - ParentRunner(Class<?>) - 类 的构造器org.junit.runners.ParentRunner
- Constructs a new
ParentRunner
that will run@TestClass
- pleaseStop() - 类 中的方法org.junit.runner.notification.RunNotifier
- Ask that the tests run stop before starting the next test.
- possiblyExpectingExceptions(FrameworkMethod, Object, Statement) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Returns a
Statement
: ifmethod
's@Test
annotation has theexpecting
attribute, return normally only ifnext
throws an exception of the correct type, and throw an exception otherwise. - PotentialAssignment - org.junit.experimental.theories中的类
- PotentialAssignment() - 类 的构造器org.junit.experimental.theories.PotentialAssignment
- PotentialAssignment.CouldNotGenerateValueException - org.junit.experimental.theories中的异常错误
- potentialsForNextUnassigned() - 类 中的方法org.junit.experimental.theories.internal.Assignments
- PrintableResult - org.junit.experimental.results中的类
- A test result that prints nicely in error messages.
- PrintableResult(List<Failure>) - 类 的构造器org.junit.experimental.results.PrintableResult
- A result that includes the given
failures
- printFailure(Failure, String) - 类 中的方法org.junit.internal.TextListener
- printFailures(Result) - 类 中的方法org.junit.internal.TextListener
- printFooter(Result) - 类 中的方法org.junit.internal.TextListener
- printHeader(long) - 类 中的方法org.junit.internal.TextListener
- producesType(Type) - 类 中的方法org.junit.runners.model.FrameworkMethod
- 已过时。This is used only by the Theories runner, and does not use all the generic type info that it ought to. It will be replaced with a forthcoming ParameterSignature#canAcceptResultOf(FrameworkMethod) once Theories moves to junit-contrib.
- PublicClassValidator - org.junit.validator中的类
- Validates that a
TestClass
is public. - PublicClassValidator() - 类 的构造器org.junit.validator.PublicClassValidator
R
- RealSystem - org.junit.internal中的类
- RealSystem() - 类 的构造器org.junit.internal.RealSystem
- ReflectiveTypeFinder - org.hamcrest.internal中的类
- ReflectiveTypeFinder(String, int, int) - 类 的构造器org.hamcrest.internal.ReflectiveTypeFinder
- relationship() - 类 中的方法org.hamcrest.core.StringContains
- relationship() - 类 中的方法org.hamcrest.core.StringEndsWith
- relationship() - 类 中的方法org.hamcrest.core.StringStartsWith
- relationship() - 类 中的方法org.hamcrest.core.SubstringMatcher
- remove() - 类 中的方法org.hamcrest.internal.ArrayIterator
- remove() - 类 中的方法org.hamcrest.internal.SelfDescribingValueIterator
- removeListener(RunListener) - 类 中的方法org.junit.runner.JUnitCore
- Remove a listener.
- removeListener(RunListener) - 类 中的方法org.junit.runner.notification.RunNotifier
- Internal use only
- reportMissingExceptionWithMessage(String) - 类 中的方法org.junit.rules.ExpectedException
- Specifies the failure message for tests that are expected to throw an exception but do not throw any.
- reportParameterizedError(Throwable, Object...) - 类 中的方法org.junit.experimental.theories.Theories.TheoryAnchor
- Request - org.junit.runner中的类
- A
Request
is an abstract description of tests to be run. - Request() - 类 的构造器org.junit.runner.Request
- Result - org.junit.runner中的类
- A
Result
collects and summarizes information from running multiple tests. - Result() - 类 的构造器org.junit.runner.Result
- ResultMatchers - org.junit.experimental.results中的类
- Matchers on a PrintableResult, to enable JUnit self-tests.
- ResultMatchers() - 类 的构造器org.junit.experimental.results.ResultMatchers
- rethrowAsException(Throwable) - 类 中的静态方法org.junit.internal.Throwables
- Rethrows the given
Throwable
, allowing the caller to declare that it throwsException
. - Rule - org.junit中的注释类型
- Annotates fields that reference rules or methods that return a rule.
- RuleChain - org.junit.rules中的类
- The RuleChain rule allows ordering of TestRules.
- rules(Object) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- run(Class<?>) - 类 中的方法org.junit.experimental.max.MaxCore
- Run all the tests in
class
. - run(Class<?>...) - 类 中的方法org.junit.runner.JUnitCore
- Run all the tests in
classes
. - run(Test) - 类 中的方法org.junit.runner.JUnitCore
- Run all the tests contained in JUnit 3.8.x
test
. - run(Computer, Class<?>...) - 类 中的方法org.junit.runner.JUnitCore
- Run all the tests in
classes
. - run(RunNotifier) - 类 中的方法org.junit.runner.Runner
- Run the tests for this runner.
- run(RunNotifier) - 类 中的方法org.junit.runners.ParentRunner
- run(Request) - 类 中的方法org.junit.experimental.max.MaxCore
- Run all the tests contained in
request
. - run(Request) - 类 中的方法org.junit.runner.JUnitCore
- Run all the tests contained in
request
. - run(Request, JUnitCore) - 类 中的方法org.junit.experimental.max.MaxCore
- Run all the tests contained in
request
. - run(Runner) - 类 中的方法org.junit.runner.JUnitCore
- Do not use.
- runChild(Runner, RunNotifier) - 类 中的方法org.junit.runners.Suite
- runChild(FrameworkMethod, RunNotifier) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- runChild(T, RunNotifier) - 类 中的方法org.junit.runners.ParentRunner
- Runs the test corresponding to
child
, which can be assumed to be an element of the list returned byParentRunner.getChildren()
. - runClasses(Class<?>...) - 类 中的静态方法org.junit.runner.JUnitCore
- Run the tests contained in
classes
. - runClasses(Computer, Class<?>...) - 类 中的静态方法org.junit.runner.JUnitCore
- Run the tests contained in
classes
. - runLeaf(Statement, Description, RunNotifier) - 类 中的方法org.junit.runners.ParentRunner
- Runs a
Statement
that represents a leaf (aka atomic) test. - RunListener - org.junit.runner.notification中的类
- Register an instance of this class with
RunNotifier
to be notified of events that occur during a test run. - RunListener() - 类 的构造器org.junit.runner.notification.RunListener
- RunListener.ThreadSafe - org.junit.runner.notification中的注释类型
- Indicates a
RunListener
that can have its methods called concurrently. - runner(Runner) - 类 中的静态方法org.junit.runner.Request
- Runner - org.junit.runner中的类
- A
Runner
runs tests and notifies aRunNotifier
of significant events as it does so. - Runner() - 类 的构造器org.junit.runner.Runner
- RunnerBuilder - org.junit.runners.model中的类
- A RunnerBuilder is a strategy for constructing runners for classes.
- RunnerBuilder() - 类 的构造器org.junit.runners.model.RunnerBuilder
- runnerForClass(Class<?>) - 类 中的方法org.junit.runners.model.RunnerBuilder
- Override to calculate the correct runner for a test class at runtime.
- runners(Class<?>, Class<?>[]) - 类 中的方法org.junit.runners.model.RunnerBuilder
- Constructs and returns a list of Runners, one for each child class in
children
. - runners(Class<?>, List<Class<?>>) - 类 中的方法org.junit.runners.model.RunnerBuilder
- RunnerScheduler - org.junit.runners.model中的接口
- Represents a strategy for scheduling when individual test methods should be run (in serial or parallel) WARNING: still experimental, may go away.
- RunNotifier - org.junit.runner.notification中的类
- If you write custom runners, you may need to notify JUnit of your progress running tests.
- RunNotifier() - 类 的构造器org.junit.runner.notification.RunNotifier
- RunRules - org.junit.rules中的类
- Runs a collection of rules on a statement.
- RunRules(Statement, Iterable<TestRule>, Description) - 类 的构造器org.junit.rules.RunRules
- runtime(TimeUnit) - 类 中的方法org.junit.rules.Stopwatch
- Gets the runtime for the test.
- RunWith - org.junit.runner中的注释类型
- When a class is annotated with
@RunWith
or extends a class annotated with@RunWith
, JUnit will invoke the class it references to run the tests in that class instead of the runner built into JUnit. - runWithAssignment(Assignments) - 类 中的方法org.junit.experimental.theories.Theories.TheoryAnchor
- runWithCompleteAssignment(Assignments) - 类 中的方法org.junit.experimental.theories.Theories.TheoryAnchor
- runWithIncompleteAssignment(Assignments) - 类 中的方法org.junit.experimental.theories.Theories.TheoryAnchor
S
- safeRunnerForClass(Class<?>) - 类 中的方法org.junit.runners.model.RunnerBuilder
- Always returns a runner, even if it is just one that prints an error instead of running tests.
- sameInstance(T) - 类 中的静态方法org.hamcrest.core.IsSame
- Creates a matcher that matches only when the examined object is the same instance as the specified target object.
- sameInstance(T) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches only when the examined object is the same instance as the specified target object.
- scanAnnotatedMembers(Map<Class<? extends Annotation>, List<FrameworkMethod>>, Map<Class<? extends Annotation>, List<FrameworkField>>) - 类 中的方法org.junit.runners.model.TestClass
- schedule(Runnable) - 接口 中的方法org.junit.runners.model.RunnerScheduler
- Schedule a child statement to run
- seconds(long) - 类 中的静态方法org.junit.rules.Timeout
- Creates a
Timeout
that will timeout a test after the given duration, in seconds. - SelfDescribing - org.hamcrest中的接口
- The ability of an object to describe itself.
- SelfDescribingValue<T> - org.hamcrest.internal中的类
- SelfDescribingValue(T) - 类 的构造器org.hamcrest.internal.SelfDescribingValue
- SelfDescribingValueIterator<T> - org.hamcrest.internal中的类
- SelfDescribingValueIterator(Iterator<T>) - 类 的构造器org.hamcrest.internal.SelfDescribingValueIterator
- serial() - 类 中的静态方法org.junit.runner.Computer
- Returns a new default computer, which runs tests in serial order
- setScheduler(RunnerScheduler) - 类 中的方法org.junit.runners.ParentRunner
- Sets a scheduler that determines the order and parallelization of children.
- shouldRun(Description) - 类 中的方法org.junit.experimental.categories.Categories.CategoryFilter
- shouldRun(Description) - 类 中的方法org.junit.runner.manipulation.Filter
- signatures(Constructor<?>) - 类 中的静态方法org.junit.experimental.theories.ParameterSignature
- signatures(Method) - 类 中的静态方法org.junit.experimental.theories.ParameterSignature
- skipped(long, AssumptionViolatedException, Description) - 类 中的方法org.junit.rules.Stopwatch
- Invoked when a test is skipped due to a failed assumption.
- skipped(AssumptionViolatedException, Description) - 类 中的方法org.junit.rules.TestWatcher
- Invoked when a test is skipped due to a failed assumption.
- skipped(AssumptionViolatedException, Description) - 类 中的方法org.junit.rules.TestWatcher
- sort(Sorter) - 接口 中的方法org.junit.runner.manipulation.Sortable
- Sorts the tests using
sorter
- sort(Sorter) - 类 中的方法org.junit.runners.ParentRunner
- Sortable - org.junit.runner.manipulation中的接口
- Interface for runners that allow sorting of tests.
- sortedLeavesForTest(Request) - 类 中的方法org.junit.experimental.max.MaxCore
- Sorter - org.junit.runner.manipulation中的类
- A
Sorter
orders tests. - Sorter(Comparator<Description>) - 类 的构造器org.junit.runner.manipulation.Sorter
- Creates a
Sorter
that usescomparator
to sort tests - sortRequest(Request) - 类 中的方法org.junit.experimental.max.MaxCore
- sortWith(Comparator<Description>) - 类 中的方法org.junit.runner.Request
- Returns a Request whose Tests can be run in a certain order, defined by
comparator
- SpecificDataPointsSupplier - org.junit.experimental.theories.internal中的类
- SpecificDataPointsSupplier(TestClass) - 类 的构造器org.junit.experimental.theories.internal.SpecificDataPointsSupplier
- starting(Description) - 类 中的方法org.junit.rules.TestName
- starting(Description) - 类 中的方法org.junit.rules.TestWatcher
- Invoked when a test is about to start
- starting(FrameworkMethod) - 类 中的方法org.junit.rules.TestWatchman
- 已过时。Invoked when a test method is about to start
- startsWith(String) - 类 中的静态方法org.hamcrest.core.StringStartsWith
- startsWith(String) - 类 中的静态方法org.hamcrest.CoreMatchers
- Statement - org.junit.runners.model中的类
- Represents one or more actions to be taken at runtime in the course of running a JUnit test suite.
- Statement() - 类 的构造器org.junit.runners.model.Statement
- StoppedByUserException - org.junit.runner.notification中的异常错误
- Thrown when a user has requested that the test run stop.
- StoppedByUserException() - 异常错误 的构造器org.junit.runner.notification.StoppedByUserException
- Stopwatch - org.junit.rules中的类
- The Stopwatch Rule notifies one of its own protected methods of the time spent by a test.
- Stopwatch() - 类 的构造器org.junit.rules.Stopwatch
- storedLocally(File) - 类 中的静态方法org.junit.experimental.max.MaxCore
- Create a new MaxCore from a serialized file stored at storedResults
- StringContains - org.hamcrest.core中的类
- Tests if the argument is a string that contains a substring.
- StringContains(String) - 类 的构造器org.hamcrest.core.StringContains
- StringDescription - org.hamcrest中的类
- A
Description
that is stored as a string. - StringDescription() - 类 的构造器org.hamcrest.StringDescription
- StringDescription(Appendable) - 类 的构造器org.hamcrest.StringDescription
- StringEndsWith - org.hamcrest.core中的类
- Tests if the argument is a string that contains a substring.
- StringEndsWith(String) - 类 的构造器org.hamcrest.core.StringEndsWith
- StringStartsWith - org.hamcrest.core中的类
- Tests if the argument is a string that contains a substring.
- StringStartsWith(String) - 类 的构造器org.hamcrest.core.StringStartsWith
- substring - 类 中的变量org.hamcrest.core.SubstringMatcher
- SubstringMatcher - org.hamcrest.core中的类
- SubstringMatcher(String) - 类 的构造器org.hamcrest.core.SubstringMatcher
- succeeded(long, Description) - 类 中的方法org.junit.rules.Stopwatch
- Invoked when a test succeeds
- succeeded(Description) - 类 中的方法org.junit.rules.TestWatcher
- Invoked when a test succeeds
- succeeded(FrameworkMethod) - 类 中的方法org.junit.rules.TestWatchman
- 已过时。Invoked when a test method succeeds
- Suite - org.junit.runners中的类
- Using
Suite
as a runner allows you to manually build a suite containing tests from many classes. - Suite(Class<?>, Class<?>[]) - 类 的构造器org.junit.runners.Suite
- Call this when the default builder is good enough.
- Suite(Class<?>, List<Runner>) - 类 的构造器org.junit.runners.Suite
- Called by this class and subclasses once the runners making up the suite have been determined
- Suite(Class<?>, RunnerBuilder) - 类 的构造器org.junit.runners.Suite
- Called reflectively on classes annotated with
@RunWith(Suite.class)
- Suite(RunnerBuilder, Class<?>[]) - 类 的构造器org.junit.runners.Suite
- Call this when there is no single root class (for example, multiple class names passed on the command line to
JUnitCore
- Suite(RunnerBuilder, Class<?>, Class<?>[]) - 类 的构造器org.junit.runners.Suite
- Called by this class and subclasses once the classes making up the suite have been determined
- Suite.SuiteClasses - org.junit.runners中的注释类型
- The
SuiteClasses
annotation specifies the classes to be run when a class annotated with@RunWith(Suite.class)
is run.
T
- TemporaryFolder - org.junit.rules中的类
- The TemporaryFolder Rule allows creation of files and folders that should be deleted when the test method finishes (whether it passes or fails).
- TemporaryFolder() - 类 的构造器org.junit.rules.TemporaryFolder
- TemporaryFolder(File) - 类 的构造器org.junit.rules.TemporaryFolder
- Test - org.junit中的注释类型
- The
Test
annotation tells JUnit that thepublic void
method to which it is attached can be run as a test case. - TEST_MECHANISM - 类 中的静态变量org.junit.runner.Description
- Describes a step in the test-running mechanism that goes so wrong no other description can be used (for example, an exception thrown from a Runner's constructor
- Test.None - org.junit中的类
- Default empty exception
- testAssumptionFailure(Failure) - 类 中的方法org.junit.runner.notification.RunListener
- Called when an atomic test flags that it assumes a condition that is false
- TestClass - org.junit.runners.model中的类
- Wraps a class to be run, providing method validation and annotation searching
- TestClass(Class<?>) - 类 的构造器org.junit.runners.model.TestClass
- Creates a
TestClass
wrappingclazz
. - TestClassValidator - org.junit.validator中的接口
- Validates a single facet of a test class.
- testComparator() - 类 中的方法org.junit.experimental.max.MaxHistory
- testCount() - 类 中的方法org.junit.runner.Description
- testCount() - 类 中的方法org.junit.runner.Runner
- TestedOn - org.junit.experimental.theories.suppliers中的注释类型
- TestedOnSupplier - org.junit.experimental.theories.suppliers中的类
- TestedOnSupplier() - 类 的构造器org.junit.experimental.theories.suppliers.TestedOnSupplier
- testFailure(Failure) - 类 中的方法org.junit.internal.TextListener
- testFailure(Failure) - 类 中的方法org.junit.runner.notification.RunListener
- Called when an atomic test fails, or when a listener throws an exception.
- testFinished(Description) - 类 中的方法org.junit.runner.notification.RunListener
- Called when an atomic test has finished, whether the test succeeds or fails.
- testIgnored(Description) - 类 中的方法org.junit.internal.TextListener
- testIgnored(Description) - 类 中的方法org.junit.runner.notification.RunListener
- Called when a test will not be run, generally because a test method is annotated with
Ignore
. - testName(FrameworkMethod) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Returns the name that describes
method
forDescription
s. - testName(FrameworkMethod) - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- TestName - org.junit.rules中的类
- The TestName Rule makes the current test name available inside test methods:
- TestName() - 类 的构造器org.junit.rules.TestName
- testResult(Class<?>) - 类 中的静态方法org.junit.experimental.results.PrintableResult
- The result of running JUnit on
type
- testResult(Request) - 类 中的静态方法org.junit.experimental.results.PrintableResult
- The result of running JUnit on Request
request
- TestRule - org.junit.rules中的接口
- A TestRule is an alteration in how a test method, or set of test methods, is run and reported.
- testRunFinished(Result) - 类 中的方法org.junit.internal.TextListener
- testRunFinished(Result) - 类 中的方法org.junit.runner.notification.RunListener
- Called when all tests have finished.
- testRunStarted(Description) - 类 中的方法org.junit.runner.notification.RunListener
- Called before any tests have been run.
- testStarted(Description) - 类 中的方法org.junit.internal.TextListener
- testStarted(Description) - 类 中的方法org.junit.runner.notification.RunListener
- Called when an atomic test is about to be started.
- TestTimedOutException - org.junit.runners.model中的异常错误
- Exception thrown when a test fails on timeout.
- TestTimedOutException(long, TimeUnit) - 异常错误 的构造器org.junit.runners.model.TestTimedOutException
- Creates exception with a standard message "test timed out after [timeout] [timeUnit]"
- TestWatcher - org.junit.rules中的类
- TestWatcher is a base class for Rules that take note of the testing action, without modifying it.
- TestWatcher() - 类 的构造器org.junit.rules.TestWatcher
- TestWatchman - org.junit.rules中的类
- 已过时。Use
TestWatcher
(which implementsTestRule
) instead. - TestWatchman() - 类 的构造器org.junit.rules.TestWatchman
- 已过时。
- TestWithParameters - org.junit.runners.parameterized中的类
- A
TestWithParameters
keeps the data together that are needed for creating a runner for a single data set of a parameterized test. - TestWithParameters(String, TestClass, List<Object>) - 类 的构造器org.junit.runners.parameterized.TestWithParameters
- TextListener - org.junit.internal中的类
- TextListener(PrintStream) - 类 的构造器org.junit.internal.TextListener
- TextListener(JUnitSystem) - 类 的构造器org.junit.internal.TextListener
- theInstance(T) - 类 中的静态方法org.hamcrest.core.IsSame
- Creates a matcher that matches only when the examined object is the same instance as the specified target object.
- theInstance(T) - 类 中的静态方法org.hamcrest.CoreMatchers
- Creates a matcher that matches only when the examined object is the same instance as the specified target object.
- then(Condition.Step<? super T, U>) - 类 中的方法org.hamcrest.Condition
- Theories - org.junit.experimental.theories中的类
- The Theories runner allows to test a certain functionality against a subset of an infinite set of data points.
- Theories(Class<?>) - 类 的构造器org.junit.experimental.theories.Theories
- Theories.TheoryAnchor - org.junit.experimental.theories中的类
- Theory - org.junit.experimental.theories中的注释类型
- Marks test methods that should be read as theories by the
Theories
runner. - TheoryAnchor(FrameworkMethod, TestClass) - 类 的构造器org.junit.experimental.theories.Theories.TheoryAnchor
- Throwables - org.junit.internal中的类
- Miscellaneous functions dealing with
Throwable
. - timeout() - 注释类型 中的方法org.junit.Test
- Optionally specify
timeout
in milliseconds to cause a test method to fail if it takes longer than that number of milliseconds. - Timeout - org.junit.rules中的类
- The Timeout Rule applies the same timeout to all test methods in a class:
- Timeout(int) - 类 的构造器org.junit.rules.Timeout
- 已过时。
- Timeout(long, TimeUnit) - 类 的构造器org.junit.rules.Timeout
- Create a
Timeout
instance with the timeout specified at the timeUnit of granularity of the providedTimeUnit
. - Timeout(Timeout.Builder) - 类 的构造器org.junit.rules.Timeout
- Create a
Timeout
instance initialized with values form a builder. - Timeout.Builder - org.junit.rules中的类
- Builder for
Timeout
. - toString() - 类 中的方法org.hamcrest.BaseMatcher
- toString() - 类 中的方法org.hamcrest.Description.NullDescription
- toString() - 类 中的方法org.hamcrest.StringDescription
- Returns the description as a string.
- toString() - 类 中的方法org.junit.experimental.categories.Categories.CategoryFilter
- Returns string in the form "[included categories] - [excluded categories]", where both sets have comma separated names of categories.
- toString() - 类 中的方法org.junit.experimental.results.PrintableResult
- toString() - 错误 中的方法org.junit.internal.ArrayComparisonFailure
- toString() - 类 中的方法org.junit.runner.Description
- toString() - 类 中的方法org.junit.runner.notification.Failure
- toString() - 类 中的方法org.junit.runners.model.FrameworkField
- toString() - 类 中的方法org.junit.runners.model.FrameworkMethod
- toString() - 类 中的方法org.junit.runners.parameterized.TestWithParameters
- toString(SelfDescribing) - 类 中的静态方法org.hamcrest.StringDescription
- Return the description of a
SelfDescribing
object as a String. - TypeSafeDiagnosingMatcher<T> - org.hamcrest中的类
- Convenient base class for Matchers that require a non-null value of a specific type and that will report why the received value has been rejected.
- TypeSafeDiagnosingMatcher() - 类 的构造器org.hamcrest.TypeSafeDiagnosingMatcher
- The default constructor for simple sub types
- TypeSafeDiagnosingMatcher(Class<?>) - 类 的构造器org.hamcrest.TypeSafeDiagnosingMatcher
- Use this constructor if the subclass that implements
matchesSafely
is not the class that binds <T> to a type. - TypeSafeDiagnosingMatcher(ReflectiveTypeFinder) - 类 的构造器org.hamcrest.TypeSafeDiagnosingMatcher
- Use this constructor if the subclass that implements
matchesSafely
is not the class that binds <T> to a type. - TypeSafeMatcher<T> - org.hamcrest中的类
- Convenient base class for Matchers that require a non-null value of a specific type.
- TypeSafeMatcher() - 类 的构造器org.hamcrest.TypeSafeMatcher
- The default constructor for simple sub types
- TypeSafeMatcher(Class<?>) - 类 的构造器org.hamcrest.TypeSafeMatcher
- Use this constructor if the subclass that implements
matchesSafely
is not the class that binds <T> to a type. - TypeSafeMatcher(ReflectiveTypeFinder) - 类 的构造器org.hamcrest.TypeSafeMatcher
- Use this constructor if the subclass that implements
matchesSafely
is not the class that binds <T> to a type.
V
- validateAnnotatedClass(TestClass) - 类 中的方法org.junit.validator.AnnotationValidator
- Validates annotation on the given class.
- validateAnnotatedField(FrameworkField) - 类 中的方法org.junit.validator.AnnotationValidator
- Validates annotation on the given field.
- validateAnnotatedMethod(FrameworkMethod) - 类 中的方法org.junit.experimental.categories.CategoryValidator
- Adds to
errors
a throwable for each problem detected. - validateAnnotatedMethod(FrameworkMethod) - 类 中的方法org.junit.validator.AnnotationValidator
- Validates annotation on the given method.
- validateConstructor(List<Throwable>) - 类 中的方法org.junit.experimental.theories.Theories
- validateConstructor(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Adds to
errors
if the test class has more than one constructor, or if the constructor takes parameters. - validateConstructor(List<Throwable>) - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- validateFields(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- validateFields(List<Throwable>) - 类 中的方法org.junit.runners.parameterized.BlockJUnit4ClassRunnerWithParameters
- validateInstanceMethods(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- 已过时。
- validateNoNonStaticInnerClass(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- validateNoTypeParametersOnArgs(List<Throwable>) - 类 中的方法org.junit.runners.model.FrameworkMethod
- validateOnlyOneConstructor(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Adds to
errors
if the test class has more than one constructor (do not override) - validatePublicVoid(boolean, List<Throwable>) - 类 中的方法org.junit.runners.model.FrameworkMethod
- Adds to
errors
if this method: is not public, or returns something other than void, or is static (givenisStatic is false
), or is not static (givenisStatic is true
). - validatePublicVoidNoArg(boolean, List<Throwable>) - 类 中的方法org.junit.runners.model.FrameworkMethod
- Adds to
errors
if this method: is not public, or takes parameters, or returns something other than void, or is static (givenisStatic is false
), or is not static (givenisStatic is true
). - validatePublicVoidNoArgMethods(Class<? extends Annotation>, boolean, List<Throwable>) - 类 中的方法org.junit.runners.ParentRunner
- Adds to
errors
if any method in this class is annotated withannotation
, but: is not public, or takes parameters, or returns something other than void, or is static (givenisStatic is false
), or is not static (givenisStatic is true
). - validateTestClass(TestClass) - 类 中的方法org.junit.validator.AnnotationsValidator
- Validate all annotations of the specified test class that are be annotated with
ValidateWith
. - validateTestClass(TestClass) - 类 中的方法org.junit.validator.PublicClassValidator
- Validate that the specified
TestClass
is public. - validateTestClass(TestClass) - 接口 中的方法org.junit.validator.TestClassValidator
- Validate a single facet of a test class.
- validateTestMethods(List<Throwable>) - 类 中的方法org.junit.experimental.theories.Theories
- validateTestMethods(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Adds to
errors
for each method annotated with@Test
that is not a public, void instance method with no arguments. - ValidateWith - org.junit.validator中的注释类型
- Allows for an
AnnotationValidator
to be attached to an annotation. - validateZeroArgConstructor(List<Throwable>) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Adds to
errors
if the test class's single constructor takes parameters (do not override) - value() - 注释类型 中的方法org.junit.experimental.categories.Categories.ExcludeCategory
- Determines the tests which do not run if they are annotated with categories specified in the value of this annotation or their subtypes regardless of being included in
Categories.IncludeCategory.value()
. - value() - 注释类型 中的方法org.junit.experimental.categories.Categories.IncludeCategory
- Determines the tests to run that are annotated with categories specified in the value of this annotation or their subtypes unless excluded with
Categories.ExcludeCategory
. - value() - 注释类型 中的方法org.junit.experimental.categories.Category
- value() - 注释类型 中的方法org.junit.experimental.theories.DataPoint
- value() - 注释类型 中的方法org.junit.experimental.theories.DataPoints
- value() - 注释类型 中的方法org.junit.experimental.theories.FromDataPoints
- value() - 注释类型 中的方法org.junit.experimental.theories.ParametersSuppliedBy
- value() - 注释类型 中的方法org.junit.FixMethodOrder
- Optionally specify
value
to have the methods executed in a particular order - value() - 注释类型 中的方法org.junit.Ignore
- The optional reason why the test is ignored.
- value() - 注释类型 中的方法org.junit.runner.RunWith
- value() - 注释类型 中的方法org.junit.runners.Parameterized.Parameter
- Method that returns the index of the parameter in the array returned by the method annotated by
Parameters
. - value() - 注释类型 中的方法org.junit.runners.Parameterized.UseParametersRunnerFactory
- value() - 注释类型 中的方法org.junit.runners.Suite.SuiteClasses
- value() - 注释类型 中的方法org.junit.validator.ValidateWith
- valueOf(String) - 枚举 中的静态方法org.junit.runners.MethodSorters
- 返回带有指定名称的该类型的枚举常量。
- values() - 枚举 中的静态方法org.junit.runners.MethodSorters
- 按照声明该枚举类型的常量的顺序, 返回 包含这些常量的数组。
- Verifier - org.junit.rules中的类
- Verifier is a base class for Rules like ErrorCollector, which can turn otherwise passing test methods into failing tests if a verification check is failed
- Verifier() - 类 的构造器org.junit.rules.Verifier
- verify() - 类 中的方法org.junit.rules.ErrorCollector
- verify() - 类 中的方法org.junit.rules.Verifier
- Override this to add verification logic.
W
- wasSuccessful() - 类 中的方法org.junit.runner.Result
- withAfterClasses(Statement) - 类 中的方法org.junit.runners.ParentRunner
- Returns a
Statement
: run all non-overridden@AfterClass
methods on this class and superclasses before executingstatement
; all AfterClass methods are always executed: exceptions thrown by previous steps are combined, if necessary, with exceptions from AfterClass methods into aMultipleFailureException
. - withAfters(FrameworkMethod, Object, Statement) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Returns a
Statement
: run all non-overridden@After
methods on this class and superclasses before runningnext
; all After methods are always executed: exceptions thrown by previous steps are combined, if necessary, with exceptions from After methods into aMultipleFailureException
. - withBeforeClasses(Statement) - 类 中的方法org.junit.runners.ParentRunner
- Returns a
Statement
: run all non-overridden@BeforeClass
methods on this class and superclasses before executingstatement
; if any throws an Exception, stop execution and pass the exception on. - withBefores(FrameworkMethod, Object, Statement) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- Returns a
Statement
: run all non-overridden@Before
methods on this class and superclasses before runningnext
; if any throws an Exception, stop execution and pass the exception on. - withLookingForStuckThread(boolean) - 类 中的方法org.junit.rules.Timeout.Builder
- Specifies whether to look for a stuck thread.
- withPotentialTimeout(FrameworkMethod, Object, Statement) - 类 中的方法org.junit.runners.BlockJUnit4ClassRunner
- 已过时。
- withTimeout(long, TimeUnit) - 类 中的方法org.junit.rules.Timeout.Builder
- Specifies the time to wait before timing out the test.
_
- _dont_implement_Matcher___instead_extend_BaseMatcher_() - 类 中的方法org.hamcrest.BaseMatcher
- 已过时。
- _dont_implement_Matcher___instead_extend_BaseMatcher_() - 接口 中的方法org.hamcrest.Matcher
- 已过时。to make
所有类 所有程序包