mirror of
https://github.com/NixOS/nix.git
synced 2025-11-21 01:39:36 +01:00
Merge pull request #14471 from obsidiansystems/derivation-options-json-test
FIx `DerivationOptions` JSON and clean up unit tests
This commit is contained in:
commit
34c77ffe38
11 changed files with 578 additions and 300 deletions
46
src/libstore-tests/data/derivation/ca/all_set.json
Normal file
46
src/libstore-tests/data/derivation/ca/all_set.json
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
{
|
||||
"additionalSandboxProfile": "sandcastle",
|
||||
"allowLocalNetworking": true,
|
||||
"allowSubstitutes": false,
|
||||
"exportReferencesGraph": {
|
||||
"refs1": [
|
||||
"/164j69y6zir9z0339n8pjigg3rckinlr77bxsavzizdaaljb7nh9"
|
||||
],
|
||||
"refs2": [
|
||||
"/nix/store/qnml92yh97a6fbrs2m5qg5cqlc8vni58-bar.drv"
|
||||
]
|
||||
},
|
||||
"impureEnvVars": [
|
||||
"UNICORN"
|
||||
],
|
||||
"impureHostDeps": [
|
||||
"/usr/bin/ditto"
|
||||
],
|
||||
"noChroot": true,
|
||||
"outputChecks": {
|
||||
"forAllOutputs": {
|
||||
"allowedReferences": [
|
||||
"/164j69y6zir9z0339n8pjigg3rckinlr77bxsavzizdaaljb7nh9"
|
||||
],
|
||||
"allowedRequisites": [
|
||||
"/0nr45p69vn6izw9446wsh9bng9nndhvn19kpsm4n96a5mycw0s4z"
|
||||
],
|
||||
"disallowedReferences": [
|
||||
"/0nyw57wm2iicnm9rglvjmbci3ikmcp823czdqdzdcgsnnwqps71g"
|
||||
],
|
||||
"disallowedRequisites": [
|
||||
"/07f301yqyz8c6wf6bbbavb2q39j4n8kmcly1s09xadyhgy6x2wr8"
|
||||
],
|
||||
"ignoreSelfRefs": true,
|
||||
"maxClosureSize": null,
|
||||
"maxSize": null
|
||||
}
|
||||
},
|
||||
"passAsFile": [],
|
||||
"preferLocalBuild": true,
|
||||
"requiredSystemFeatures": [
|
||||
"rainbow",
|
||||
"uid-range"
|
||||
],
|
||||
"unsafeDiscardReferences": {}
|
||||
}
|
||||
|
|
@ -0,0 +1,66 @@
|
|||
{
|
||||
"additionalSandboxProfile": "sandcastle",
|
||||
"allowLocalNetworking": true,
|
||||
"allowSubstitutes": false,
|
||||
"exportReferencesGraph": {
|
||||
"refs1": [
|
||||
"/164j69y6zir9z0339n8pjigg3rckinlr77bxsavzizdaaljb7nh9"
|
||||
],
|
||||
"refs2": [
|
||||
"/nix/store/qnml92yh97a6fbrs2m5qg5cqlc8vni58-bar.drv"
|
||||
]
|
||||
},
|
||||
"impureEnvVars": [
|
||||
"UNICORN"
|
||||
],
|
||||
"impureHostDeps": [
|
||||
"/usr/bin/ditto"
|
||||
],
|
||||
"noChroot": true,
|
||||
"outputChecks": {
|
||||
"perOutput": {
|
||||
"bin": {
|
||||
"allowedReferences": null,
|
||||
"allowedRequisites": null,
|
||||
"disallowedReferences": [
|
||||
"/0nyw57wm2iicnm9rglvjmbci3ikmcp823czdqdzdcgsnnwqps71g"
|
||||
],
|
||||
"disallowedRequisites": [
|
||||
"/07f301yqyz8c6wf6bbbavb2q39j4n8kmcly1s09xadyhgy6x2wr8"
|
||||
],
|
||||
"ignoreSelfRefs": false,
|
||||
"maxClosureSize": null,
|
||||
"maxSize": null
|
||||
},
|
||||
"dev": {
|
||||
"allowedReferences": null,
|
||||
"allowedRequisites": null,
|
||||
"disallowedReferences": [],
|
||||
"disallowedRequisites": [],
|
||||
"ignoreSelfRefs": false,
|
||||
"maxClosureSize": 5909,
|
||||
"maxSize": 789
|
||||
},
|
||||
"out": {
|
||||
"allowedReferences": [
|
||||
"/164j69y6zir9z0339n8pjigg3rckinlr77bxsavzizdaaljb7nh9"
|
||||
],
|
||||
"allowedRequisites": [
|
||||
"/0nr45p69vn6izw9446wsh9bng9nndhvn19kpsm4n96a5mycw0s4z"
|
||||
],
|
||||
"disallowedReferences": [],
|
||||
"disallowedRequisites": [],
|
||||
"ignoreSelfRefs": false,
|
||||
"maxClosureSize": null,
|
||||
"maxSize": null
|
||||
}
|
||||
}
|
||||
},
|
||||
"passAsFile": [],
|
||||
"preferLocalBuild": true,
|
||||
"requiredSystemFeatures": [
|
||||
"rainbow",
|
||||
"uid-range"
|
||||
],
|
||||
"unsafeDiscardReferences": {}
|
||||
}
|
||||
46
src/libstore-tests/data/derivation/ia/all_set.json
Normal file
46
src/libstore-tests/data/derivation/ia/all_set.json
Normal file
|
|
@ -0,0 +1,46 @@
|
|||
{
|
||||
"additionalSandboxProfile": "sandcastle",
|
||||
"allowLocalNetworking": true,
|
||||
"allowSubstitutes": false,
|
||||
"exportReferencesGraph": {
|
||||
"refs1": [
|
||||
"/nix/store/p0hax2lzvjpfc2gwkk62xdglz0fcqfzn-foo"
|
||||
],
|
||||
"refs2": [
|
||||
"/nix/store/vj2i49jm2868j2fmqvxm70vlzmzvgv14-bar.drv"
|
||||
]
|
||||
},
|
||||
"impureEnvVars": [
|
||||
"UNICORN"
|
||||
],
|
||||
"impureHostDeps": [
|
||||
"/usr/bin/ditto"
|
||||
],
|
||||
"noChroot": true,
|
||||
"outputChecks": {
|
||||
"forAllOutputs": {
|
||||
"allowedReferences": [
|
||||
"/nix/store/p0hax2lzvjpfc2gwkk62xdglz0fcqfzn-foo"
|
||||
],
|
||||
"allowedRequisites": [
|
||||
"/nix/store/z0rjzy29v9k5qa4nqpykrbzirj7sd43v-foo-dev"
|
||||
],
|
||||
"disallowedReferences": [
|
||||
"/nix/store/r5cff30838majxk5mp3ip2diffi8vpaj-bar"
|
||||
],
|
||||
"disallowedRequisites": [
|
||||
"/nix/store/9b61w26b4avv870dw0ymb6rw4r1hzpws-bar-dev"
|
||||
],
|
||||
"ignoreSelfRefs": true,
|
||||
"maxClosureSize": null,
|
||||
"maxSize": null
|
||||
}
|
||||
},
|
||||
"passAsFile": [],
|
||||
"preferLocalBuild": true,
|
||||
"requiredSystemFeatures": [
|
||||
"rainbow",
|
||||
"uid-range"
|
||||
],
|
||||
"unsafeDiscardReferences": {}
|
||||
}
|
||||
24
src/libstore-tests/data/derivation/ia/defaults.json
Normal file
24
src/libstore-tests/data/derivation/ia/defaults.json
Normal file
|
|
@ -0,0 +1,24 @@
|
|||
{
|
||||
"additionalSandboxProfile": "",
|
||||
"allowLocalNetworking": false,
|
||||
"allowSubstitutes": true,
|
||||
"exportReferencesGraph": {},
|
||||
"impureEnvVars": [],
|
||||
"impureHostDeps": [],
|
||||
"noChroot": false,
|
||||
"outputChecks": {
|
||||
"forAllOutputs": {
|
||||
"allowedReferences": null,
|
||||
"allowedRequisites": null,
|
||||
"disallowedReferences": [],
|
||||
"disallowedRequisites": [],
|
||||
"ignoreSelfRefs": true,
|
||||
"maxClosureSize": null,
|
||||
"maxSize": null
|
||||
}
|
||||
},
|
||||
"passAsFile": [],
|
||||
"preferLocalBuild": false,
|
||||
"requiredSystemFeatures": [],
|
||||
"unsafeDiscardReferences": {}
|
||||
}
|
||||
|
|
@ -0,0 +1,66 @@
|
|||
{
|
||||
"additionalSandboxProfile": "sandcastle",
|
||||
"allowLocalNetworking": true,
|
||||
"allowSubstitutes": false,
|
||||
"exportReferencesGraph": {
|
||||
"refs1": [
|
||||
"/nix/store/p0hax2lzvjpfc2gwkk62xdglz0fcqfzn-foo"
|
||||
],
|
||||
"refs2": [
|
||||
"/nix/store/vj2i49jm2868j2fmqvxm70vlzmzvgv14-bar.drv"
|
||||
]
|
||||
},
|
||||
"impureEnvVars": [
|
||||
"UNICORN"
|
||||
],
|
||||
"impureHostDeps": [
|
||||
"/usr/bin/ditto"
|
||||
],
|
||||
"noChroot": true,
|
||||
"outputChecks": {
|
||||
"perOutput": {
|
||||
"bin": {
|
||||
"allowedReferences": null,
|
||||
"allowedRequisites": null,
|
||||
"disallowedReferences": [
|
||||
"/nix/store/r5cff30838majxk5mp3ip2diffi8vpaj-bar"
|
||||
],
|
||||
"disallowedRequisites": [
|
||||
"/nix/store/9b61w26b4avv870dw0ymb6rw4r1hzpws-bar-dev"
|
||||
],
|
||||
"ignoreSelfRefs": false,
|
||||
"maxClosureSize": null,
|
||||
"maxSize": null
|
||||
},
|
||||
"dev": {
|
||||
"allowedReferences": null,
|
||||
"allowedRequisites": null,
|
||||
"disallowedReferences": [],
|
||||
"disallowedRequisites": [],
|
||||
"ignoreSelfRefs": false,
|
||||
"maxClosureSize": 5909,
|
||||
"maxSize": 789
|
||||
},
|
||||
"out": {
|
||||
"allowedReferences": [
|
||||
"/nix/store/p0hax2lzvjpfc2gwkk62xdglz0fcqfzn-foo"
|
||||
],
|
||||
"allowedRequisites": [
|
||||
"/nix/store/z0rjzy29v9k5qa4nqpykrbzirj7sd43v-foo-dev"
|
||||
],
|
||||
"disallowedReferences": [],
|
||||
"disallowedRequisites": [],
|
||||
"ignoreSelfRefs": false,
|
||||
"maxClosureSize": null,
|
||||
"maxSize": null
|
||||
}
|
||||
}
|
||||
},
|
||||
"passAsFile": [],
|
||||
"preferLocalBuild": true,
|
||||
"requiredSystemFeatures": [
|
||||
"rainbow",
|
||||
"uid-range"
|
||||
],
|
||||
"unsafeDiscardReferences": {}
|
||||
}
|
||||
|
|
@ -0,0 +1,16 @@
|
|||
{
|
||||
"additionalSandboxProfile": "",
|
||||
"allowLocalNetworking": false,
|
||||
"allowSubstitutes": true,
|
||||
"exportReferencesGraph": {},
|
||||
"impureEnvVars": [],
|
||||
"impureHostDeps": [],
|
||||
"noChroot": false,
|
||||
"outputChecks": {
|
||||
"perOutput": {}
|
||||
},
|
||||
"passAsFile": [],
|
||||
"preferLocalBuild": false,
|
||||
"requiredSystemFeatures": [],
|
||||
"unsafeDiscardReferences": {}
|
||||
}
|
||||
Loading…
Add table
Add a link
Reference in a new issue