Don't run casting test.
Throw exceptions for basic errors.