Cleanup debugging and update tests for testing and unstable