nim-dagger/tests/codex/helpers/mocksalesagent.nim
Adam Uhlíř 44981d24d0
perf: contract storage optimizations (#1094)
* perf: contract storage optimizations

* Apply optimization changes

* Apply optimizing parameters sizing

* Update codex-contracts-eth

* bump latest changes in contracts branch

* Change requestDurationLimit to uint64

* fix tests

* fix tests

---------

Co-authored-by: Arnaud <arnaud@status.im>
Co-authored-by: Eric <5089238+emizzle@users.noreply.github.com>
2025-02-20 07:11:06 +00:00

18 lines
452 B
Nim

import pkg/codex/sales/salesagent
type MockSalesAgent = ref object of SalesAgent
fulfilledCalled*: bool
failedCalled*: bool
slotFilledCalled*: bool
method onFulfilled*(agent: SalesAgent, requestId: RequestId) =
fulfilledCalled = true
method onFailed*(agent: SalesAgent, requestId: RequestId) =
failedCalled = true
method onSlotFilled*(
agent: SalesAgent, requestId: RequestId, slotIndex: uint64
) {.base.} =
slotFilledCalled = true