summaryrefslogtreecommitdiff
path: root/examples/TAP.py
diff options
context:
space:
mode:
authorptmcg <ptmcg@austin.rr.com>2020-06-27 08:26:16 -0500
committerptmcg <ptmcg@austin.rr.com>2020-06-27 08:26:16 -0500
commit20dfaac6b80ad42851d82f9d2be376e098f0a5ba (patch)
tree2cf9ef8ceee535a069a05399575ef763b2a6e066 /examples/TAP.py
parentb3edef08a38b45c3a5fe74968e3589996761660c (diff)
downloadpyparsing-git-20dfaac6b80ad42851d82f9d2be376e098f0a5ba.tar.gz
Add make_diagram.py to examples to demonstrate creating railroad diags for selected examples
Diffstat (limited to 'examples/TAP.py')
-rw-r--r--examples/TAP.py6
1 files changed, 5 insertions, 1 deletions
diff --git a/examples/TAP.py b/examples/TAP.py
index 8676e7e..788a656 100644
--- a/examples/TAP.py
+++ b/examples/TAP.py
@@ -169,7 +169,7 @@ class TAPSummary:
tapOutputParser.setParseAction(TAPSummary)
-if __name__ == "__main__":
+def main():
test1 = """\
1..4
ok 1 - Input file opened
@@ -241,3 +241,7 @@ if __name__ == "__main__":
tapResult = tapOutputParser.parseString(test)[0]
print(tapResult.summary(showAll=True))
print()
+
+
+if __name__ == "__main__":
+ main()