diff options
Diffstat (limited to 'tests/host_adapter_contract.lua')
| -rw-r--r-- | tests/host_adapter_contract.lua | 16 |
1 files changed, 3 insertions, 13 deletions
diff --git a/tests/host_adapter_contract.lua b/tests/host_adapter_contract.lua index ff369d5..5d22a85 100644 --- a/tests/host_adapter_contract.lua +++ b/tests/host_adapter_contract.lua @@ -11,19 +11,9 @@ local composition_root = require("clever_f.composition_root") local domain = require("clever_f.domain") local host_adapter = require("clever_f.host_adapter") -local function same(expected, actual, message) - if expected ~= actual then - error((message or "values differ") - .. ": expected " .. tostring(expected) - .. ", got " .. tostring(actual), 2) - end -end - -local function truthy(value, message) - if not value then - error(message or "value must be true", 2) - end -end +local assertions = dofile(root .. "/tests/assertions.lua") +local same = assertions.same +local truthy = assertions.truthy local exercised = {} local host = host_adapter.new() |
