Alphabetical Index

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

>

> eachOne(Object...) - static method in class org.junit.runners.Parameterized

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(org.junit.runner.Description) - method in class org.junit.runner.Description
Add Description as a child of the receiver.
addFirstListener(org.junit.runner.notification.RunListener) - method in class org.junit.runner.notification.RunNotifier
Internal use only.
Add a listener to be notified as the tests run.
addListener(org.junit.runner.notification.RunListener) - method in class org.junit.runner.notification.RunNotifier
Internal use only
After - interface org.junit.After
If you allocate external resources in a Before method you need to release them after the test runs.
AfterClass - interface org.junit.AfterClass
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 field in class org.junit.runner.manipulation.Filter
A null Filter that passes all tests through.
AllTests - class org.junit.runners.AllTests
Runner for use with JUnit 3.8.x-style AllTests classes (those that only implement a static suite() method).
apply(org.junit.runner.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(org.junit.runner.Runner) - method in class org.junit.runner.manipulation.Sorter
Sorts the test in runner using comparator
Assert - class org.junit.Assert
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
assertArrayEquals(byte[],byte[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(char[],char[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(int[],int[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(long[],long[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(Object[],Object[]) - static method in class org.junit.Assert
Asserts that two object arrays are equal.
assertArrayEquals(short[],short[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(String,byte[],byte[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(String,char[],char[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(String,int[],int[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(String,long[],long[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertArrayEquals(String,Object[],Object[]) - static method in class org.junit.Assert
Asserts that two object arrays are equal.
assertArrayEquals(String,short[],short[]) - static method in class org.junit.Assert
TODO: fix javadoc Asserts that two object arrays are equal.
assertEquals(double,double,double) - static method in class org.junit.Assert
Asserts that two doubles or floats are equal to within a positive delta.
assertEquals(Object,Object) - static method in class org.junit.Assert
Asserts that two objects are equal.
assertEquals(String,double,double,double) - static method in class org.junit.Assert
Asserts that two doubles or floats are equal to within a positive delta.
assertEquals(String,Object,Object) - static method in class org.junit.Assert
Asserts that two objects are equal.
assertFalse(boolean) - static method in class org.junit.Assert
Asserts that a condition is false.
assertFalse(String,boolean) - static method in class org.junit.Assert
Asserts that a condition is false.
assertNotNull(Object) - static method in class org.junit.Assert
Asserts that an object isn't null.
assertNotNull(String,Object) - static method in class org.junit.Assert
Asserts that an object isn't null.
assertNotSame(Object,Object) - static method in class org.junit.Assert
Asserts that two objects do not refer to the same object.
assertNotSame(String,Object,Object) - static method in class org.junit.Assert
Asserts that two objects do not refer to the same object.
assertNull(Object) - static method in class org.junit.Assert
Asserts that an object is null.
assertNull(String,Object) - static method in class org.junit.Assert
Asserts that an object is null.
assertSame(Object,Object) - static method in class org.junit.Assert
Asserts that two objects refer to the same object.
assertSame(String,Object,Object) - static method in class org.junit.Assert
Asserts that two objects refer to the same object.
assertTrue(boolean) - static method in class org.junit.Assert
Asserts that a condition is true.
assertTrue(String,boolean) - static method in class org.junit.Assert
Asserts that a condition is true.

B

Before - interface org.junit.Before
When writing tests, it is common to find that several tests need similar objects created before they can run.
BeforeClass - interface org.junit.BeforeClass
Sometimes several tests need to share computationally expensive setup (like logging into a database).
boolean equals(Object) - method in class org.junit.runner.Description

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.
classWithoutSuiteMethod(Class) - static method in class org.junit.runner.Request
compare(org.junit.runner.Description,org.junit.runner.Description) - method in class org.junit.runner.manipulation.Sorter
Thrown when an assertEquals(String, String) fails.
Constructs a comparison failure.
createListener() - method in class org.junit.runner.Result
Internal use only.
createSuiteDescription(Class) - static method in class org.junit.runner.Description
Create a Description named after testClass
createSuiteDescription(String) - static method in class org.junit.runner.Description
Create a Description named name.
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 org.junit.runner.Description
A Description describes a test which is to be run or has been run.

E

EMPTY - static field in class org.junit.runner.Description
Enclosed - class org.junit.runners.Enclosed
Enclosed(Class) - constructor for class org.junit.runners.Enclosed
errorReport(Class,Throwable) - static method in class org.junit.runner.Request
extends Runner> value() - method in class org.junit.runner.RunWith
extends Throwable> expected() - method in class org.junit.Test
Optionally specify expected, a Throwable, to cause a test method to succeed iff an exception of the specified class is thrown by the method.

F

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

I

Ignore - interface org.junit.Ignore
Sometimes you want to temporarily disable a test.
int hashCode() - method in class org.junit.runner.Description
isSuite() - method in class org.junit.runner.Description
isTest() - method in class org.junit.runner.Description

J

JUnitCore - class org.junit.runner.JUnitCore
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

Test.None - class org.junit.Test.None
Default empty exception
NoTestsRemainException - class org.junit.runner.manipulation.NoTestsRemainException
Thrown when a filter removes all tests from a runner.

O

org.junit - package

P

Parameterized - class org.junit.runners.Parameterized
The custom runner Parameterized implements parameterized tests.
Parameterized(Class) - constructor for class org.junit.runners.Parameterized
pleaseStop() - method in class org.junit.runner.notification.RunNotifier
Ask that the tests run stop before starting the next test.

R

Remove a listener.
removeListener(org.junit.runner.notification.RunListener) - method in class org.junit.runner.notification.RunNotifier
Internal use only
Request - class org.junit.runner.Request
A Request is an abstract description of tests to be run.
Result - class org.junit.runner.Result
A Result collects and summarizes information from running multiple tests.
run(Class...) - method in class org.junit.runner.JUnitCore
Run all the tests in classes.
run(junit.framework.Test) - method in class org.junit.runner.JUnitCore
Run all the tests contained in JUnit 3.8.x test.
run(org.junit.runner.notification.RunNotifier) - method in class org.junit.runner.Runner
Run the tests for this runner.
run(org.junit.runner.Request) - method in class org.junit.runner.JUnitCore
Run all the tests contained in request.
run(org.junit.runner.Runner) - method in class org.junit.runner.JUnitCore
Do not use.
runClasses(Class...) - static method in class org.junit.runner.JUnitCore
Run the tests contained in classes.
RunListener - class org.junit.runner.notification.RunListener
If you need to respond to the events during a test run, extend RunListener and override the appropriate methods.
runMain(String...) - method in class org.junit.runner.JUnitCore
Do not use.
Runner - class org.junit.runner.Runner
A Runner runs tests and notifies a RunNotifier of significant events as it does so.
RunNotifier - class org.junit.runner.notification.RunNotifier
If you write custom runners, you may need to notify JUnit of your progress running tests.
RunWith - interface org.junit.runner.RunWith
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(org.junit.runner.Description) - method in class org.junit.runner.manipulation.Filter
sort(org.junit.runner.manipulation.Sorter) - method in class org.junit.runner.manipulation.Sortable
Sorts the tests using sorter
Sortable - interface org.junit.runner.manipulation.Sortable
Interface for runners that allow sorting of tests.
Sorter - class org.junit.runner.manipulation.Sorter
A Sorter orders tests.
Sorter(Comparator) - constructor for class org.junit.runner.manipulation.Sorter
Creates a Sorter that uses comparator to sort tests
sortWith(Comparator) - method in class org.junit.runner.Request
Returns a Request whose Tests can be run in a certain order, defined by comparator For example, here is code to run a test suite in alphabetical order:
private static Comparator forward() {
return new Comparator() {
public int compare(Description o1, Description o2) {
return o1.getDisplayName().compareTo(o2.getDisplayName());
}
};
}
public static main() {
new JUnitCore().run(Request.aClass(AllTests.class).sortWith(forward()));
}
 
StoppedByUserException - class org.junit.runner.notification.StoppedByUserException
Thrown when a user has requested that the test run stop.
String getMessage() - method in class org.junit.ComparisonFailure
Returns "..." in place of common prefix and "..." in place of common suffix between expected and actual.
String toString() - method in class org.junit.runner.Description
String toString() - method in class org.junit.runner.notification.Failure
Suite - class org.junit.runners.Suite
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

T

Test - interface org.junit.Test
The Test annotation tells JUnit that the public void method to which it is attached can be run as a test case.
TEST_MECHANISM - static field in class org.junit.runner.Description
testAborted(org.junit.runner.Description,Throwable) - method in class org.junit.runner.notification.RunNotifier
testCount() - method in class org.junit.runner.Description
testCount() - method in class org.junit.runner.Runner
testFailure(org.junit.runner.notification.Failure) - method in class org.junit.runner.notification.RunListener
Called when an atomic test fails.
testFinished(org.junit.runner.Description) - method in class org.junit.runner.notification.RunListener
Called when an atomic test has finished, whether the test succeeds or fails.
testFromSuiteMethod(Class) - static method in class org.junit.runners.AllTests
testIgnored(org.junit.runner.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(org.junit.runner.Result) - method in class org.junit.runner.notification.RunListener
Called when all tests have finished
testRunStarted(org.junit.runner.Description) - method in class org.junit.runner.notification.RunListener
Called before any tests have been run.
testStarted(org.junit.runner.Description) - method in class org.junit.runner.notification.RunListener
Called when an atomic test is about to be started.
timeout() - method in class org.junit.Test
Optionally specify timeout in milliseconds to cause a test method to fail if it takes longer than that number of milliseconds.

V

value() - method in class org.junit.Ignore
The optional reason why the test is ignored.
void assertEquals(Object[],Object[]) - static method in class org.junit.Assert
Asserts that two object arrays are equal.
void assertEquals(String,Object[],Object[]) - static method in class org.junit.Assert
Asserts that two object arrays are equal.

W

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