Fixed tracebacks triggered by wrong use of beginMessage

Changed two test cases to reflect the changed signature of beginMessage. Please pull.