Misc fixes.
General tests clean-up