package function.builtin.special; import static testutil.TestUtilities.*; import org.junit.Test; import function.ArgumentValidator.*; public class QUOTETester { @Test public void testQuoteSymbol() { String input = "'a"; assertSExpressionsMatch(evaluateString(input), parseString("a")); } @Test public void testQuoteList() { String input = "'(l i s t)"; assertSExpressionsMatch(evaluateString(input), parseString("(l i s t)")); } @Test(expected = TooFewArgumentsException.class) public void testQuoteWithTooFewArguments() { evaluateString("(quote)"); } @Test(expected = TooManyArgumentsException.class) public void testQuoteWithTooManyArguments() { evaluateString("(quote a b)"); } }