Fix bug on message split and added test case