Test main method