// Failure 1: join to unique key
AISValidationFailure fail = fails.next();
Assert.assertEquals(ErrorCode.JOIN_TO_MULTIPLE_PARENTS, fail.errorCode());
// Failure 2: join to non-key
fail = fails.next();
Assert.assertEquals(ErrorCode.JOIN_TO_MULTIPLE_PARENTS, fail.errorCode());
// Failure 3: 3 joins to parent
fail = fails.next();
Assert.assertEquals(ErrorCode.JOIN_TO_WRONG_COLUMNS, fail.errorCode());
Assert.assertEquals("Table `s`.`child` join reference part `nk` does not match `s`.`parent` primary key part `pk`", fail.message());
// Failure 4: 3 joins to parent