tests for sub