Added tests for the two use cases