Add test for incomplete datagram.
Fix datagram complete check.