Add few more tests for cost matrix exceptions