Moved all type-specific tests to type-specific functions