test middle-of-buffer snippet insertion