diff options
author | Florian Klink <flokli@flokli.de> | 2024-01-24T14·15+0200 |
---|---|---|
committer | clbot <clbot@tvl.fyi> | 2024-01-25T12·06+0000 |
commit | e0a1c03b2471271fc96690b3dc5dd5423f93fa42 (patch) | |
tree | b6af86c4217151e901a78a1730c41be213a8dfca /tvix/eval | |
parent | 0b3245211ec32ec222830ba5593a762a2cbf3407 (diff) |
feat(tvix/eval/tvix_tests): add some more xml tests r/7451
https: //cl.tvl.fyi/c/depot/+/10686/comment/ea582dae_574d6c3f/ Change-Id: Iac74abbf2f2e0327bc9ddf9dcc6bb43f918a1c63 Reviewed-on: https://cl.tvl.fyi/c/depot/+/10689 Autosubmit: flokli <flokli@flokli.de> Reviewed-by: tazjin <tazjin@tvl.su> Tested-by: BuildkiteCI
Diffstat (limited to 'tvix/eval')
-rw-r--r-- | tvix/eval/src/tests/tvix_tests/eval-okay-xml.exp.xml | 41 | ||||
-rw-r--r-- | tvix/eval/src/tests/tvix_tests/eval-okay-xml.nix | 7 |
2 files changed, 48 insertions, 0 deletions
diff --git a/tvix/eval/src/tests/tvix_tests/eval-okay-xml.exp.xml b/tvix/eval/src/tests/tvix_tests/eval-okay-xml.exp.xml new file mode 100644 index 000000000000..1521bcc97afc --- /dev/null +++ b/tvix/eval/src/tests/tvix_tests/eval-okay-xml.exp.xml @@ -0,0 +1,41 @@ +<?xml version='1.0' encoding='utf-8'?> +<expr> + <attrs> + <attr name="attrspat"> + <function> + <attrspat name="args"> + <attr name="x" /> + <attr name="y" /> + <attr name="z" /> + </attrspat> + </function> + </attr> + <attr name="attrspat-ellipsis"> + <function> + <attrspat ellipsis="1" name="args"> + <attr name="x" /> + <attr name="y" /> + <attr name="z" /> + </attrspat> + </function> + </attr> + <attr name="noattrspat"> + <function> + <attrspat> + <attr name="x" /> + <attr name="y" /> + <attr name="z" /> + </attrspat> + </function> + </attr> + <attr name="noattrspat-ellipsis"> + <function> + <attrspat ellipsis="1"> + <attr name="x" /> + <attr name="y" /> + <attr name="z" /> + </attrspat> + </function> + </attr> + </attrs> +</expr> diff --git a/tvix/eval/src/tests/tvix_tests/eval-okay-xml.nix b/tvix/eval/src/tests/tvix_tests/eval-okay-xml.nix new file mode 100644 index 000000000000..3cc5acf43023 --- /dev/null +++ b/tvix/eval/src/tests/tvix_tests/eval-okay-xml.nix @@ -0,0 +1,7 @@ +{ + attrspat = args@{ x, y, z }: x; + attrspat-ellipsis = args@{ x, y, z, ... }: x; + + noattrspat = { x, y, z }: x; + noattrspat-ellipsis = { x, y, z, ... }: x; +} |