You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
412 lines
21 KiB
412 lines
21 KiB
1 year ago
|
---
|
||
|
test case: Zero bytes received
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- ''
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 0
|
||
|
---
|
||
|
test case: Correct number of bytes received
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
# Start of header parsing tests
|
||
|
---
|
||
|
test case: Fragmented header
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZB'
|
||
|
- 'XD\x01\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
---
|
||
|
test case: Fragmented incorrect header in part 1
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZZ'
|
||
|
- 'XD\x01\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Fragmented incorrect header in part 2
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZB'
|
||
|
- 'XX\x01\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Header in separate fragment
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01'
|
||
|
- '\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
---
|
||
|
test case: Header in separate fragment incorrect
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBBD\x01'
|
||
|
- '\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Whole header fragmented
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'Z'
|
||
|
- 'B'
|
||
|
- 'X'
|
||
|
- 'D'
|
||
|
- '\x01'
|
||
|
- '\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
---
|
||
|
test case: Only header with 0 data
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x00\x00\x00\x00\x00\x00\x00\x00'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 13
|
||
|
---
|
||
|
test case: Header is too small
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBX'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
# End of header parsing tests
|
||
|
# Start of version parsing tests
|
||
|
test case: Version not received
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD'
|
||
|
out:
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Incorrect version 0 in header
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x00\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Incorrect version in header only compression
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x02\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Unsupported version in header
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x04\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
return: FAIL
|
||
|
test case: Unsupported and supported versions in header
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\xFF\x0A\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Received header signature without version
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
# Start of data length parsing tests
|
||
|
---
|
||
|
test case: Hheader + version received
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Header + version + data size received
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x00\x00\x00\x00'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Header and data length fragmented
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'Z'
|
||
|
- 'B'
|
||
|
- 'X'
|
||
|
- 'D'
|
||
|
- '\x01'
|
||
|
- '\x0A' # data length starts
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- 'agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
---
|
||
|
test case: Data length indicator exceed max size
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'Z'
|
||
|
- 'B'
|
||
|
- 'X'
|
||
|
- 'D'
|
||
|
- '\x01'
|
||
|
- '\x01\x00\x00\x08\x00\x00\x00\x00'
|
||
|
- 'agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Don't accept if bigger length is supplied in header than sent
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x0B\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Don't accept if smaller length supplied than sent
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x09\x00\x00\x00\x00\x00\x00\x00agent.ping'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Data length is too small
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x01\x00\x00\x00\x00\x00\x00'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
# End of data length parsing tests
|
||
|
# Start of data tests
|
||
|
test case: Fragmented key
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x0A\x00\x00'
|
||
|
- '\x00\x00\x00\x00\x00agent.pi'
|
||
|
- 'ng'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
---
|
||
|
test case: Fragmented key by bytes
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x0A\x00\x00'
|
||
|
- '\x00\x00\x00\x00\x00'
|
||
|
- 'a'
|
||
|
- 'g'
|
||
|
- 'e'
|
||
|
- 'n'
|
||
|
- 't'
|
||
|
- '.'
|
||
|
- 'p'
|
||
|
- 'i'
|
||
|
- 'n'
|
||
|
- 'g'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
---
|
||
|
test case: Whole message streamed by 1 byte
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'Z'
|
||
|
- 'B'
|
||
|
- 'X'
|
||
|
- 'D'
|
||
|
- '\x01'
|
||
|
- '\x0A' # data length starts
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- '\x00'
|
||
|
- 'a'
|
||
|
- 'g'
|
||
|
- 'e'
|
||
|
- 'n'
|
||
|
- 't'
|
||
|
- '.'
|
||
|
- 'p'
|
||
|
- 'i'
|
||
|
- 'n'
|
||
|
- 'g'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 23
|
||
|
---
|
||
|
test case: Stat buffer almost filled
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\xF2\x07\x00\x00\x00\x00\x00\x000123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmn'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 2047
|
||
|
---
|
||
|
test case: Stat buffer filled
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\xF3\x07\x00\x00\x00\x00\x00\x000123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmno'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 2048
|
||
|
---
|
||
|
test case: Second receive is required but still stat buffer
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\xF4\x07\x00\x00\x00\x00\x00\x000123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnop'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 2049
|
||
|
---
|
||
|
test case: Stat buffer is not enough for data, switching to dynamic
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x00\x08\x00\x00\x00\x00\x00\x000123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz01'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 2061
|
||
|
---
|
||
|
test case: Second receive, dynamic and fragmented
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x13\x08\x00\x00\x00\x00\x00\x000123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEF'
|
||
|
- 'GHI\x00'
|
||
|
- 'K'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 2080
|
||
|
---
|
||
|
test case: Second receive, received more than expected
|
||
|
in:
|
||
|
fragments: &fragments # 2050 expected
|
||
|
- 'ZBXD\x01\x02\x08\x00\x00\x00\x00\x00\x000123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789'
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: FAIL
|
||
|
---
|
||
|
test case: Lots of binary data
|
||
|
in:
|
||
|
fragments: &fragments
|
||
|
- 'ZBXD\x01\x00\x00\x02\x00\x00\x00\x00\x00'
|
||
|
- &1 '0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0123456789ABCDEFGHIJKLMNOPQRSTUVWXYZabcdefghijklmnopqrstuvwxyz0\x00'
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
- *1
|
||
|
out:
|
||
|
fragments: *fragments
|
||
|
return: SUCCEED
|
||
|
bytes: 131085
|
||
|
...
|