Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

stdlib: Fix refactor typo #1660

Merged
merged 2 commits into from
Oct 1, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion share/wake/lib/system/job.wake
Original file line number Diff line number Diff line change
Expand Up @@ -153,7 +153,7 @@ def runAlways cmd env dir stdin res uusage finputs foutputs vis keep run echo st
run job (Pass (RunnerInput label cmd vis env dir stdin res prefix usage isatty finputs foutputs))

def final _ = match output
Fail e -> primJobFailLaunch job e
Fail e -> primJobFailFinish job e
Pass (RunnerOutput inputs outputs cleanable reality) ->
def hashedOutputs =
outputs
Expand Down
1 change: 1 addition & 0 deletions tests/standard-library/runner/.wakeroot
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
{"log_header":"", "log_header_source_width":0}
9 changes: 9 additions & 0 deletions tests/standard-library/runner/pass.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
#! /bin/sh

WAKE="${1:+$1/wake}"

# Since we are writing jobs to the database in this test we should clear it for each run if it
# happens to exist from a previous run
rm -f wake.db wake.log

"${WAKE:-wake}" --stdout=warning,report testRunnerFailFinish
1 change: 1 addition & 0 deletions tests/standard-library/runner/stdout
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
False
13 changes: 13 additions & 0 deletions tests/standard-library/runner/test.wake
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
export def testRunnerFailFinish _ =
def run job input =
def (Runner _ virtRun) = virtualRunner
require Pass _ = virtRun job (Pass input)

# Force a failure outside of the actual job
failWithError "Mark job as failure"

def testRunner = makeRunner "" run

makeExecPlan ("<test>", Nil) Nil
| runJobWith testRunner
| isJobOk
Loading