Add tests for phase