Added string decoding, tests