A B C D E F G H I J M N O P R S T V W

A

aClass(Class<?>) - Static method in class org.junit.runner.Request
Create a Request that, when processed, will run all the tests in a class.
addChild(Description) - Method in class org.junit.runner.Description
Add Description as a child of the receiver.
addFirstListener(RunListener) - Method in class org.junit.runner.notification.RunNotifier
Internal use only.
addListener(RunListener) - Method in class org.junit.runner.JUnitCore
Add a listener to be notified as the tests run.
addListener(RunListener) - Method in class org.junit.runner.notification.RunNotifier
Internal use only
After - Annotation Type in org.junit
If you allocate external resources in a Before method you need to release them after the test runs.
AfterClass - Annotation Type in 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 - Static variable in class org.junit.runner.manipulation.Filter
A null Filter that passes all tests through.
AllTests - Class in org.junit.runners
Runner for use with JUnit 3.8.x-style AllTests classes (those that only implement a static suite() method).
AllTests(Class<?>) - Constructor for class org.junit.runners.AllTests
 
apply(Runner) - Method in class 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(Runner) - Method in class org.junit.runner.manipulation.Sorter
Sorts the test in runner using comparator
Assert - Class in org.junit
A set of assertion methods useful for writing tests.
Assert() - Constructor for class org.junit.Assert
Protect constructor since it is a static only class
assertEquals(String, Object, Object) - Static method in class org.junit.Assert
Asserts that two objects are equal.
assertEquals(Object, Object) - Static method in class org.junit.Assert
Asserts that two objects are equal.
assertEquals(String, Object[], Object[]) - Static method in class org.junit.Assert
Asserts that two object arrays are equal.
assertEquals(Object[], Object[]) - Static method in class org.junit.Assert
Asserts that two object arrays are equal.
assertEquals(String, double, double, double) - Static method in class org.junit.Assert
Asserts that two doubles are equal to within a positive delta.
assertEquals(double, double, double) - Static method in class org.junit.Assert
Asserts that two doubles are equal to within a positive delta.
assertEquals(String, float, float, float) - Static method in class org.junit.Assert
Asserts that two floats are equal to within a positive delta.
assertEquals(float, float, float) - Static method in class org.junit.Assert
Asserts that two floats are equal to within a positive delta.
assertFalse(String, boolean) - Static method in class org.junit.Assert
Asserts that a condition is false.
assertFalse(boolean) - Static method in class org.junit.Assert
Asserts that a condition is false.
assertNotNull(String, Object) - Static method in class org.junit.Assert
Asserts that an object isn't null.
assertNotNull(Object) - Static method in class org.junit.Assert
Asserts that an object isn't null.
assertNotSame(String, Object, Object) - Static method in class org.junit.Assert
Asserts that two objects do not refer to the same object.
assertNotSame(Object, Object) - Static method in class org.junit.Assert
Asserts that two objects do not refer to the same object.
assertNull(String, Object) - Static method in class org.junit.Assert
Asserts that an object is null.
assertNull(Object) - Static method in class org.junit.Assert
Asserts that an object is null.
assertSame(String, Object, Object) - Static method in class org.junit.Assert
Asserts that two objects refer to the same object.
assertSame(Object, Object) - Static method in class org.junit.Assert
Asserts that two objects refer to the same object.
assertTrue(String, boolean) - Static method in class org.junit.Assert
Asserts that a condition is true.
assertTrue(boolean) - Static method in class org.junit.Assert
Asserts that a condition is true.

B

Before - Annotation Type in org.junit
When writing tests, it is common to find that several tests need similar objects created before they can run.
BeforeClass - Annotation Type in org.junit
Sometimes several tests need to share computationally expensive setup (like logging into a database).

C

classes(String, Class<?>...) - Static method in class org.junit.runner.Request
Create a Request that, when processed, will run all the tests in a set of classes.
compare(Description, Description) - Method in class org.junit.runner.manipulation.Sorter
 
ComparisonFailure - Error in org.junit
Thrown when an assertEquals(String, String) fails.
ComparisonFailure(String, String, String) - Constructor for error org.junit.ComparisonFailure
Constructs a comparison failure.
createListener() - Method in class org.junit.runner.Result
Internal use only.
createSuiteDescription(String) - Static method in class org.junit.runner.Description
Create a Description named name.
createSuiteDescription(Class<?>) - Static method in class org.junit.runner.Description
Create a generic Description that says there are tests in testClass.
createTestDescription(Class<?>, String) - Static method in class org.junit.runner.Description
Create a Description of a single test named name in the class clazz.

D

describe() - Method in class org.junit.runner.manipulation.Filter
Returns a textual description of this Filter
Description - Class in org.junit.runner
A Description describes a test which is to be run or has been run.
Description(String) - Constructor for class org.junit.runner.Description
 

E

eachOne(Object...) - Static method in class org.junit.runners.Parameterized
 
Enclosed - Class in org.junit.runners
 
Enclosed(Class<?>) - Constructor for class org.junit.runners.Enclosed
 
equals(Object) - Method in class org.junit.runner.Description
 
errorReport(Class<?>, Throwable) - Static method in class org.junit.runner.Request
 

F

fail(String) - Static method in class org.junit.Assert
Fails a test with the given message.
fail() - Static method in class org.junit.Assert
Fails a test with no message.
Failure - Class in 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) - Constructor for class org.junit.runner.notification.Failure
Constructs a Failure with the given description and exception.
Filter - Class in org.junit.runner.manipulation
The canonical case of filtering is when you want to run a single test method in a class.
Filter() - Constructor for class org.junit.runner.manipulation.Filter
 
filter(Filter) - Method in interface org.junit.runner.manipulation.Filterable
Remove tests that don't pass the parameter filter.
Filterable - Interface in org.junit.runner.manipulation
Runners that allow filtering should implement this interface.
filterWith(Filter) - Method in class org.junit.runner.Request
Returns a Request that only contains those tests that should run when filter is applied
filterWith(Description) - Method in class org.junit.runner.Request
Returns a Request that only runs contains tests whose Description equals desiredDescription
fireTestFailure(Failure) - Method in class org.junit.runner.notification.RunNotifier
Invoke to tell listeners that an atomic test failed.
fireTestFinished(Description) - Method in class org.junit.runner.notification.RunNotifier
Invoke to tell listeners that an atomic test finished.
fireTestIgnored(Description) - Method in class org.junit.runner.notification.RunNotifier
Invoke to tell listeners that an atomic test was ignored.
fireTestRunFinished(Result) - Method in class org.junit.runner.notification.RunNotifier
Do not invoke.
fireTestRunStarted(Description) - Method in class org.junit.runner.notification.RunNotifier
Do not invoke.
fireTestStarted(Description) - Method in class org.junit.runner.notification.RunNotifier
Invoke to tell listeners that an atomic test is about to start.

G

getActual() - Method in error org.junit.ComparisonFailure
Returns the actual string value
getChildren() - Method in class org.junit.runner.Description
 
getDescription() - Method in class org.junit.runner.notification.Failure
 
getDescription() - Method in class org.junit.runner.Runner
 
getDisplayName() - Method in class org.junit.runner.Description
 
getException() - Method in class org.junit.runner.notification.Failure
 
getExpected() - Method in error org.junit.ComparisonFailure
Returns the expected string value
getFailureCount() - Method in class org.junit.runner.Result
 
getFailures() - Method in class org.junit.runner.Result
 
getIgnoreCount() - Method in class org.junit.runner.Result
 
getMessage() - Method in error org.junit.ComparisonFailure
Returns "..." in place of common prefix and "..." in place of common suffix between expected and actual.
getMessage() - Method in class org.junit.runner.notification.Failure
Convenience method
getRunCount() - Method in class org.junit.runner.Result
 
getRunner() - Method in class org.junit.runner.Request
Returns a Runner for this Request
getRunTime() - Method in class org.junit.runner.Result
 
getTestHeader() - Method in class org.junit.runner.notification.Failure
 
getTrace() - Method in class org.junit.runner.notification.Failure
Convenience method
getVersion() - Method in class org.junit.runner.JUnitCore
 

H

hashCode() - Method in class org.junit.runner.Description
 

I

Ignore - Annotation Type in org.junit
Sometimes you want to temporarily disable a test.
isSuite() - Method in class org.junit.runner.Description
 
isTest() - Method in class org.junit.runner.Description
 

J

JUnitCore - Class in org.junit.runner
JUnitCore is a facade for running tests.
JUnitCore() - Constructor for class org.junit.runner.JUnitCore
Create a new JUnitCore to run tests.

M

main(String...) - Static method in class org.junit.runner.JUnitCore
Run the tests contained in the classes named in the args.
method(Class<?>, String) - Static method in class org.junit.runner.Request
Create a Request that, when processed, will run a single test.

N

NoTestsRemainException - Exception in org.junit.runner.manipulation
Thrown when a filter removes all tests from a runner.
NoTestsRemainException() - Constructor for exception org.junit.runner.manipulation.NoTestsRemainException
 

O

org.junit - package org.junit
Provides JUnit core classes and annotations.
org.junit.runner - package org.junit.runner
Provides classes used to describe, collect, run and analyze multiple tests.
org.junit.runner.manipulation - package org.junit.runner.manipulation
Provides classes to filter or sort tests.
org.junit.runner.notification - package org.junit.runner.notification
Provides information about a test run.
org.junit.runners - package org.junit.runners
Provides standard Runner implementations.

P

Parameterized - Class in org.junit.runners
The custom runner Parameterized implements parameterized tests.
Parameterized(Class<?>) - Constructor for class org.junit.runners.Parameterized
 
Parameterized.Parameters - Annotation Type in org.junit.runners
 
Parameterized.RunAllParameterMethods - Class in org.junit.runners
 
Parameterized.RunAllParameterMethods(Class<?>) - Constructor for class org.junit.runners.Parameterized.RunAllParameterMethods
 
pleaseStop() - Method in class org.junit.runner.notification.RunNotifier
Ask that the tests run stop before starting the next test.

R

removeListener(RunListener) - Method in class org.junit.runner.JUnitCore
Remove a listener.
removeListener(RunListener) - Method in class org.junit.runner.notification.RunNotifier
Internal use only
Request - Class in org.junit.runner
A Request is an abstract description of tests to be run.
Request() - Constructor for class org.junit.runner.Request
 
Result - Class in org.junit.runner
A Result collects and summarizes information from running multiple tests.
Result() - Constructor for class org.junit.runner.Result
 
run(Class<?>...) - Method in class org.junit.runner.JUnitCore
Run all the tests in classes.
run(Request) - Method in class org.junit.runner.JUnitCore
Run all the tests contained in request.
run(Test) - Method in class org.junit.runner.JUnitCore
Run all the tests contained in JUnit 3.8.x test.
run(Runner) - Method in class org.junit.runner.JUnitCore
Do not use.
run(RunNotifier) - Method in class org.junit.runner.Runner
Run the tests for this runner.
runClasses(Class<?>...) - Static method in class org.junit.runner.JUnitCore
Run the tests contained in classes.
RunListener - Class in org.junit.runner.notification
If you need to respond to the events during a test run, extend RunListener and override the appropriate methods.
RunListener() - Constructor for class org.junit.runner.notification.RunListener
 
runMain(String...) - Method in class org.junit.runner.JUnitCore
Do not use.
Runner - Class in org.junit.runner
A Runner runs tests and notifies a RunNotifier of significant events as it does so.
Runner() - Constructor for class org.junit.runner.Runner
 
RunNotifier - Class in org.junit.runner.notification
If you write custom runners, you may need to notify JUnit of your progress running tests.
RunNotifier() - Constructor for class org.junit.runner.notification.RunNotifier
 
RunWith - Annotation Type in 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.

S

shouldRun(Description) - Method in class org.junit.runner.manipulation.Filter
 
sort(Sorter) - Method in interface org.junit.runner.manipulation.Sortable
Sorts the tests using sorter
Sortable - Interface in org.junit.runner.manipulation
Interface for runners that allow sorting of tests.
Sorter - Class in org.junit.runner.manipulation
A Sorter orders tests.
Sorter(Comparator<Description>) - Constructor for class org.junit.runner.manipulation.Sorter
Creates a Sorter that uses comparator to sort tests
sortWith(Comparator<Description>) - Method in class org.junit.runner.Request
Returns a Request whose Tests can be run in a certain order, defined by comparator
StoppedByUserException - Exception in org.junit.runner.notification
Thrown when a user has requested that the test run stop.
StoppedByUserException() - Constructor for exception org.junit.runner.notification.StoppedByUserException
 
Suite - Class in org.junit.runners
Using Suite as a runner allows you to manually build a suite containing tests from many classes.
Suite(Class<?>) - Constructor for class org.junit.runners.Suite
Internal use only.
Suite(Class<?>, Class<?>[]) - Constructor for class org.junit.runners.Suite
 
Suite.SuiteClasses - Annotation Type in org.junit.runners
The SuiteClasses annotation specifies the classes to be run when a class annotated with @RunWith(Suite.class) is run.

T

Test - Annotation Type in org.junit
The Test annotation tells JUnit that the public void method to which it is attached can be run as a test case.
Test.None - Class in org.junit
Default empty exception
TEST_MECHANISM - Static variable in class org.junit.runner.Description
 
testCount() - Method in class org.junit.runner.Description
 
testCount() - Method in class org.junit.runner.Runner
 
testFailure(Failure) - Method in class org.junit.runner.notification.RunListener
Called when an atomic test fails.
testFinished(Description) - Method in class org.junit.runner.notification.RunListener
Called when an atomic test has finished, whether the test succeeds or fails.
testIgnored(Description) - Method in class org.junit.runner.notification.RunListener
Called when a test will not be run, generally because a test method is annotated with Ignore.
testRunFinished(Result) - Method in class org.junit.runner.notification.RunListener
Called when all tests have finished
testRunStarted(Description) - Method in class org.junit.runner.notification.RunListener
Called before any tests have been run.
testStarted(Description) - Method in class org.junit.runner.notification.RunListener
Called when an atomic test is about to be started.
toString() - Method in class org.junit.runner.Description
 
toString() - Method in class org.junit.runner.notification.Failure
 

V

validate(MethodValidator) - Method in class org.junit.runners.Parameterized
 

W

wasSuccessful() - Method in class org.junit.runner.Result
 

A B C D E F G H I J M N O P R S T V W