fix all the broken tests

Mostly issues in relations