Add tests for coverage the bug.