Fixed failing test case by pattern matching for 5. Added failing test for 6.