summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorKeith Hall <kingkeith+github@gmail.com>2024-01-02 00:38:36 +0200
committerKeith Hall <kingkeith+github@gmail.com>2024-01-02 00:39:54 +0200
commitc963e80343af2e7a708d2e338805c150f43c04c0 (patch)
tree266f8bdf049d5005a1d36f053da26228dd1d2a4c
parentea1fbacf76ba3e440e37bfd3dd2e7e65b734e110 (diff)
update highlighted version of sample.jq
-rw-r--r--tests/syntax-tests/highlighted/JQ/sample.jq32
1 files changed, 16 insertions, 16 deletions
diff --git a/tests/syntax-tests/highlighted/JQ/sample.jq b/tests/syntax-tests/highlighted/JQ/sample.jq
index ba9c853f..057e9edd 100644
--- a/tests/syntax-tests/highlighted/JQ/sample.jq
+++ b/tests/syntax-tests/highlighted/JQ/sample.jq
@@ -1,31 +1,31 @@
import "../imported-file" ;
# With Comments !
-def weird($a; $b; $c):
- [ $a, $b, $c ] | transpose | reduce .[][] as $item (
- [];
- . + $item.property
- )
+def weird($a; $b; $c):
+ [ $a, $b, $c ] | transpose | reduce .[][] as $item (
+ [];
+ . + $item.property
+ )
;
-. | weird (.a; .b; .c) |
+. | weird (.a; .b; .c) |
(
-if (. | contains("never") ) then
+if (. | contains("never") ) then
 "Why yes"
else
 12.23
end
-) as $never |
+) as $never |
{
 hello,
 why: "because",
- hello: ( weird | ascii_upcase ),
- format_eg: ( . | @json "My json string \( . | this | part | just | white | ascii_upcase | transpose)" ),
- never: $never,
+ hello: ( weird | ascii_upcase ),
+ format_eg: ( . | @json "My json string \( . | this | part | just | white | ascii_upcase | transpose)" ),
+ never: $never,
 "literal_key": literal_value,
 "this": 12.1e12,
 "part": "almost"
@@ -38,8 +38,8 @@
 similar: "but not quite"
 }
 }
- ],
-} | (
+ ],
+} | (
 
 # And with very basic brace matching
 
@@ -47,13 +47,13 @@
 ] 
 
 # Other invalid ends
- ( [ } ] )
+ ( [ } ] )
 # A "valid" sequence
- ( [ { key: () , other_key:( [ [] [[]] ] ), gaga } ] )
+ ( [ { key: () , other_key:( [ [] [[]] ] ), gaga } ] )
 # A "invalid" sequence
- ( [ { key: () , other_key:( [ [] [[] ] ), gaga } ] )
+ ( [ { key: () , other_key:( [ [] [[] ] ), gaga } ] )
 "A string\n whith escaped characters \" because we can"
)