Skip to content

Commit

Permalink
check in generated test suite
Browse files Browse the repository at this point in the history
  • Loading branch information
awalterschulze committed Oct 22, 2024
1 parent b019c9e commit 2c081a7
Show file tree
Hide file tree
Showing 1,696 changed files with 170,648 additions and 1 deletion.
1 change: 0 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
gen-validator-tests
validator/tests/*
validator/benches/*
7 changes: 7 additions & 0 deletions validator/tests/goreflect/APocketRoses/valid.goreflect
Original file line number Diff line number Diff line change
@@ -0,0 +1,7 @@
{
"MenuPaperclip": [
"a",
"b",
"c"
]
}
60 changes: 60 additions & 0 deletions validator/tests/goreflect/APocketRoses/validator.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,60 @@
{
"TopPattern": {
"TreeNode": {
"Name": {
"Name": {
"StringValue": "MenuPaperclip"
}
},
"Pattern": {
"Concat": {
"OpenBracket": {
"Value": "["
},
"LeftPattern": {
"TreeNode": {
"Name": {
"Name": {
"IntValue": 0
}
},
"Colon": {
"Value": ":"
},
"Pattern": {
"LeafNode": {
"Expr": {
"BuiltIn": {
"Symbol": {
"Value": "=="
},
"Expr": {
"Terminal": {
"Literal": "\"a\"",
"StringValue": "a"
}
}
}
}
}
}
}
},
"Comma": {
"Value": ","
},
"RightPattern": {
"ZAny": {
"Star": {
"Value": "*"
}
}
},
"CloseBracket": {
"Value": "]"
}
}
}
}
}
}
1 change: 1 addition & 0 deletions validator/tests/goreflect/APocketRoses/validator.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
MenuPaperclip[0:=="a",*]
63 changes: 63 additions & 0 deletions validator/tests/goreflect/APocketRoses/validator.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
<Grammar>
<TopPattern>
<TreeNode>
<Name>
<Name>
<StringValue>MenuPaperclip</StringValue>
<BytesValue></BytesValue>
</Name>
</Name>
<Pattern>
<Concat>
<OpenBracket>
<Value>[</Value>
</OpenBracket>
<LeftPattern>
<TreeNode>
<Name>
<Name>
<IntValue>0</IntValue>
<BytesValue></BytesValue>
</Name>
</Name>
<Colon>
<Value>:</Value>
</Colon>
<Pattern>
<LeafNode>
<Expr>
<BuiltIn>
<Symbol>
<Value>==</Value>
</Symbol>
<Expr>
<Terminal>
<Literal>&#34;a&#34;</Literal>
<StringValue>a</StringValue>
<BytesValue></BytesValue>
</Terminal>
</Expr>
</BuiltIn>
</Expr>
</LeafNode>
</Pattern>
</TreeNode>
</LeftPattern>
<Comma>
<Value>,</Value>
</Comma>
<RightPattern>
<ZAny>
<Star>
<Value>*</Value>
</Star>
</ZAny>
</RightPattern>
<CloseBracket>
<Value>]</Value>
</CloseBracket>
</Concat>
</Pattern>
</TreeNode>
</TopPattern>
</Grammar>
12 changes: 12 additions & 0 deletions validator/tests/goreflect/Ab21Any/valid.goreflect
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"SaladWorry": {
"MagazineFrame": [
"a",
"b"
],
"XrayPilot": {
"AnkleCoat": 2
}
},
"RumourSpirit": 1
}
9 changes: 9 additions & 0 deletions validator/tests/goreflect/Ab21Any/validator.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
{
"TopPattern": {
"ZAny": {
"Star": {
"Value": "*"
}
}
}
}
1 change: 1 addition & 0 deletions validator/tests/goreflect/Ab21Any/validator.txt
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
*
9 changes: 9 additions & 0 deletions validator/tests/goreflect/Ab21Any/validator.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
<Grammar>
<TopPattern>
<ZAny>
<Star>
<Value>*</Value>
</Star>
</ZAny>
</TopPattern>
</Grammar>
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
{
"SaladWorry": {
"MagazineFrame": [
"a",
"b"
],
"XrayPilot": {
"AnkleCoat": 2
}
},
"RumourSpirit": 1
}
93 changes: 93 additions & 0 deletions validator/tests/goreflect/Ab21InAnyExceptSaladWorry/validator.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,93 @@
{
"TopPattern": {
"Concat": {
"OpenBracket": {
"Value": "["
},
"LeftPattern": {
"TreeNode": {
"Name": {
"AnyNameExcept": {
"Exclamation": {
"Value": "!"
},
"OpenParen": {
"Value": "("
},
"Except": {
"Name": {
"StringValue": "SaladWorry"
}
},
"CloseParen": {
"Value": ")"
}
}
},
"Pattern": {
"Concat": {
"OpenBracket": {
"Value": "["
},
"LeftPattern": {
"TreeNode": {
"Name": {
"Name": {
"StringValue": "MagazineFrame"
}
},
"Colon": {
"Value": ":"
},
"Pattern": {
"LeafNode": {
"Expr": {
"BuiltIn": {
"Symbol": {
"Value": "=="
},
"Expr": {
"Terminal": {
"Literal": "\"a\"",
"StringValue": "a"
}
}
}
}
}
}
}
},
"Comma": {
"Value": ","
},
"RightPattern": {
"ZAny": {
"Star": {
"Value": "*"
}
}
},
"CloseBracket": {
"Value": "]"
}
}
}
}
},
"Comma": {
"Value": ","
},
"RightPattern": {
"ZAny": {
"Star": {
"Value": "*"
}
}
},
"CloseBracket": {
"Value": "]"
}
}
}
}
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
[!(SaladWorry)[MagazineFrame:=="a",*],*]
96 changes: 96 additions & 0 deletions validator/tests/goreflect/Ab21InAnyExceptSaladWorry/validator.xml
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
<Grammar>
<TopPattern>
<Concat>
<OpenBracket>
<Value>[</Value>
</OpenBracket>
<LeftPattern>
<TreeNode>
<Name>
<AnyNameExcept>
<Exclamation>
<Value>!</Value>
</Exclamation>
<OpenParen>
<Value>(</Value>
</OpenParen>
<Except>
<Name>
<StringValue>SaladWorry</StringValue>
<BytesValue></BytesValue>
</Name>
</Except>
<CloseParen>
<Value>)</Value>
</CloseParen>
</AnyNameExcept>
</Name>
<Pattern>
<Concat>
<OpenBracket>
<Value>[</Value>
</OpenBracket>
<LeftPattern>
<TreeNode>
<Name>
<Name>
<StringValue>MagazineFrame</StringValue>
<BytesValue></BytesValue>
</Name>
</Name>
<Colon>
<Value>:</Value>
</Colon>
<Pattern>
<LeafNode>
<Expr>
<BuiltIn>
<Symbol>
<Value>==</Value>
</Symbol>
<Expr>
<Terminal>
<Literal>&#34;a&#34;</Literal>
<StringValue>a</StringValue>
<BytesValue></BytesValue>
</Terminal>
</Expr>
</BuiltIn>
</Expr>
</LeafNode>
</Pattern>
</TreeNode>
</LeftPattern>
<Comma>
<Value>,</Value>
</Comma>
<RightPattern>
<ZAny>
<Star>
<Value>*</Value>
</Star>
</ZAny>
</RightPattern>
<CloseBracket>
<Value>]</Value>
</CloseBracket>
</Concat>
</Pattern>
</TreeNode>
</LeftPattern>
<Comma>
<Value>,</Value>
</Comma>
<RightPattern>
<ZAny>
<Star>
<Value>*</Value>
</Star>
</ZAny>
</RightPattern>
<CloseBracket>
<Value>]</Value>
</CloseBracket>
</Concat>
</TopPattern>
</Grammar>
Loading

0 comments on commit 2c081a7

Please sign in to comment.