adding test. Fixing return type