I changed the implementation of the random permutation in two ways:
it is now possible to provide a seed to change the outcome of the permutation process on the same input
the tweak that makes this permutation will fail if the result is unchanged
This satisfies, I believe the requirement for this Tweak; that is to give a pseudo-random way of permutating the outputs of a transaction to test to resilience of contract for such variations. I believe this PR is mergeable following these changes.
This PR proposes a collection of small improvements:
txSkelOutValidators
negativePart
andpositivePart
by relying onPl.negate
overMaybeTweakSelecting
tooverMaybeSelectingTweak
for consistency