Examples of prettySourceString()


Examples of st.gravel.support.compiler.ast.Statement.prettySourceString()

  @Test
  public void testParseNestedExpression() {
    final Statement _node;
    _node = Parser.factory.source_(" 3 + (4 + 5) ").parseExpression();
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), BinaryMessageNode.factory));
    assertEquals((String) "3 + (4 + 5)", (String) _node.prettySourceString());
  }

  @Test
  public void testParseNilaryBlockNoTemps() {
    final Statement _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.Statement.prettySourceString()

  @Test
  public void testParseNilaryBlockNoTemps() {
    final Statement _node;
    _node = Parser.factory.source_("[1 foo. 2 bar]").parseExpression();
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), BlockNode.factory));
    assertEquals((String) "\n[\n1 foo.\n2 bar]", (String) _node.prettySourceString());
  }

  @Test
  public void testParseNilaryBlockWithTemps() {
    final Statement _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.Statement.prettySourceString()

  @Test
  public void testParseNilaryBlockWithTemps() {
    final Statement _node;
    _node = Parser.factory.source_("[| a b | a foo. b bar]").parseExpression();
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), BlockNode.factory));
    assertEquals((String) "\n[\n| a b |\na foo.\nb bar]", (String) _node.prettySourceString());
  }

  @Test
  public void testParseNilInArray1() {
    final ArrayLiteralNode _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.Statement.prettySourceString()

  @Test
  public void testParseReturn() {
    final Statement _node;
    _node = Parser.factory.source_("[:a | ^a]").parseExpression();
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), BlockNode.factory));
    assertEquals((String) "[:a | ^a]", (String) _node.prettySourceString());
  }

  @Test
  public void testParseString1() {
    final StringLiteralNode _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.Statement.prettySourceString()

  @Test
  public void testParseUnaryBlockNoTemps() {
    final Statement _node;
    _node = Parser.factory.source_("[:a | a foo. 2 bar]").parseExpression();
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), BlockNode.factory));
    assertEquals((String) "\n[:a | \na foo.\n2 bar]", (String) _node.prettySourceString());
  }

  @Test
  public void testParseUnaryBlockWithTemps() {
    final Statement _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.Statement.prettySourceString()

  @Test
  public void testParseUnaryBlockWithTemps() {
    final Statement _node;
    _node = Parser.factory.source_("[:a | | b | a foo. b bar]").parseExpression();
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), BlockNode.factory));
    assertEquals((String) "\n[:a | \n| b |\na foo.\nb bar]", (String) _node.prettySourceString());
  }

  @Test
  public void testParseUnaryExpression() {
    final UnaryMessageNode _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.UnaryMessageNode.prettySourceString()

  @Test
  public void testParseUnaryExpression() {
    final UnaryMessageNode _node;
    _node = ((UnaryMessageNode) Parser.factory.source_(" 3 foo ").parseExpression());
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), UnaryMessageNode.factory));
    assertEquals((String) "3 foo", (String) _node.prettySourceString());
  }

  @Test
  public void testParseUnaryMethod() {
    final UnaryMethodNode _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.UnaryMethodNode.prettySourceString()

  @Test
  public void testParseUnaryMethod() {
    final UnaryMethodNode _node;
    _node = ((UnaryMethodNode) Parser.factory.parseMethod_("foo self baz. ^bar"));
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), UnaryMethodNode.factory));
    assertEquals((String) "foo\n\tself baz.\n\t^bar", (String) _node.prettySourceString());
  }

  @Test
  public void testParseVariable() {
    final VariableNode _node;
View Full Code Here

Examples of st.gravel.support.compiler.ast.VariableNode.prettySourceString()

  @Test
  public void testParseVariable() {
    final VariableNode _node;
    _node = ((VariableNode) Parser.factory.source_(" foo ").parseExpression());
    assertTrue(st.gravel.support.jvm.ObjectExtensions.equals_(_node.factory(), VariableNode.factory));
    assertEquals((String) "foo", (String) _node.prettySourceString());
  }

  @Test
  public void testParseVariableDot() {
    final BlockNode _node;
View Full Code Here
TOP
Copyright © 2018 www.massapi.com. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.