### Question:
ResourceNode extends BlockNode { public Node getName() { return name; } ResourceNode(String type, Node name, List<Node> body);  ResourceNode(GyroParser.ResourceContext context); String getType(); Node getName(); @Override R accept(NodeVisitor<C, R, X> visitor, C context);  }### Answer:
@Test void getNameNode() { Node name = mock(Node.class); ResourceNode node = new ResourceNode("foo", name, Collections.emptyList()); assertThat(node.getName()).isEqualTo(name); }