Add tests for sub-typing
Add base classes to ScalarType