tests: add option test.stubs
This option provides a more convenient way to overlay dummy packages. It also adds a function `config.lib.test.mkStubPackage` that can, e.g., be used for `package` options.
This commit is contained in:
parent
b0651cc217
commit
cb09a968e9
159 changed files with 753 additions and 981 deletions
|
|
@ -79,14 +79,10 @@ in {
|
|||
}
|
||||
];
|
||||
|
||||
nixpkgs.overlays = [
|
||||
(self: super: {
|
||||
git-lfs = pkgs.writeScriptBin "dummy-git-lfs" "";
|
||||
delta = pkgs.writeScriptBin "dummy-delta" "" // {
|
||||
outPath = "@delta@";
|
||||
};
|
||||
})
|
||||
];
|
||||
test.stubs = {
|
||||
git-lfs = { };
|
||||
delta = { };
|
||||
};
|
||||
|
||||
nmt.script = ''
|
||||
assertFileExists home-files/.config/git/config
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue