update shell grammar and add test case