-
-
Couldn't load subscription status.
- Fork 1.8k
Test nix build --json return output paths in floating CA case
#4589
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
Conversation
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
To make the types more explicit (and also prevent a couple of unneeded back-and-forths), could it make sense to make build return a vector of RealisedPath?
|
I marked this as stale due to inactivity. → More info |
d81696f to
40a18b6
Compare
nix build --json return output paths in floating CA casenix build --json return output paths in floating CA case
|
This is now just a test, and ready to go. |
|
Regarding |
|
@edolstra would you prefer I flatten this, or put those in the subdir? |
|
@Ericson2314 Yes please. |
|
Oh i meant to replace But I'll do it the way you said for now. |
40a18b6 to
12ac77b
Compare
12ac77b to
f3c980c
Compare
|
Found a bunch of testing infra that indeed already exists since I first wrote. This became a lot easier now! |
|
I marked this as stale due to inactivity. → More info |
f3c980c to
3ada1ad
Compare
|
|
||
| set -o pipefail | ||
|
|
||
| # https://github.com/NixOS/nix/issues/6572 |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
These tests do not yet work with CA derivations, so I pulled them out from tests/build.sh into their own file.
| @@ -0,0 +1,9 @@ | |||
| source common.sh | |||
|
|
|||
| testNormalization () { | |||
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This test also do not yet work with CA derivations, so I pulled it out from tests/build.sh into its own file.
Adding a test to ensure there is no regression. The tests that are split out of `tests/build.sh` are ones that don't yet work with CA derivation. I have not yet evaluated whether they should or not. This behavior, reported missing in issue NixOS#4661, already got fixed in PR NixOS#4818, but didn't get a test case then.
3ada1ad to
55016b6
Compare
|
|
||
| export NIX_TESTS_CA_BY_DEFAULT=1 | ||
| cd .. | ||
| source ./build.sh |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This is us running the (remaining) tests/build.sh tests, except with CA derivations enabled by default. This shows that this functionality works with or with or without CA derivations.
|
This pull request has been mentioned on NixOS Discourse. There might be relevant details there: https://discourse.nixos.org/t/2023-02-10-nix-team-meeting-minutes-31/25438/1 |
Motivation
Adding a test to ensure there is no regression.
The tests that are split out of
tests/build.share ones that don't yet work with CA derivation. I have not yet evaluated whether they should or not.Context
This behavior, reported missing in issue #4661, already got fixed in PR #4818, but didn't get a test case then.
Checklist for maintainers
Maintainers: tick if completed or explain if not relevant
tests/**.shsrc/*/teststests/nixos/*