cardano-ledger-test-9.9.9.9: Testing harness, tests and benchmarks for Shelley style cardano ledgers
Safe HaskellSafe-Inferred
LanguageHaskell2010

Test.Cardano.Ledger.Generic.Same

Description

A Proof parameterized equality test, that records the sameness of individual record fields, this way it is possible to know where the equality failed.

Synopsis

Documentation

extendLabelString → [(String, Maybe x)] → [(String, Maybe x)] Source #

Relabel by appending s to the front of the path

notEqDoc a → Doc a → Doc a Source #

Dispays a difference vertically as x =/= y

eqByShow ∷ (Eq t, Show t) ⇒ t → t → Maybe PDoc Source #

Compare for equality, and display difference using show

eqViaEq t ⇒ (t → PDoc) → t → t → Maybe PDoc Source #

Compare for equality, and display differences using pcf

class Same era t where Source #

The Same class is similar to Eq but returns descriptions (paths and non-matching components) for each difference in a large structure.

Methods

sameProof era → t → t → [(String, Maybe PDoc)] Source #

Instances

Instances details
Same era (CertState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → CertState era → CertState era → [(String, Maybe PDoc)] Source #

Same era (DState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → DState era → DState era → [(String, Maybe PDoc)] Source #

Same era (PState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → PState era → PState era → [(String, Maybe PDoc)] Source #

Same era (VState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → VState era → VState era → [(String, Maybe PDoc)] Source #

Reflect era ⇒ Same era (EpochState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → EpochState era → EpochState era → [(String, Maybe PDoc)] Source #

Reflect era ⇒ Same era (LedgerState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → LedgerState era → LedgerState era → [(String, Maybe PDoc)] Source #

Reflect era ⇒ Same era (NewEpochState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → NewEpochState era → NewEpochState era → [(String, Maybe PDoc)] Source #

Reflect era ⇒ Same era (UTxOState era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Methods

sameProof era → UTxOState era → UTxOState era → [(String, Maybe PDoc)] Source #

Reflect era ⇒ Same era (ShelleyLedgerExamples era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

Era era ⇒ Same era (ShelleyResultExamples era) Source # 
Instance details

Defined in Test.Cardano.Ledger.Generic.Same

sameUTxOProof era → UTxO era → UTxO era → Maybe PDoc Source #

data SomeDepend where Source #

Constructors

SomeDString → (x → x → Maybe PDoc) → x → x → SomeDepend 
SomeMString → (x → x → [(String, Maybe PDoc)]) → x → x → SomeDepend 

sameWithDependency ∷ [SomeDepend] → [(String, Maybe PDoc)] Source #

If x occurs in y then a difference in x forces a difference in y, so only return the information on x if it has differences.

samePParamsProof era → PParams era → PParams era → Maybe PDoc Source #

sameTxOutProof era → TxOut era → TxOut era → Maybe PDoc Source #

sameShelleyTxWits ∷ ∀ era. Reflect era ⇒ Proof era → ShelleyTxWits era → ShelleyTxWits era → [(String, Maybe PDoc)] Source #

sameAlonzoTxWits ∷ ∀ era. (Reflect era, AlonzoEraScript era) ⇒ Proof era → AlonzoTxWits era → AlonzoTxWits era → [(String, Maybe PDoc)] Source #

sameTxWitsReflect era ⇒ Proof era → TxWits era → TxWits era → [(String, Maybe PDoc)] Source #

sameMaryTxBodyReflect era ⇒ Proof era → MaryTxBody era → MaryTxBody era → [(String, Maybe PDoc)] Source #

sameAlonzoTxBodyReflect era ⇒ Proof era → AlonzoTxBody era → AlonzoTxBody era → [(String, Maybe PDoc)] Source #

sameTxBodyReflect era ⇒ Proof era → TxBody era → TxBody era → [(String, Maybe PDoc)] Source #

sameShelleyTx ∷ (Reflect era, TxWits era ~ ShelleyTxWits era) ⇒ Proof era → ShelleyTx era → ShelleyTx era → [(String, Maybe PDoc)] Source #

sameAlonzoTx ∷ (Reflect era, AlonzoEraScript era, TxWits era ~ AlonzoTxWits era) ⇒ Proof era → AlonzoTx era → AlonzoTx era → [(String, Maybe PDoc)] Source #

sameTxReflect era ⇒ Proof era → Tx era → Tx era → [(String, Maybe PDoc)] Source #

sameShelleyTxSeq ∷ (Reflect era, Tx era ~ ShelleyTx era, SafeToHash (TxWits era)) ⇒ Proof era → ShelleyTxSeq era → ShelleyTxSeq era → [(String, Maybe PDoc)] Source #

sameAlonzoTxSeq ∷ (Reflect era, AlonzoEraTx era, SafeToHash (TxWits era)) ⇒ Proof era → AlonzoTxSeq era → AlonzoTxSeq era → [(String, Maybe PDoc)] Source #

sameTxSeqReflect era ⇒ Proof era → TxSeq era → TxSeq era → [(String, Maybe PDoc)] Source #

Orphan instances

Terse (PParamsUpdate (AllegraEra c)) Source # 
Instance details

Terse (PParamsUpdate (AlonzoEra c)) Source # 
Instance details

Terse (PParamsUpdate (BabbageEra c)) Source # 
Instance details

Terse (PParamsUpdate (ConwayEra c)) Source # 
Instance details

Terse (PParamsUpdate (MaryEra c)) Source # 
Instance details

Terse (PParamsUpdate (ShelleyEra c)) Source # 
Instance details

Terse (KeyHash 'Genesis c) Source # 
Instance details

Methods

terseKeyHash 'Genesis c → String Source #