fix expect output
support multiline expect