Module

Contract.Test.E2E

Re-exports from Ctl.Internal.Test.E2E.Feedback.Hooks

#e2eFeedbackHooks

Re-exports from Ctl.Internal.Test.E2E.Options

#parseCliArgs

parseCliArgs :: Effect E2ECommand

Parse CLI arguments to get E2ECommand that can be run by runE2E

Re-exports from Ctl.Internal.Test.E2E.Route

#E2ETestName

type E2ETestName = String

A name of some particular test. Used in the URL

#E2EConfigName

type E2EConfigName = String

A name of some particular E2E test environment (ContractParams and possible CIP-30 mock). Used in the URL for routing

#route

route :: Map E2EConfigName (ContractParams /\ (Maybe String)) -> Map E2ETestName (Contract Unit) -> Effect Unit

Serves given examples conditionally, depending on the URL query part.

The structure of the query string should be one of:

E2EConfigName:E2ETestName
E2EConfigName:E2ETestName:PrivatePaymentKeyCborHex
E2EConfigName:E2ETestName:PrivatePaymentKeyCborHex:PrivateStakeKeyCborHex

Examples:

gero:MintsMultiple
eternl:AlwaysSucceeds:58200b07c066ba037344acee5431e6df41f6034bf1c5ffd6f803751e356807c6a209
nami-mock:MintsMultiple:58200b07c066ba037344acee5431e6df41f6034bf1c5ffd6f803751e356807c6a209:5820f0db841df6c7fbc4506c58fad6676db0354a02dfd26efca445715a8adeabc338

In case that for the specified E2EConfigName a WalletMock is provided (present in the Map), but no private keys are given, this function assumes that the test is running on a local cluster, and pre-funded keys from the cluster should be used. If there's no local cluster, an error will be thrown.

Re-exports from Ctl.Internal.Test.E2E.Runner

#runE2ETests

runE2ETests :: TestOptions -> E2ETestRuntime -> Aff Unit

Implements run command

#runE2ECommand

runE2ECommand :: E2ECommand -> Aff Unit

The entry point to the implementation of E2E tests.

Modules