Added generic enum
new testcase to test failing put
buffer length was not correctly set