|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Objectjunit.framework.Assert
junit.framework.TestCase
org.eclipse.core.tests.harness.CoreTest
org.eclipse.core.tests.resources.ResourceTest
public abstract class ResourceTest
Superclass for tests that use the Eclipse Platform workspace.
Field Summary | |
---|---|
static IResourceChangeListener |
deltaListener
delta change listener if requested |
static java.lang.String |
PI_RESOURCES_TESTS
|
Fields inherited from class org.eclipse.core.tests.harness.CoreTest |
---|
PI_HARNESS |
Constructor Summary | |
---|---|
ResourceTest()
Need a zero argument constructor to satisfy the test harness. |
|
ResourceTest(java.lang.String name)
Creates a new ResourceTest |
Method Summary | |
---|---|
void |
assertDoesNotExistInFileSystem(IResource resource)
Assert that the given resource does not exist in the local store. |
void |
assertDoesNotExistInFileSystem(IResource[] resources)
Assert that each element of the resource array does not exist in the local store. |
void |
assertDoesNotExistInFileSystem(java.lang.String message,
IResource resource)
Assert that the given resource does not exist in the local store. |
void |
assertDoesNotExistInFileSystem(java.lang.String message,
IResource[] resources)
Assert that each element of the resource array does not exist in the local store. |
void |
assertDoesNotExistInWorkspace(IResource resource)
Assert that the given resource does not exist in the workspace resource info tree. |
void |
assertDoesNotExistInWorkspace(IResource[] resources)
Assert that each element of the resource array does not exist in the workspace resource info tree. |
void |
assertDoesNotExistInWorkspace(java.lang.String message,
IResource resource)
Assert that the given resource does not exist in the workspace resource info tree. |
void |
assertDoesNotExistInWorkspace(java.lang.String message,
IResource[] resources)
Assert that each element of the resource array does not exist in the workspace resource info tree. |
void |
assertExistsInFileSystem(IResource resource)
Assert whether or not the given resource exists in the local store. |
void |
assertExistsInFileSystem(IResource[] resources)
Assert that each element in the resource array exists in the local store. |
void |
assertExistsInFileSystem(java.lang.String message,
IResource resource)
Assert whether or not the given resource exists in the local store. |
void |
assertExistsInFileSystem(java.lang.String message,
IResource[] resources)
Assert that each element in the resource array exists in the local store. |
void |
assertExistsInWorkspace(IResource resource)
Assert whether or not the given resource exists in the workspace resource info tree. |
void |
assertExistsInWorkspace(IResource[] resources)
Assert that each element of the resource array exists in the workspace resource info tree. |
void |
assertExistsInWorkspace(IResource[] resources,
boolean phantom)
Assert that each element of the resource array exists in the workspace resource info tree. |
void |
assertExistsInWorkspace(IResource resource,
boolean phantom)
Assert whether or not the given resource exists in the workspace resource info tree. |
void |
assertExistsInWorkspace(java.lang.String message,
IResource resource)
Assert whether or not the given resource exists in the workspace resource info tree. |
void |
assertExistsInWorkspace(java.lang.String message,
IResource[] resources)
Assert that each element of the resource array exists in the workspace resource info tree. |
void |
assertExistsInWorkspace(java.lang.String message,
IResource[] resources,
boolean phantom)
Assert that each element of the resource array exists in the workspace resource info tree. |
void |
assertExistsInWorkspace(java.lang.String message,
IResource resource,
boolean phantom)
Assert whether or not the given resource exists in the workspace resource info tree. |
IResource[] |
buildResources()
Return a collection of resources the hierarchy defined by defineHeirarchy(). |
IResource[] |
buildResources(IContainer root,
java.lang.String[] hierarchy)
Return a collection of resources for the given hierarchy at the given root. |
boolean |
compareContent(java.io.InputStream a,
java.io.InputStream b)
Returns a boolean value indicating whether or not the contents of the given streams are considered to be equal. |
void |
createFileInFileSystem(org.eclipse.core.filesystem.IFileStore file)
Create the given file in the local store. |
void |
createFileInFileSystem(org.eclipse.core.filesystem.IFileStore file,
java.io.InputStream contents)
Create the given file in the local store. |
void |
createFileInFileSystem(org.eclipse.core.runtime.IPath path)
Create the given file in the file system. |
void |
createFileInFileSystem(org.eclipse.core.runtime.IPath path,
java.io.InputStream contents)
Create the given file in the file system. |
IResource[] |
createHierarchy()
|
java.lang.String[] |
defineHierarchy()
Returns a collection of string paths describing the standard resource hierarchy for this test. |
void |
ensureDoesNotExistInFileSystem(IResource resource)
Delete the given resource from the local store. |
void |
ensureDoesNotExistInFileSystem(IResource[] resources)
Delete the resources in the array from the local store. |
void |
ensureDoesNotExistInWorkspace(IResource resource)
Delete the given resource from the workspace resource tree. |
void |
ensureDoesNotExistInWorkspace(IResource[] resources)
Delete each element of the resource array from the workspace resource info tree. |
void |
ensureExistsInFileSystem(IFile file)
Create the given file in the local store. |
void |
ensureExistsInFileSystem(IResource resource)
Create the given folder in the local store. |
void |
ensureExistsInFileSystem(IResource[] resources)
Create the each resource of the array in the local store. |
void |
ensureExistsInWorkspace(IFile resource,
java.io.InputStream contents)
Create the given file in the workspace resource info tree. |
void |
ensureExistsInWorkspace(IFile resource,
java.lang.String contents)
Create the given file in the workspace resource info tree. |
void |
ensureExistsInWorkspace(IResource[] resources,
boolean local)
Create each element of the resource array in the workspace resource info tree. |
void |
ensureExistsInWorkspace(IResource resource,
boolean local)
Create the given resource in the workspace resource info tree. |
void |
ensureOutOfSync(IResource resource)
Modifies the resource in the file system so that it is out of sync with the workspace. |
java.lang.String |
getUniqueString()
|
static IWorkspace |
getWorkspace()
|
Methods inherited from class org.eclipse.core.tests.harness.CoreTest |
---|
createFileInFileSystem, debug, fail, getContents, getContents, getMonitor, getRandomContents, getRandomLocation, getRandomString, getTempDir, log, log, transferData, transferDataWithoutClose |
Methods inherited from class junit.framework.TestCase |
---|
countTestCases, getName, run, run, runBare, setName, toString |
Methods inherited from class junit.framework.Assert |
---|
assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertFalse, assertFalse, assertNotNull, assertNotNull, assertNotSame, assertNotSame, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame, failSame |
Methods inherited from class java.lang.Object |
---|
equals, getClass, hashCode, notify, notifyAll, wait, wait, wait |
Field Detail |
---|
public static IResourceChangeListener deltaListener
public static final java.lang.String PI_RESOURCES_TESTS
Constructor Detail |
---|
public ResourceTest()
public ResourceTest(java.lang.String name)
name
- java.lang.StringMethod Detail |
---|
public static IWorkspace getWorkspace()
public void assertDoesNotExistInFileSystem(IResource resource)
public void assertDoesNotExistInFileSystem(IResource[] resources)
public void assertDoesNotExistInFileSystem(java.lang.String message, IResource resource)
public void assertDoesNotExistInFileSystem(java.lang.String message, IResource[] resources)
public void assertDoesNotExistInWorkspace(IResource resource)
public void assertDoesNotExistInWorkspace(IResource[] resources)
public void assertDoesNotExistInWorkspace(java.lang.String message, IResource resource)
public void assertDoesNotExistInWorkspace(java.lang.String message, IResource[] resources)
public void assertExistsInFileSystem(IResource resource)
public void assertExistsInFileSystem(IResource[] resources)
public void assertExistsInFileSystem(java.lang.String message, IResource resource)
public void assertExistsInFileSystem(java.lang.String message, IResource[] resources)
public void assertExistsInWorkspace(IResource resource)
public void assertExistsInWorkspace(IResource resource, boolean phantom)
public void assertExistsInWorkspace(IResource[] resources)
public void assertExistsInWorkspace(IResource[] resources, boolean phantom)
public void assertExistsInWorkspace(java.lang.String message, IResource resource)
public void assertExistsInWorkspace(java.lang.String message, IResource resource, boolean phantom)
public void assertExistsInWorkspace(java.lang.String message, IResource[] resources)
public void assertExistsInWorkspace(java.lang.String message, IResource[] resources, boolean phantom)
public IResource[] buildResources()
public IResource[] buildResources(IContainer root, java.lang.String[] hierarchy)
public boolean compareContent(java.io.InputStream a, java.io.InputStream b)
public void createFileInFileSystem(org.eclipse.core.filesystem.IFileStore file)
public void createFileInFileSystem(org.eclipse.core.filesystem.IFileStore file, java.io.InputStream contents)
public void createFileInFileSystem(org.eclipse.core.runtime.IPath path)
public void createFileInFileSystem(org.eclipse.core.runtime.IPath path, java.io.InputStream contents)
public IResource[] createHierarchy()
public java.lang.String[] defineHierarchy()
return new String[] {"/", "/1/", "/1/1", "/1/2", "/1/3", "/2/", "/2/1"};
public void ensureDoesNotExistInFileSystem(IResource resource)
public void ensureDoesNotExistInFileSystem(IResource[] resources)
public void ensureDoesNotExistInWorkspace(IResource resource)
public void ensureDoesNotExistInWorkspace(IResource[] resources)
public void ensureExistsInFileSystem(IFile file)
public void ensureExistsInFileSystem(IResource resource)
public void ensureExistsInFileSystem(IResource[] resources)
public void ensureExistsInWorkspace(IFile resource, java.io.InputStream contents)
public void ensureExistsInWorkspace(IFile resource, java.lang.String contents)
public void ensureExistsInWorkspace(IResource resource, boolean local)
public void ensureExistsInWorkspace(IResource[] resources, boolean local)
public void ensureOutOfSync(IResource resource)
public java.lang.String getUniqueString()
getUniqueString
in class CoreTest
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: NESTED | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |