From 1f403ad2197fc7442409f434ee574f3e6b46fb73 Mon Sep 17 00:00:00 2001 From: Daniel Baumann Date: Sat, 4 May 2024 13:33:32 +0200 Subject: Adding upstream version 2.14.0+dfsg. Signed-off-by: Daniel Baumann --- tests/snippets/yaml/test_yaml.txt | 13 +++++++++++++ tests/snippets/yaml/test_yaml_colon_in_key.txt | 11 +++++++++++ tests/snippets/yaml/test_yaml_colon_in_key_double.txt | 11 +++++++++++ tests/snippets/yaml/test_yaml_colon_in_key_start.txt | 11 +++++++++++ 4 files changed, 46 insertions(+) create mode 100644 tests/snippets/yaml/test_yaml.txt create mode 100644 tests/snippets/yaml/test_yaml_colon_in_key.txt create mode 100644 tests/snippets/yaml/test_yaml_colon_in_key_double.txt create mode 100644 tests/snippets/yaml/test_yaml_colon_in_key_start.txt (limited to 'tests/snippets/yaml') diff --git a/tests/snippets/yaml/test_yaml.txt b/tests/snippets/yaml/test_yaml.txt new file mode 100644 index 0000000..0dd3911 --- /dev/null +++ b/tests/snippets/yaml/test_yaml.txt @@ -0,0 +1,13 @@ +# Bug #1528: This previously parsed 'token # innocent' as a tag + +---input--- +here: token # innocent: comment + +---tokens--- +'here' Name.Tag +':' Punctuation +' ' Text.Whitespace +'token' Literal.Scalar.Plain +' ' Text.Whitespace +'# innocent: comment' Comment.Single +'\n' Text.Whitespace diff --git a/tests/snippets/yaml/test_yaml_colon_in_key.txt b/tests/snippets/yaml/test_yaml_colon_in_key.txt new file mode 100644 index 0000000..9f3d313 --- /dev/null +++ b/tests/snippets/yaml/test_yaml_colon_in_key.txt @@ -0,0 +1,11 @@ +# Colon in the key name is accepted by the YAML specs too + +---input--- +foo:bar: value + +---tokens--- +'foo:bar' Name.Tag +':' Punctuation +' ' Text.Whitespace +'value' Literal.Scalar.Plain +'\n' Text.Whitespace diff --git a/tests/snippets/yaml/test_yaml_colon_in_key_double.txt b/tests/snippets/yaml/test_yaml_colon_in_key_double.txt new file mode 100644 index 0000000..6f68b6d --- /dev/null +++ b/tests/snippets/yaml/test_yaml_colon_in_key_double.txt @@ -0,0 +1,11 @@ +# Colons in the key name is accepted by the YAML specs too + +---input--- +foo::bar: value + +---tokens--- +'foo::bar' Name.Tag +':' Punctuation +' ' Text.Whitespace +'value' Literal.Scalar.Plain +'\n' Text.Whitespace diff --git a/tests/snippets/yaml/test_yaml_colon_in_key_start.txt b/tests/snippets/yaml/test_yaml_colon_in_key_start.txt new file mode 100644 index 0000000..60d4e23 --- /dev/null +++ b/tests/snippets/yaml/test_yaml_colon_in_key_start.txt @@ -0,0 +1,11 @@ +# Colon at the beginning of the key name is accepted by the YAML specs too + +---input--- +:foo: value + +---tokens--- +':foo' Name.Tag +':' Punctuation +' ' Text.Whitespace +'value' Literal.Scalar.Plain +'\n' Text.Whitespace -- cgit v1.2.3