Add unit tests for NbtTagInfo and fix minor, associated bugs.