iotaledger / entangled

enTangle'd is an amalgamation of all things Tangle
Apache License 2.0
113 stars 66 forks source link

common: test and fix flex pow #1460

Closed semenov-vladyslav closed 4 years ago

semenov-vladyslav commented 4 years ago

This PR fixes issue with incorrect handling of head trits in flex_trits_insert_from_pos. It affects iota_pow_flex.

Also, fixed the test case for iota_pow_flex as it used sizes in flex trits instead of trits which results in invalid behaviour of iota_pow_flex, iota_flex_digest and flex_trits_to_trytes in the test case.