Removed unused code and new test for long keys.