Implemented missing unit tests