Github user rvesse commented on a diff in the pull request:

    https://github.com/apache/jena/pull/440#discussion_r198490652
  
    --- Diff: 
jena-arq/src/test/java/org/apache/jena/sparql/syntax/TestSSE_Builder.java ---
    @@ -233,4 +249,42 @@ public void testBuildExpr_14() {
                           "(!= ?x ?y)") ;
         }
     
    +    @Test
    +    public void testBuildTable_01() {
    +        Op expected = OpTable.unit();
    +        Op actual = SSE.parseOp("(table unit)");
    +        assertEquals(expected, actual);
    +    }
    +
    +    @Test
    +    public void testBuildTable_02() {
    +        Op expected = OpTable.empty();
    +        Op actual = SSE.parseOp("(table empty)");
    +        assertEquals(expected, actual);
    +    }
    +
    +    @Test
    +    public void testBuildTable_03() {
    +        Op expected = OpTable.create(TableFactory.create(Var.alloc("x"), 
NodeConst.nodeTrue));
    +        Op actual = SSE.parseOp("(table (vars ?x) (row (?x true)))");
    +        assertEquals(expected, actual);
    +    }
    +    
    +    @Test
    +    public void testBuildTable_04() {
    +        // Can't test for equality because can't create a BNode in a way 
that equality will
    +        // succeed because OpTable does strict equality and ignores 
NodeIsomorphismMap
    +        SSE.parseOp("(table (vars ?x) (row (?x _:test)))");
    +    }
    +
    +    @Test(expected = ExprBuildException.class)
    --- End diff --
    
    For some reason `expected` is not working as expected ;)


---

Reply via email to