fixes to get masterref tests to pass