mirror of
https://gitlab.gnome.org/jwestman/blueprint-compiler.git
synced 2025-05-04 15:59:08 -04:00
Add compilation tests
Added a set of test inputs and expected outputs, for regression testing.
This commit is contained in:
parent
53ad4ec69d
commit
5f0eef5f2e
21 changed files with 241 additions and 9 deletions
|
@ -30,7 +30,7 @@ class Menu(AstNode):
|
|||
def emit_xml(self, xml: XmlEmitter):
|
||||
xml.start_tag(self.tokens["tag"], id=self.tokens["id"])
|
||||
for child in self.children:
|
||||
child.emit_xml()
|
||||
child.emit_xml(xml)
|
||||
xml.end_tag()
|
||||
|
||||
|
||||
|
@ -96,7 +96,7 @@ menu_item_shorthand = Group(
|
|||
)),
|
||||
Optional(Group(
|
||||
MenuAttribute,
|
||||
Sequence(UseLiteral("name", "verb-icon-name"), value),
|
||||
Sequence(UseLiteral("name", "icon"), value),
|
||||
)),
|
||||
StmtEnd().expected("`;`"),
|
||||
)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue