Bug fixes and test case updates.