Report for lv.id.jc.correcter.coder.HammingDecoderSpec


Summary:

Created on Thu Jan 20 19:43:22 EET 2022 by jegors
Executed features Passed Failures Errors Skipped Success rate Time
1 1 0 0 0 100.0% 0.047 seconds
Hamming error-correction decoder
See:

Features:

should decode data by Hamming algorithm Return
Given:
received binary data with errors
def data = received as byte[]
When:
we decode the data using Hamming error-correction algorithm
def decoded = coder.apply(data)
Then:
the algorithm correct the data and we get original text
decoded == text as byte[]
Where:
we have one-bit errors in every byte of the data
Examples:
received text
[74, 152] T OK
[10, 144] T OK
[202, 24] T OK
[10, 152] T OK
[202, 152] T OK
[74, 152, 204, 74, 30, 134, 30, 152] Test OK
[106, 24, 236, 10, 63, 143, 63, 136] Test OK
7/7 passed