Add new user guide page "Simplifying Code Before Compilation" #6796
Garnix CI / check plutus-tx-test [x86_64-linux]
succeeded
Jan 17, 2025 in 9s
Run results
Build succeeded
Details
Last 100 lines of logs:
one is a left identity: OK (0.01s)
✓ propOneLeftId passed 100 tests.
one is a right identity: OK (0.01s)
✓ propOneRightId passed 100 tests.
Ring
zero is a left annihilator: OK
✓ propZeroLeftAnnih passed 100 tests.
zero is a right annihilator: OK (0.01s)
✓ propZeroRightAnnih passed 100 tests.
* left-distributes over +: OK (0.02s)
✓ propTimesLeftDistPlus passed 100 tests.
* right-distributes over +: OK (0.02s)
✓ propTimesRightDistPlus passed 100 tests.
Module
scale 0 = 0: OK (0.01s)
✓ propScaleZero passed 100 tests.
scale 1 = id: OK
✓ propScaleOne passed 100 tests.
scale distributes over +: OK (0.01s)
✓ propScaleDistPlus passed 100 tests.
scale x (scale y r) = scale (x * y) r: OK
✓ propScaleTimes passed 100 tests.
Serialization
FromBuiltinData-ToBuiltinData roundtrip: OK
✓ propIsDataRound passed 100 tests.
unsafeFromBuiltinData . toBuiltinData = id: OK
✓ propUnsafeIsData passed 100 tests.
FromJSON-ToJSON roundtrip: OK (0.01s)
✓ propIsJSONRound passed 100 tests.
Construction
ratio x 0 = Nothing: OK
✓ propZeroDenom passed 100 tests.
ratio x 1 = Just . fromInteger $ x: OK
✓ propOneDenom passed 100 tests.
ratio x x = Just 1 for x /= 0: OK
✓ propRatioSelf passed 100 tests.
sign of result depends on signs of arguments: OK (0.25s)
✓ sign of result depends on signs of arguments passed 8000 tests.
zero numerator 34% ██████▊············· ✓ 30%
same signs 33% ██████▋············· ✓ 30%
different signs 33% ██████▌············· ✓ 30%
if ratio x y = Just r, then unsafeRatio x y = r: OK
✓ propConstructionAgreement passed 100 tests.
if r = fromInteger x, then numerator r = x: OK
✓ propFromIntegerNum passed 100 tests.
if r = fromInteger x, then denominator r = 1: OK
✓ propFromIntegerDen passed 100 tests.
ratio x y = ratio (x * z) (y * z) for z /= 0: OK
✓ propRatioScale passed 100 tests.
denominator (unsafeRatio x y) > 0: OK
✓ propUnsafeRatioDenomPos passed 100 tests.
Other
numerator r = numerator . scale (denominator r) $ r: OK
✓ propNumeratorScale passed 100 tests.
denominator r >= 1: OK
✓ propPosDen passed 100 tests.
recip r * r = 1 for r /= 0: OK
✓ propRecipSelf passed 100 tests.
abs r >= 0: OK
✓ propAbs passed 100 tests.
abs r * abs r' = abs (r * r'): OK
✓ probAbsTimes passed 100 tests.
r = n + f, where (n, f) = properFraction r: OK
✓ propProperFrac passed 100 tests.
signs of properFraction components match sign of input: OK (0.22s)
✓ signs of properFraction components match sign of input passed 8000 tests.
zero 34% ██████▋············· ✓ 30%
negative 34% ██████▋············· ✓ 30%
positive 33% ██████▌············· ✓ 30%
abs f < 1, where (_, f) = properFraction r: OK
✓ propProperFracAbs passed 100 tests.
abs (round r) >= abs n, where (n, _) = properFraction r: OK
✓ propAbsRound passed 100 tests.
halves round as expected: OK
✓ propRoundHalf passed 100 tests.
if abs f < half, then round r = truncate r, where (_, f) = properFraction r: OK
✓ propRoundLow passed 100 tests.
if abs f > half, then abs (round r) = abs (truncate r) + 1, where (_, f) = properFraction r: OK
✓ propRoundHigh passed 100 tests.
PlutusTx.Show property-based tests
PlutusTx.Show @Integer: OK
✓ PlutusTx.Show @Integer passed 100 tests.
PlutusTx.Show @BuiltinByteString: OK
✓ PlutusTx.Show @BuiltinByteString passed 100 tests.
Golden
product-type: OK
product-type-2: OK
sum-type-1: OK (0.01s)
sum-type-2: OK
record-type: OK (0.01s)
infix-type: OK
infix-type-2: OK
gadt: OK
poly: OK
PlutusTx.Blueprint.Definition
Derived definitions are empty when no types are provided.: OK
There are not less schema definitions than listed domain types.: OK
All referenced schema definitions are defined.: OK
All 125 tests passed (0.63s)
Loading