Add testcase to makesure no double terminating delimiter be insetred.

Signed-off-by: Yen-Chin Lee <coldnew.tw@gmail.com>