public void testOperation() throws Exception { String program = "\"\\n\\t\\\\\\\"\\\'\""; StingProgram sprogram = new StingProgram(program); ExecutionContext context = sprogram.execute(); StingStack correct = new StingStack(); correct.push(new StingString("\n\t\\\"\'")); assertTrue(correct.equals(context.getStack())); }
public StingStack getCorrectStack(ExecutionContext context) { StingStack stack = new StingStack(); stack.push(context.getOutput()); return stack; }