Update Main.java

Some test cases added for canvas.java