cardano-ledger-core-1.17.0.0: Core components of Cardano ledgers from the Shelley release on.
Safe HaskellSafe-Inferred
LanguageHaskell2010

Test.Cardano.Ledger.Core.Arbitrary

Synopsis

Documentation

genBadPtrGen Ptr Source #

Generate a Ptr with full 64bit range for values. Not allowed starting in Babbage

Plutus

Utils

Will need to find a better home in the future

uniformSubSet Source #

Arguments

∷ (StatefulGen g m, Ord k) 
Maybe Int

Size of the subset. If supplied will be clamped to [0, Set.size s] interval, otherwise will be generated randomly.

Set k 
→ g 
→ m (Set k) 

uniformSubMap Source #

Arguments

∷ (StatefulGen g m, Ord k) 
Maybe Int

Size of the subMap. If supplied will be clamped to [0, Map.size s] interval, otherwise will be generated randomly.

Map k v 
→ g 
→ m (Map k v) 

uniformSubMapElems Source #

Arguments

∷ (StatefulGen g m, Monoid f) 
⇒ (k → v → f → f) 
Maybe Int

Size of the subMap. If supplied will be clamped to [0, Map.size s] interval, otherwise will be generated randomly.

Map k v 
→ g 
→ m f 

Orphan instances

Arbitrary AddrAttributes Source # 
Instance details

Arbitrary Address Source # 
Instance details

Arbitrary Addr Source # 
Instance details

Arbitrary BootstrapAddress Source # 
Instance details

Arbitrary CompactAddr Source # 
Instance details

Arbitrary RewardAccount Source # 
Instance details

Arbitrary Withdrawals Source # 
Instance details

Arbitrary ActiveSlotCoeff Source # 
Instance details

Arbitrary Anchor Source # 
Instance details

Arbitrary BlocksMade Source # 
Instance details

Arbitrary CertIx Source # 
Instance details

Arbitrary DnsName Source # 
Instance details

Arbitrary Network Source # 
Instance details

Arbitrary NonNegativeInterval Source #

Decimal numbers only

Instance details

Arbitrary Nonce Source # 
Instance details

Arbitrary Port Source # 
Instance details

Arbitrary PositiveInterval Source #

Decimal numbers only

Instance details

Arbitrary PositiveUnitInterval Source #

Decimal numbers only

Instance details

Arbitrary ProtVer Source # 
Instance details

Arbitrary TxIx Source # 
Instance details

Arbitrary UnitInterval Source #

Decimal numbers only

Instance details

Arbitrary Url Source # 
Instance details

Methods

arbitraryGen Url Source #

shrinkUrl → [Url] Source #

Arbitrary CommitteeAuthorization Source # 
Instance details

Arbitrary FutureGenDeleg Source # 
Instance details

Arbitrary InstantaneousRewards Source # 
Instance details

Arbitrary Coin Source # 
Instance details

Arbitrary DeltaCoin Source # 
Instance details

Arbitrary PoolCert Source # 
Instance details

Arbitrary Ptr Source # 
Instance details

Methods

arbitraryGen Ptr Source #

shrinkPtr → [Ptr] Source #

Arbitrary StakeReference Source # 
Instance details

Arbitrary DRep Source # 
Instance details

Arbitrary DRepState Source # 
Instance details

Arbitrary SnapShot Source # 
Instance details

Arbitrary SnapShots Source # 
Instance details

Arbitrary Stake Source #

In the system, Stake never contains more than the sum of all Ada (which is constant). This makes it safe to store individual Coins (in CompactForm) as Word64. But we must be careful that we never generate Stake where the sum of all the coins exceeds (maxBound :: Word64) There will never be a real Stake in the system with that many Ada, because total Ada is constant. So using a restricted Arbitrary Generator is OK.

Instance details

Arbitrary GenDelegPair Source # 
Instance details

Arbitrary GenDelegs Source # 
Instance details

Arbitrary ScriptHash Source # 
Instance details

Arbitrary TxAuxDataHash Source # 
Instance details

Arbitrary BootstrapWitness Source # 
Instance details

Arbitrary ChainCode Source # 
Instance details

Arbitrary CostModel Source # 
Instance details

Arbitrary CostModels Source #

This Arbitrary instance assumes the inflexible deserialization scheme prior to version 9.

Instance details

Arbitrary ExUnits Source # 
Instance details

Arbitrary Prices Source # 
Instance details

Arbitrary Language Source # 
Instance details

Arbitrary IndividualPoolStake Source # 
Instance details

Arbitrary PoolDistr Source # 
Instance details

Arbitrary PoolMetadata Source # 
Instance details

Arbitrary PoolParams Source # 
Instance details

Arbitrary SizeOfPoolOwners Source # 
Instance details

Arbitrary SizeOfPoolRelays Source # 
Instance details

Arbitrary StakePoolRelay Source # 
Instance details

Arbitrary Reward Source # 
Instance details

Arbitrary RewardType Source # 
Instance details

Arbitrary TxId Source # 
Instance details

Arbitrary TxIn Source # 
Instance details

Arbitrary RDPair Source # 
Instance details

Arbitrary UMElem Source # 
Instance details

Arbitrary UMap Source # 
Instance details

Arbitrary EpochInterval Source # 
Instance details

GenValid ActiveSlotCoeff Source # 
Instance details

GenValid NonNegativeInterval Source # 
Instance details

GenValid PositiveInterval Source # 
Instance details

GenValid PositiveUnitInterval Source # 
Instance details

GenValid UnitInterval Source # 
Instance details

Validity ActiveSlotCoeff Source # 
Instance details

Validity NonNegativeInterval Source # 
Instance details

Validity PositiveInterval Source # 
Instance details

Validity PositiveUnitInterval Source # 
Instance details

Validity UnitInterval Source # 
Instance details

(Era era, EncCBOR (f era), Arbitrary (f era)) ⇒ Arbitrary (Sized (f era)) Source # 
Instance details

Methods

arbitraryGen (Sized (f era)) Source #

shrinkSized (f era) → [Sized (f era)] Source #

Arbitrary (Attributes AddrAttributes) Source # 
Instance details

Era era ⇒ Arbitrary (CertState era) Source # 
Instance details

Methods

arbitraryGen (CertState era) Source #

shrinkCertState era → [CertState era] Source #

Arbitrary (CommitteeState era) Source # 
Instance details

Era era ⇒ Arbitrary (DState era) Source # 
Instance details

Methods

arbitraryGen (DState era) Source #

shrinkDState era → [DState era] Source #

Arbitrary (PState era) Source # 
Instance details

Methods

arbitraryGen (PState era) Source #

shrinkPState era → [PState era] Source #

Arbitrary (VState era) Source # 
Instance details

Methods

arbitraryGen (VState era) Source #

shrinkVState era → [VState era] Source #

Arbitrary (CompactForm Coin) Source # 
Instance details

(Era era, Arbitrary (PParamsHKD Identity era)) ⇒ Arbitrary (PParams era) Source # 
Instance details

Methods

arbitraryGen (PParams era) Source #

shrinkPParams era → [PParams era] Source #

(Era era, Arbitrary (PParamsHKD StrictMaybe era)) ⇒ Arbitrary (PParamsUpdate era) Source # 
Instance details

Arbitrary (Credential r) Source # 
Instance details

Arbitrary (NoUpdate a) Source # 
Instance details

Arbitrary (KeyHash r) Source # 
Instance details

Methods

arbitraryGen (KeyHash r) Source #

shrinkKeyHash r → [KeyHash r] Source #

Arbitrary (SafeHash i) Source # 
Instance details

Arbitrary (VRFVerKeyHash r) Source # 
Instance details

Arbitrary (VKey kd) Source # 
Instance details

Methods

arbitraryGen (VKey kd) Source #

shrinkVKey kd → [VKey kd] Source #

Typeable kr ⇒ Arbitrary (WitVKey kr) Source # 
Instance details

Methods

arbitraryGen (WitVKey kr) Source #

shrinkWitVKey kr → [WitVKey kr] Source #

(EraTxOut era, Arbitrary (TxOut era)) ⇒ Arbitrary (UTxO era) Source # 
Instance details

Methods

arbitraryGen (UTxO era) Source #

shrinkUTxO era → [UTxO era] Source #

Arbitrary a ⇒ Arbitrary (Mismatch r a) Source # 
Instance details

Methods

arbitraryGen (Mismatch r a) Source #

shrinkMismatch r a → [Mismatch r a] Source #