tests/functional/repl: Characterize side effecting print behavior

Reported on matrix by aleksana:
https://matrix.to/#/!VRULIdgoKmKPzJZzjj:nixos.org/$7wZp5lUDTd-_u6MYo8kWWcysjtqTiQqP8dLI0RDNVVM?via=nixos.org&via=matrix.org&via=nixos.dev
This commit is contained in:
Robert Hensing 2024-07-14 13:42:12 +02:00
parent b230c01f73
commit ece334b532
3 changed files with 61 additions and 0 deletions

View file

@ -0,0 +1,33 @@
Nix <nix version>
Type :? for help.
Added <number omitted> variables.
{
homepage = "https://example.com";
}
{ homepage = "https://example.com"; }
{
layerOne = { ... };
}
{
layerOne = { ... };
}
[
"https://example.com"
]
[ "https://example.com" ]
[
[ ... ]
]
[
[ ... ]
]

View file

@ -0,0 +1,9 @@
:l pretty-print-idempotent.nix
oneDeep
oneDeep
twoDeep
twoDeep
oneDeepList
oneDeepList
twoDeepList
twoDeepList

View file

@ -0,0 +1,19 @@
{
oneDeep = {
homepage = "https://" + "example.com";
};
twoDeep = {
layerOne = {
homepage = "https://" + "example.com";
};
};
oneDeepList = [
("https://" + "example.com")
];
twoDeepList = [
[
("https://" + "example.com")
]
];
}