Skip to content

Commit

Permalink
added failing test
Browse files Browse the repository at this point in the history
  • Loading branch information
jurgenvinju committed Jan 15, 2024
1 parent d0ec41b commit 25a0c65
Showing 1 changed file with 16 additions and 0 deletions.
16 changes: 16 additions & 0 deletions src/test/java/io/usethesource/vallang/basic/RelationSmokeTest.java
Original file line number Diff line number Diff line change
Expand Up @@ -182,6 +182,22 @@ public void testProductISet(IValueFactory vf) {
}
}

@ParameterizedTest @ArgumentsSource(ValueProvider.class)
public void testClosureFailureOnIrreflexiveRelation(IValueFactory vf) {
// rascal>{<"",{}>}+
// java.lang.AssertionError
// (internal error)
// at $shell$(|main://$shell$|)
// java.lang.AssertionError
// at io.usethesource.vallang.impl.persistent.PersistentHashIndexedBinaryRelation.<init>(PersistentHashIndexedBinaryRelation.java:74)
// at io.usethesource.vallang.impl.persistent.PersistentSetFactory.from(PersistentSetFactory.java:67)
// at io.usethesource.vallang.impl.persistent.PersistentHashIndexedBinaryRelation.closure(PersistentHashIndexedBinaryRelation.java:573)
ISet input = vf.set(vf.tuple(vf.string(""), vf.set()));

assertTrue(input.asRelation().closure().equals(input));
}


@ParameterizedTest @ArgumentsSource(ValueProvider.class)
public void testClosure(IValueFactory vf) {
try {
Expand Down

0 comments on commit 25a0c65

Please sign in to comment.