From 8e3d03e55793b49dc6844b23877c84d111e8d7d1 Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?Roman=20Smr=C5=BE?= Date: Sat, 13 Sep 2025 21:35:02 +0200 Subject: Get call stack information from function application --- src/Run.hs | 10 +++++----- 1 file changed, 5 insertions(+), 5 deletions(-) (limited to 'src/Run.hs') diff --git a/src/Run.hs b/src/Run.hs index 3ecd7d4..2e5d641 100644 --- a/src/Run.hs +++ b/src/Run.hs @@ -208,8 +208,8 @@ runStep = \case Flush p regex -> do atomicallyTest $ flushProcessOutput p regex - Guard line vars expr -> do - testStepGuard line vars expr + Guard stack expr -> do + testStepGuard stack expr DisconnectNode node inner -> do withDisconnectedUp (nodeUpstream node) $ runStep inner @@ -343,6 +343,6 @@ expect sline p (Traced trace re) tvars inner = do Nothing -> exprFailed (T.pack "expect") (CallStack [ ( sline, trace ) ]) (Just $ procName p) -testStepGuard :: SourceLine -> EvalTrace -> Bool -> TestRun () -testStepGuard sline vars x = do - when (not x) $ exprFailed (T.pack "guard") (CallStack [ ( sline, vars ) ]) Nothing +testStepGuard :: CallStack -> Bool -> TestRun () +testStepGuard stack x = do + when (not x) $ exprFailed (T.pack "guard") stack Nothing -- cgit v1.2.3