Adding missing imports for tests, and gate off others