Fix unit tests

A few tests went down with the latest wave of commits, nothing serious.
This fixes the tests, no changes to functionality.
Merge pull request #4429 from dballesteros7/fixUnitTests

Fix unit tests