Added error scenario test.