MCPcopy
hub / github.com/gogo/protobuf / TestEncodeDecode1

Function TestEncodeDecode1

proto/all_test.go:521–544  ·  view source on GitHub ↗

All required fields set, no defaults provided.

(t *testing.T)

Source from the content-addressed store, hash-verified

519
520// All required fields set, no defaults provided.
521func TestEncodeDecode1(t *testing.T) {
522 pb := initGoTest(false)
523 overify(t, pb,
524 "0807"+ // field 1, encoding 0, value 7
525 "220d"+"0a056c6162656c120474797065"+ // field 4, encoding 2 (GoTestField)
526 "5001"+ // field 10, encoding 0, value 1
527 "5803"+ // field 11, encoding 0, value 3
528 "6006"+ // field 12, encoding 0, value 6
529 "6d20000000"+ // field 13, encoding 5, value 0x20
530 "714000000000000000"+ // field 14, encoding 1, value 0x40
531 "78a019"+ // field 15, encoding 0, value 0xca0 = 3232
532 "8001c032"+ // field 16, encoding 0, value 0x1940 = 6464
533 "8d0100004a45"+ // field 17, encoding 5, value 3232.0
534 "9101000000000040b940"+ // field 18, encoding 1, value 6464.0
535 "9a0106"+"737472696e67"+ // field 19, encoding 2, string "string"
536 "b304"+ // field 70, encoding 3, start group
537 "ba0408"+"7265717569726564"+ // field 71, encoding 2, string "required"
538 "b404"+ // field 70, encoding 4, end group
539 "aa0605"+"6279746573"+ // field 101, encoding 2, string "bytes"
540 "b0063f"+ // field 102, encoding 0, 0x3f zigzag32
541 "b8067f"+ // field 103, encoding 0, 0x7f zigzag64
542 "c506e0ffffff"+ // field 104, encoding 5, -32 fixed32
543 "c906c0ffffffffffffff") // field 105, encoding 1, -64 fixed64
544}
545
546// All required fields set, defaults provided.
547func TestEncodeDecode2(t *testing.T) {

Callers

nothing calls this directly

Calls 2

initGoTestFunction · 0.85
overifyFunction · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…