-
-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Add Nix support to language tests (#10)
* adapt language_tests to nix * add nix to language test makefile * ci: test nix on language test * ci: install nix before test-projects * fix outdated comment * fix comment in nix ffi
- Loading branch information
Showing
6 changed files
with
373 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,15 @@ | ||
let | ||
print = msg: builtins.trace msg null; | ||
append = a: b: a + b; | ||
toString = builtins.toJSON; | ||
fileExists = | ||
f: | ||
let | ||
# ./. is relative to this file in the build directory (language/build/dev/nix/ffi_nix.nix) | ||
# In other targets, this would be relative to 'language/', so let's go back there | ||
absPath = if builtins.isString f && builtins.substring 0 1 f != "/" then ./../../../../${f} else f; | ||
in builtins.pathExists absPath; | ||
halt = code: if code == 0 then null else builtins.abort (toString code); | ||
toDynamic = x: x; | ||
in | ||
{ inherit print append toString fileExists halt toDynamic; } |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.