Add test for zero-length buffers with getBuffer/putBuffer