haskoin-core-0.19.0: Bitcoin & Bitcoin Cash library for Haskell
CopyrightNo rights reserved
LicenseMIT
Maintainerjprupp@protonmail.ch
Stabilityexperimental
PortabilityPOSIX
Safe HaskellNone
LanguageHaskell2010

Haskoin.Util.Arbitrary.Transaction

Description

 
Synopsis

Documentation

newtype TestCoin Source #

Wrapped coin value for testing.

Constructors

TestCoin 

Fields

Instances

Instances details
Eq TestCoin Source # 
Instance details

Defined in Haskoin.Util.Arbitrary.Transaction

Show TestCoin Source # 
Instance details

Defined in Haskoin.Util.Arbitrary.Transaction

Coin TestCoin Source # 
Instance details

Defined in Haskoin.Util.Arbitrary.Transaction

arbitraryTxHash :: Gen TxHash Source #

Arbitrary transaction hash (for non-existent transaction).

arbitrarySatoshi :: Network -> Gen TestCoin Source #

Arbitrary amount of Satoshi as Word64 (Between 1 and 21e14)

arbitraryTx :: Network -> Gen Tx Source #

Arbitrary transaction. Can be regular or with witnesses.

arbitraryLegacyTx :: Network -> Gen Tx Source #

Arbitrary regular transaction.

arbitraryWitnessTx :: Network -> Gen Tx Source #

Arbitrary witness transaction (witness data is fake).

arbitraryWLTx :: Network -> Bool -> Gen Tx Source #

Arbitrary witness or legacy transaction.

arbitraryAddrOnlyTx :: Network -> Gen Tx Source #

Arbitrary transaction containing only inputs of type SpendPKHash, SpendScriptHash (multisig) and outputs of type PayPKHash and PaySH. Only compressed public keys are used.

arbitraryAddrOnlyTxFull :: Network -> Gen Tx Source #

Like arbitraryAddrOnlyTx without empty signatures in the inputs.

arbitraryAddrOnlyTxIn :: Network -> Gen TxIn Source #

Arbitrary TxIn that can only be of type SpendPKHash or SpendScriptHash (multisig). Only compressed public keys are used.

arbitraryAddrOnlyTxOut :: Network -> Gen TxOut Source #

Arbitrary TxOut that can only be of type PayPKHash or PaySH.

arbitrarySigInput :: Network -> Gen (SigInput, [SecKeyI]) Source #

Arbitrary SigInput with the corresponding private keys used to generate the ScriptOutput or RedeemScript.

arbitraryInputStuff :: Network -> Gen (Word64, OutPoint, SigHash) Source #

Arbitrary value, out point and sighash for an input.

arbitrarySigningData :: Network -> Gen (Tx, [SigInput], [SecKeyI]) Source #

Arbitrary Tx (empty TxIn), SigInputs and private keys that can be passed to signTx or detSignTx to fully sign the Tx.

arbitraryEmptyTx :: Network -> Gen Tx Source #

Arbitrary transaction with empty inputs.

arbitraryPartialTxs :: Network -> Gen ([Tx], [(ScriptOutput, Word64, OutPoint, Int, Int)]) Source #

Arbitrary partially-signed transactions.