diff options
Diffstat (limited to 'tests/receptor.rs')
| -rw-r--r-- | tests/receptor.rs | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/tests/receptor.rs b/tests/receptor.rs index 843eaa6..656ed1f 100644 --- a/tests/receptor.rs +++ b/tests/receptor.rs @@ -427,6 +427,9 @@ fn pack_from_sources() { "items": { "a.key": { "source": { "file": "key" } }, "a.pub": { "source": { "command": [lister, "show", "${file:key}"] } }, + // A placeholder in parentheses, as a whole value: text, its trailing line + // breaks removed. + "extra": { "source": format!("$(cmd: {lister} show extra)") }, } }); let path = host.root.join("sources.json"); @@ -442,6 +445,10 @@ fn pack_from_sources() { std::fs::read(out.join("channels/secrets/a.pub")).unwrap(), b"pub-of-K\n\n" ); + assert_eq!( + std::fs::read(out.join("channels/secrets/extra")).unwrap(), + b"pub-of-extra" + ); // The pair validator compares without trailing line breaks ($(cat)). let plan = host.apply(&schema, &out); assert!(plan.accepted, "{plan:?}"); |
