test boolean to_hash method