package utils

import "testing"

func TestString(t *testing.T) {
	t.Run("should parse normal string", func(t *testing.T) {
		seq := []byte{0x48, 0x65, 0x6C, 0x6C, 0x6F, 0x20, 0x77, 0x6F, 0x72, 0x6C, 0x64, 0x21}
		if String(seq) != "Hello world!" {
			t.Errorf("got %s, want %s", String(seq), "Hello world!")
		}
	})
}
