Add test for relationships with multiple classes.