-
Notifications
You must be signed in to change notification settings - Fork 67
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Add new test cases #100
Merged
Merged
Add new test cases #100
Changes from all commits
Commits
Show all changes
12 commits
Select commit
Hold shift + click to select a range
c12d2db
Add new test cases
ingydotnet d8d8f43
Add JSON entries for new tests
ingydotnet 7ba5479
Move test to better file
ingydotnet e174507
Remove `tree` entry as it is same as one above
ingydotnet 3c797dd
Split MUS6 into another file to skip some poor tests
ingydotnet c7eab02
Add back src/58MP.yaml
ingydotnet d347e98
Add empty-key tag to 2 tests
ingydotnet c348517
Fix tree text on error tests
ingydotnet fc8e1de
More directives test work
ingydotnet 7698ac0
Change test that is 1.2 specific
ingydotnet 66d86b6
Unskip 2 tests
ingydotnet fd76e0d
Turn of json for error tests
ingydotnet File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,34 @@ | ||
--- | ||
- name: Literal modifers | ||
from: '@ingydotnet' | ||
tags: literal scalar | ||
fail: true | ||
yaml: | | ||
--- |0 | ||
tree: | | ||
+STR | ||
+DOC --- | ||
|
||
- fail: true | ||
yaml: | | ||
--- |10 | ||
|
||
- yaml: | | ||
--- |1-∎ | ||
tree: |- | ||
+STR | ||
+DOC --- | ||
=VAL | | ||
-DOC | ||
-STR | ||
json: | | ||
"" | ||
|
||
- yaml: | | ||
--- |1+∎ | ||
tree: |- | ||
+STR | ||
+DOC --- | ||
=VAL | | ||
-DOC | ||
-STR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,3 +20,16 @@ | |
} | ||
emit: | | ||
"foo": "bar" | ||
|
||
- yaml: | | ||
{"foo" | ||
: bar} | ||
tree: |- | ||
+STR | ||
+DOC | ||
+MAP {} | ||
=VAL "foo | ||
=VAL :bar | ||
-MAP | ||
-DOC | ||
-STR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,23 @@ | ||
--- | ||
- name: Trailing spaces after flow collection | ||
tags: flow whitespace | ||
from: '@ingydotnet' | ||
yaml: |2 | ||
[1, 2, 3]␣␣ | ||
␣␣∎ | ||
tree: |- | ||
+STR | ||
+DOC | ||
+SEQ [] | ||
=VAL :1 | ||
=VAL :2 | ||
=VAL :3 | ||
-SEQ | ||
-DOC | ||
-STR | ||
json: | | ||
[ | ||
1, | ||
2, | ||
3 | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
--- | ||
- name: Flow mapping edge cases | ||
from: '@ingydotnet' | ||
tags: edge flow mapping | ||
yaml: | | ||
{x: :x} | ||
tree: |- | ||
+STR | ||
+DOC | ||
+MAP {} | ||
=VAL :x | ||
=VAL ::x | ||
-MAP | ||
-DOC | ||
-STR | ||
json: | | ||
{ | ||
"x": ":x" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,20 @@ | ||
--- | ||
- name: Flow mapping edge cases | ||
from: '@ingydotnet' | ||
tags: edge | ||
yaml: | | ||
{x | ||
: y} | ||
tree: |- | ||
+STR | ||
+DOC | ||
+MAP {} | ||
=VAL :x | ||
=VAL :y | ||
-MAP | ||
-DOC | ||
-STR | ||
json: | | ||
{ | ||
"x": "y" | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,33 @@ | ||
--- | ||
- name: Scalars in flow start with syntax char | ||
from: '@ingydotnet' | ||
tags: flow scalar | ||
yaml: | | ||
[:x] | ||
tree: |- | ||
+STR | ||
+DOC | ||
+SEQ [] | ||
=VAL ::x | ||
-SEQ | ||
-DOC | ||
-STR | ||
json: | | ||
[ | ||
":x" | ||
] | ||
|
||
- yaml: | | ||
[?x] | ||
tree: |- | ||
+STR | ||
+DOC | ||
+SEQ [] | ||
=VAL :?x | ||
-SEQ | ||
-DOC | ||
-STR | ||
json: | | ||
[ | ||
"?x" | ||
] |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
--- | ||
- name: Question mark edge cases | ||
from: '@ingydotnet' | ||
tags: edge empty-key | ||
yaml: | | ||
- ? : x | ||
tree: |- | ||
+STR | ||
+DOC | ||
+SEQ | ||
+MAP | ||
+MAP | ||
=VAL : | ||
=VAL :x | ||
-MAP | ||
=VAL : | ||
-MAP | ||
-SEQ | ||
-DOC | ||
-STR | ||
|
||
- yaml: | | ||
? []: x | ||
tree: |- | ||
+STR | ||
+DOC | ||
+MAP | ||
+MAP | ||
+SEQ [] | ||
-SEQ | ||
=VAL :x | ||
-MAP | ||
=VAL : | ||
-MAP | ||
-DOC | ||
-STR |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,46 @@ | ||
- name: Directive variants | ||
from: '@ingydotnet' | ||
tags: directive | ||
also: ZYU8 | ||
fail: true | ||
yaml: | | ||
%YAML 1.1#... | ||
--- | ||
tree: | | ||
+STR | ||
|
||
- fail: true | ||
yaml: | | ||
%YAML 1.2 | ||
--- | ||
%YAML 1.2 | ||
--- | ||
|
||
- yaml: | | ||
%YAML 1.1 | ||
--- | ||
tree: |- | ||
+STR | ||
+DOC --- | ||
=VAL : | ||
-DOC | ||
-STR | ||
json: | | ||
null | ||
|
||
- yaml: | | ||
%YAML ——» 1.1 | ||
--- | ||
|
||
- yaml: | | ||
%YAML 1.1 # comment | ||
--- | ||
|
||
- note: These 2 are reserved directives | ||
yaml: | | ||
%YAM 1.1 | ||
--- | ||
|
||
- yaml: | | ||
%YAMLL 1.1 | ||
--- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,43 @@ | ||
--- | ||
- name: Syntax character edge cases | ||
from: '@ingydotnet' | ||
tags: edge empty-key | ||
yaml: | | ||
- : | ||
tree: |- | ||
+STR | ||
+DOC | ||
+SEQ | ||
+MAP | ||
=VAL : | ||
=VAL : | ||
-MAP | ||
-SEQ | ||
-DOC | ||
-STR | ||
|
||
- yaml: | | ||
:: | ||
tree: |- | ||
+STR | ||
+DOC | ||
+MAP | ||
=VAL :: | ||
=VAL : | ||
-MAP | ||
-DOC | ||
-STR | ||
json: | | ||
{ | ||
":": null | ||
} | ||
|
||
- yaml: | | ||
! | ||
tree: |- | ||
+STR | ||
+DOC | ||
=VAL <!> : | ||
-DOC | ||
-STR | ||
json: null |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,25 @@ | ||
--- | ||
- name: Legal tab after indentation | ||
from: '@ingydotnet' | ||
tags: indent whitespace | ||
yaml: | | ||
x: | ||
- x | ||
——»x | ||
tree: |- | ||
+STR | ||
+DOC | ||
+MAP | ||
=VAL :x | ||
+SEQ | ||
=VAL :x x | ||
-SEQ | ||
-MAP | ||
-DOC | ||
-STR | ||
json: | | ||
{ | ||
"x": [ | ||
"x x" | ||
] | ||
} |
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
This one would also be a good candidate to include in 4MUZ maybe?