feat: move everything to single folder

This commit is contained in:
Yadunand Prem
2022-11-05 10:28:46 +08:00
parent 0eb6cd0b30
commit 44c87f3500
315 changed files with 48612 additions and 0 deletions

32
cs2030s/Lab4/Test1.java Normal file
View File

@@ -0,0 +1,32 @@
import java.io.PrintStream;
import java.io.ByteArrayOutputStream;
class Test1 {
public static void main(String[] args) {
CS2030STest we = new CS2030STest();
PrintStream old = System.out;
ByteArrayOutputStream baos;
PrintStream ps;
baos = new ByteArrayOutputStream();
ps = new PrintStream(baos);
System.setOut(ps);
new Print().call(17);
we.expectPrint("new Print().call(17)",
"17",
baos,
old);
baos = new ByteArrayOutputStream();
ps = new PrintStream(baos);
System.setOut(ps);
new Print().call("string");
we.expectPrint("new Print().call(\"string\")",
"string",
baos,
old);
}
}