aboutsummaryrefslogtreecommitdiff
path: root/tests
AgeCommit message (Collapse)Author
2022-09-28tests/build-dry: re-enable some testSolene Rapenne
2022-09-26Merge pull request #7043 from edolstra/installer-testEelco Dolstra
Add an installer test
2022-09-26Quote URLsEelco Dolstra
2022-09-26Remove FIXMEEelco Dolstra
2022-09-22Dodge "trusted" vs "trustworthy" by being explicit John Ericson
Hopefully this is best!
2022-09-22"valid signature" -> "trustworthy signature"John Ericson
I just had a colleague get confused by the previous phrase for good reason. "valid" sounds like an *objective* criterion, e.g. and *invalid signature* would be one that would be trusted by no one, e.g. because it misformatted or something. What is actually going is that there might be a signature which is perfectly valid to *someone else*, but not to the user, because they don't trust the corresponding public key. This is a *subjective* criterion, because it depends on the arbitrary and personal choice of which public keys to trust. I therefore think "trustworthy" is a better adjective to use. Whether something is worthy of trust is clearly subjective, and then "trust" within that word nicely evokes `trusted-public-keys` and friends.
2022-09-15Fix evaluationEelco Dolstra
2022-09-15Add RHEL 9Eelco Dolstra
2022-09-15Disable Ubuntu 14.04Eelco Dolstra
2022-09-15Add RHEL 7/8Eelco Dolstra
2022-09-15Use libvirt imageEelco Dolstra
2022-09-15Remove pre-release Ubuntu 22.10Eelco Dolstra
2022-09-15Add Ubuntu 22.04 LTSEelco Dolstra
2022-09-15Make cross product of images and testsEelco Dolstra
2022-09-15Test buildingEelco Dolstra
2022-09-14Get Ubuntu 22.10 to workEelco Dolstra
2022-09-14Enable daemon installation test on FedoraEelco Dolstra
2022-09-14Add Fedora 36Eelco Dolstra
2022-09-14Add an installer testEelco Dolstra
This runs the installer in a QEMU VM. Unlike the old installer test that ran inside a declaratively built RedHat/Debian image, this uses an image from Vagrant.
2022-09-01Revert "Merge pull request #6621 from Kha/nested-follows"Eelco Dolstra
This reverts commit c530cda345377370c52a616d608de88b9d67cd40, reversing changes made to 4adcdff5c1d5f9f135c4ec61d690890443c19e6a.
2022-08-28Fix overlapping flake followsSebastian Ullrich
2022-08-28Fix nested flake input overridesSebastian Ullrich
2022-08-17Fix onErrorEelco Dolstra
2022-08-03tests/check.sh: add nix3-build check testFélix Baylac-Jacqué
2022-07-18Merge pull request #6784 from tweag/completion-testThéophane Hufschmitt
Add some tests for the CLI completion
2022-07-15Remove `computed-derivations` experimental featureJohn Ericson
We don't need it yet.
2022-07-14Fix bug, test more, document moreJohn Ericson
2022-07-14Merge remote-tracking branch 'upstream/master' into indexed-store-path-outputsJohn Ericson
2022-07-14On test failures, print a bash stack traceEelco Dolstra
This makes it easier to identify what command failed. It looks like: follow-paths.sh: test failed at: main in follow-paths.sh:54
2022-07-13Split off 'nix flake check' testsEelco Dolstra
2022-07-13Move flake-searching.sh and make it less dependent on gitEelco Dolstra
2022-07-13Move flake-local-settings.shEelco Dolstra
2022-07-13Move the 'nix bundle' testsEelco Dolstra
Note: these were previously not actually called.
2022-07-13Split off following paths testsEelco Dolstra
2022-07-13Split off 'nix flake init' testsEelco Dolstra
2022-07-13Split off the circular flake import testsEelco Dolstra
2022-07-13Split off the Mercurial flake testsEelco Dolstra
2022-07-13Move flakes tests to a subdirectoryEelco Dolstra
2022-07-13Merge pull request #6797 from edolstra/overrides-checkEelco Dolstra
Simplify the check for overrides on non-existent inputs
2022-07-13tests/flakes.sh: Make sure flake7 is cleanEelco Dolstra
Cherry-picked from the lazy-trees branch, where we no longer write a lock file if any of the inputs is dirty.
2022-07-13Simplify the check for overrides on non-existent inputsEelco Dolstra
2022-07-13Add some more completion testsThéophane Hufschmitt
- Test another command than `build` - Test with two input flakes
2022-07-13Fix the “out of order” completion testThéophane Hufschmitt
`--override-input` id snarky because it takes two arguments, so it doesn't play well when completed in the middle of the CLI (since the argument just after gets interpreted as its second argument). So use `--update-input` instead
2022-07-12Turn error for non-existant follows into a warningMaximilian Bosch
2022-07-12flakes: throw an error if `follows`-declaration for an input is invalidMaximilian Bosch
I recently got fairly confused why the following expression didn't have any effect { description = "Foobar"; inputs.sops-nix = { url = github:mic92/sops-nix; inputs.nixpkgs_22_05.follows = "nixpkgs"; }; } until I found out that the input was called `nixpkgs-22_05` (please note the dash vs. underscore). IMHO it's not a good idea to not throw an error in that case and probably leave end-users rather confused, so I implemented a small check for that which basically checks whether `follows`-declaration from overrides actually have corresponding inputs in the transitive flake. In fact this was done by accident already in our own test-suite where the removal of a `follows` was apparently forgotten[1]. Since the key of the `std::map` that holds the `overrides` is a vector and we have to find the last element of each vector (i.e. the override) this has to be done with a for loop in O(n) complexity with `n` being the total amount of overrides (which shouldn't be that large though). Please note that this doesn't work with nested expressions, i.e. inputs.fenix.inputs.nixpkgs.follows = "..."; which is a known problem[2]. For the expression demonstrated above, an error like this will be thrown: error: sops-nix has a `follows'-declaration for a non-existant input nixpkgs_22_05! [1] 2664a216e57169ec57d7f51be1b8383c1be83fd5 [2] https://github.com/NixOS/nix/issues/5790
2022-07-12Test the tilde expansion for the flake completionThéophane Hufschmitt
Also add a disabled test for when the `--override-input` flag comes *before* the flake ref
2022-07-12Harden the comparisons in the completion testThéophane Hufschmitt
- Don't use `printf` for the expected result, but just use bash's `$' '` litteral strings - Quote the `nix` call result - Invert the order in the comparisons (just because it feels more natural)
2022-07-12Fix the name of the completions testThéophane Hufschmitt
2022-07-12Add some tests for the CLI completionThéophane Hufschmitt
2022-07-05Add builtins.traceVerboseGytis Ivaskevicius
Co-Authored-By: Silvan Mosberger <contact@infinisil.com> Add builtins.traceVerbose tests