tweaks and fixes for tests