apropos-tx setup

This commit is contained in:
Emily Martins 2022-03-09 19:32:13 +01:00
parent b9094499ff
commit 5bae354268
17 changed files with 695 additions and 54 deletions

42
agora-bench/Main.hs Normal file
View file

@ -0,0 +1,42 @@
module Main (main) where
import Prelude
--------------------------------------------------------------------------------
import Plutus.V1.Ledger.Value qualified as Value
--------------------------------------------------------------------------------
import Plutarch.Benchmark
--------------------------------------------------------------------------------
import Agora.AuthorityToken (
AuthorityToken (AuthorityToken),
authorityTokenPolicy,
)
import Agora.SafeMoney (LQ)
import Agora.Stake (
Stake (Stake),
stakePolicy,
stakeValidator,
)
--------------------------------------------------------------------------------
main :: IO ()
main = do
benchMain benchmarks
benchmarks :: [NamedBenchmark]
benchmarks =
benchGroup
"full_scripts"
[ bench "authorityTokenPolicy" $ authorityTokenPolicy authorityToken
, bench "stakePolicy" $ stakePolicy (Stake @LQ)
, bench "stakeValidator" $ stakeValidator (Stake @LQ)
]
authorityToken :: AuthorityToken
authorityToken = AuthorityToken (Value.assetClass "" "")