cuelang.org/go@v0.10.1/pkg/encoding/hex/testdata/gen.txtar (about)

     1  # generated from the original tests.
     2  # Henceforth it may be nicer to group tests into separate files.
     3  -- in.cue --
     4  import "encoding/hex"
     5  
     6  t1: hex.Encode("foo")
     7  t2: hex.Decode(hex.Encode("foo"))
     8  t3: hex.Decode("foo")
     9  t4: hex.Dump('foo')
    10  -- out/hex --
    11  Errors:
    12  t3: error in call to encoding/hex.Decode: encoding/hex: invalid byte: U+006F 'o':
    13      ./in.cue:5:5
    14  
    15  Result:
    16  t1: "666f6f"
    17  t2: 'foo'
    18  t3: _|_ // t3: error in call to encoding/hex.Decode: encoding/hex: invalid byte: U+006F 'o'
    19  t4: """
    20  	00000000  66 6f 6f                                          |foo|
    21  
    22  	"""