mirror of
https://github.com/NixOS/nixpkgs.git
synced 2024-11-23 07:23:20 +00:00
23 lines
426 B
Nix
23 lines
426 B
Nix
|
import ./make-test-python.nix ({ ... }:
|
||
|
let
|
||
|
machineName = "machine";
|
||
|
settingName = "prefix";
|
||
|
settingValue = "/some/path";
|
||
|
in
|
||
|
{
|
||
|
name = "npmrc";
|
||
|
|
||
|
nodes."${machineName}".programs.npm = {
|
||
|
enable = true;
|
||
|
npmrc = ''
|
||
|
${settingName} = ${settingValue}
|
||
|
'';
|
||
|
};
|
||
|
|
||
|
testScript = ''
|
||
|
${machineName}.start()
|
||
|
|
||
|
assert ${machineName}.succeed("npm config get ${settingName}") == "${settingValue}\n"
|
||
|
'';
|
||
|
})
|