1 33 34 package edu.rice.cs.drjava.model; 35 36 import junit.framework.*; 37 38 import java.io.File ; 39 40 import edu.rice.cs.drjava.DrJavaTestCase; 41 42 49 public class DummyGlobalModelTest extends DrJavaTestCase { 50 51 52 59 public void testGetDocumentForFile() throws java.io.IOException { 60 DummyGlobalModel dummy = new DummyGlobalModel(); 61 try { 62 dummy.getDocumentForFile(new File ("")); 63 } 64 catch (UnsupportedOperationException e) { 65 assertTrue("This message should never be seen", true); 66 return; 67 } 68 fail("expected that UnsupportedOperationException is thrown"); 69 } 70 71 78 public void testIsAlreadyOpen() throws java.io.IOException { 79 DummyGlobalModel dummy = new DummyGlobalModel(); 80 try { 81 dummy.getDocumentForFile(new File ("")); 82 } 83 catch (UnsupportedOperationException e) { 84 assertTrue("This message should never be seen", true); 85 return; 86 } 87 fail("expected that UnsupportedOperationException is thrown"); 88 } 89 90 91 98 public void testGetDefinitionsDocuments() { 99 DummyGlobalModel dummy = new DummyGlobalModel(); 100 try { 101 dummy.getOpenDefinitionsDocuments(); 102 } 103 catch (UnsupportedOperationException e) { 104 assertTrue("This message should never be seen", true); 105 return; 106 } 107 fail("expected that UnsupportedOperationException is thrown"); 108 } 109 110 111 118 public void testHasModifiedDocuments() { 119 DummyGlobalModel dummy = new DummyGlobalModel(); 120 try { 121 dummy.hasModifiedDocuments(); 122 } 123 catch (UnsupportedOperationException e) { 124 assertTrue("This message should never be seen", true); 125 return; 126 } 127 fail("expected that UnsupportedOperationException is thrown"); 128 } 129 130 131 } 132 | Popular Tags |