예제 #1
0
        public void String()
        {
            var literal       = new GGLiteral("This is a string");
            var actualLiteral = GGParser.Parse(literal.ToString());

            Assert.Equal(literal, actualLiteral);
        }
예제 #2
0
        public void Null()
        {
            var literal       = new GGLiteral(null);
            var actualLiteral = GGParser.Parse(literal.ToString());

            Assert.Equal(literal, actualLiteral);
        }
예제 #3
0
        public void NumberDouble()
        {
            var literal       = new GGLiteral(42.42);
            var actualLiteral = GGParser.Parse(literal.ToString());

            Assert.Equal(literal, actualLiteral);

            literal       = new GGLiteral(-42.42);
            actualLiteral = GGParser.Parse(literal.ToString());
            Assert.Equal(literal, actualLiteral);
        }