Fixed failing test and added a missing test.