diff options
Diffstat (limited to 'test/uk/ac/ox/cs/pagoda/junit/AllTests.java')
| -rw-r--r-- | test/uk/ac/ox/cs/pagoda/junit/AllTests.java | 48 |
1 files changed, 0 insertions, 48 deletions
diff --git a/test/uk/ac/ox/cs/pagoda/junit/AllTests.java b/test/uk/ac/ox/cs/pagoda/junit/AllTests.java deleted file mode 100644 index fb38787..0000000 --- a/test/uk/ac/ox/cs/pagoda/junit/AllTests.java +++ /dev/null | |||
| @@ -1,48 +0,0 @@ | |||
| 1 | package uk.ac.ox.cs.pagoda.junit; | ||
| 2 | |||
| 3 | import java.io.BufferedWriter; | ||
| 4 | import java.io.FileInputStream; | ||
| 5 | import java.io.FileNotFoundException; | ||
| 6 | import java.io.FileOutputStream; | ||
| 7 | import java.io.IOException; | ||
| 8 | import java.io.InputStream; | ||
| 9 | import java.io.OutputStream; | ||
| 10 | import java.io.OutputStreamWriter; | ||
| 11 | |||
| 12 | import org.junit.runner.RunWith; | ||
| 13 | import org.junit.runners.Suite; | ||
| 14 | import org.junit.runners.Suite.SuiteClasses; | ||
| 15 | |||
| 16 | @RunWith(Suite.class) | ||
| 17 | @SuiteClasses({ PagodaUOBM.class | ||
| 18 | }) | ||
| 19 | public class AllTests { | ||
| 20 | |||
| 21 | public static void copy(String source, String dest) { | ||
| 22 | InputStream is = null; | ||
| 23 | OutputStream os = null; | ||
| 24 | try { | ||
| 25 | is = new FileInputStream(source); | ||
| 26 | os = new FileOutputStream(dest); | ||
| 27 | byte[] buffer = new byte[1024]; | ||
| 28 | int length; | ||
| 29 | while ((length = is.read(buffer)) > 0) { | ||
| 30 | os.write(buffer, 0, length); | ||
| 31 | } | ||
| 32 | is.close(); | ||
| 33 | os.close(); | ||
| 34 | |||
| 35 | BufferedWriter writer = new BufferedWriter(new OutputStreamWriter(new FileOutputStream(source))); | ||
| 36 | writer.write(""); | ||
| 37 | writer.close(); | ||
| 38 | } catch (FileNotFoundException e) { | ||
| 39 | e.printStackTrace(); | ||
| 40 | } catch (IOException e) { | ||
| 41 | e.printStackTrace(); | ||
| 42 | } | ||
| 43 | |||
| 44 | // File src = new File(source); | ||
| 45 | // src.delete(); | ||
| 46 | } | ||
| 47 | |||
| 48 | } | ||
