|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |
java.lang.Object | +--junit.framework.Assert | +--junit.framework.TestCase | +--edu.rice.cs.drjava.model.GlobalModelTestCase | +--edu.rice.cs.drjava.model.GlobalModelIOTest
Test I/O functions of the global model.
Fields inherited from class edu.rice.cs.drjava.model.GlobalModelTestCase |
_model, _originalModel, _tempDir, BAR_TEXT, BAZ_TEXT, FOO_MISSING_CLOSE_TEXT, FOO_PACKAGE_AFTER_IMPORT, FOO_PACKAGE_AS_FIELD, FOO_PACKAGE_AS_FIELD_2, FOO_PACKAGE_AS_PART_OF_FIELD, FOO_PACKAGE_INSIDE_CLASS, FOO_TEXT |
Fields inherited from class junit.framework.TestCase |
fName |
Constructor Summary | |
GlobalModelIOTest(String name)
Constructor. |
Method Summary | |
static Test |
suite()
Creates a test suite for JUnit to run. |
void |
testCancelFirstSave()
Attempts to make the first save of a document, but cancels instead. |
void |
testCancelOpenFile()
Initiates a file open, but cancels. |
void |
testCancelOpenMultipleFiles()
Initiates a file open, but cancels. |
void |
testCancelSaveAlreadySaved()
First we save the document with FOO_TEXT. |
void |
testCancelSaveAsAlreadySaved()
Make sure that saveAs doesn't save if we cancel! |
void |
testCloseFileAllowAbandon()
Creates a new document, modifies it, then allows it to be closed, ignoring the changes made. |
void |
testCloseFileDisallowAbandon()
Creates a new document, modifies it, but disallows a call to close it without saving changes. |
void |
testCloseMultipleFiles()
Ensures closing documents works correctly. |
void |
testFileMovedWhenTriedToSave()
Test for the possibility that the file has been moved or deleted since it was last referenced |
void |
testForceFileOpen()
Force a file to be opened with getDocumentforFile |
void |
testModifiedByOther()
|
void |
testModifiedByOtherFalse()
|
void |
testMultipleFiles()
Creates a new document, modifies it, and then does the same with a second document, ensuring that the changes are separate. |
void |
testMultipleFilesArray()
Opens several documents and ensures that the array returned by the model is correct and in the right order. |
void |
testOpenMultipleFiles()
Opens multiple files. |
void |
testOpenMultipleFilesError()
Error checking for openening multiple files checks for null and an array w/null |
void |
testOpenMultipleNonexistentFiles()
Attempts to open a non-existent file. |
void |
testOpenNonexistentFile()
Attempts to open a non-existent file. |
void |
testOpenRealFile()
Opens a file. |
void |
testRealSaveFirstSave()
Makes a first save of the current document. |
void |
testReopenFile()
Attempts to reopen an already open file. |
void |
testRevertFile()
Force a file to be opened with getDocumentforFile |
void |
testSaveAllSaveInOrder()
Make sure that all open files are saved in appropriate order, ie, even with BAR file as active document, save all should first prompt to save FOO, then BAR. |
void |
testSaveAlreadySaved()
Saves a file already saved and overwrites its contents. |
void |
testSaveAsAlreadySaved()
Make sure that saveAs saves to a different file. |
void |
testSaveAsExistsAndOpen()
|
void |
testSaveAsExistsForOverwrite()
|
void |
testSaveClearAndLoadHistory()
Interprets some statements, saves the history, clears the history, then loads the history. |
Methods inherited from class edu.rice.cs.drjava.model.GlobalModelTestCase |
assertCompileErrorsPresent, assertCompileErrorsPresent, assertContents, assertLength, assertModified, assertNumOpenDocs, changeDocumentText, classForJava, createFile, createModel, interpret, interpretIgnoreResult, setUp, setupDocument, tearDown, tempDirectory, tempFile, tempFile, writeToNewTempFile |
Methods inherited from class junit.framework.TestCase |
countTestCases, createResult, getName, name, run, run, runBare, runTest, setName, toString |
Methods inherited from class junit.framework.Assert |
assert, assert, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertEquals, assertNotNull, assertNotNull, assertNull, assertNull, assertSame, assertSame, assertTrue, assertTrue, fail, fail, failNotEquals, failNotSame |
Methods inherited from class java.lang.Object |
|
Constructor Detail |
public GlobalModelIOTest(String name)
String
- nameMethod Detail |
public static Test suite()
public void testMultipleFiles() throws BadLocationException
public void testMultipleFilesArray() throws BadLocationException
public void testCloseMultipleFiles() throws BadLocationException
public void testCloseFileAllowAbandon() throws BadLocationException
public void testCloseFileDisallowAbandon() throws BadLocationException
public void testOpenRealFile() throws BadLocationException, IOException
public void testCancelOpenFile() throws BadLocationException, IOException
public void testOpenNonexistentFile() throws BadLocationException, IOException
public void testReopenFile() throws BadLocationException, IOException
public void testOpenMultipleFiles() throws BadLocationException, IOException
public void testCancelOpenMultipleFiles() throws BadLocationException, IOException
public void testOpenMultipleNonexistentFiles() throws BadLocationException, IOException
public void testOpenMultipleFilesError() throws BadLocationException, IOException
public void testForceFileOpen() throws BadLocationException, IOException, OperationCanceledException, AlreadyOpenException
public void testCancelFirstSave() throws BadLocationException, IOException
public void testRealSaveFirstSave() throws BadLocationException, IOException
public void testSaveAlreadySaved() throws BadLocationException, IOException
public void testCancelSaveAlreadySaved() throws BadLocationException, IOException
public void testCancelSaveAsAlreadySaved() throws BadLocationException, IOException
public void testSaveAsAlreadySaved() throws BadLocationException, IOException
public void testSaveAsExistsForOverwrite() throws BadLocationException, IOException
public void testSaveAsExistsAndOpen() throws BadLocationException, IOException, OperationCanceledException, AlreadyOpenException
public void testSaveAllSaveInOrder() throws BadLocationException, IOException
public void testRevertFile() throws BadLocationException, IOException, OperationCanceledException, AlreadyOpenException
public void testModifiedByOther() throws BadLocationException, IOException, OperationCanceledException, AlreadyOpenException, InterruptedException
public void testModifiedByOtherFalse() throws BadLocationException, IOException, OperationCanceledException, AlreadyOpenException, InterruptedException
public void testSaveClearAndLoadHistory() throws BadLocationException, InterruptedException, IOException
public void testFileMovedWhenTriedToSave() throws BadLocationException, IOException
|
||||||||||
PREV CLASS NEXT CLASS | FRAMES NO FRAMES | |||||||||
SUMMARY: INNER | FIELD | CONSTR | METHOD | DETAIL: FIELD | CONSTR | METHOD |