Added code to test decode function