From e51ba71ec5b2c1c708e2a0cc4bbde6b748eb756c Mon Sep 17 00:00:00 2001 From: kenkeiras Date: Wed, 24 May 2017 20:42:45 +0200 Subject: [PATCH] Add after_execution mechanism to gac100 test. --- naive-nlu/tree_nlu/tests/gac_100.py | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/naive-nlu/tree_nlu/tests/gac_100.py b/naive-nlu/tree_nlu/tests/gac_100.py index 680f909..29d5ead 100644 --- a/naive-nlu/tree_nlu/tests/gac_100.py +++ b/naive-nlu/tree_nlu/tests/gac_100.py @@ -668,6 +668,10 @@ def main(): if result != data['answer']: raise AssertionError('{} is not {}'.format(result, data['answer'])) + if "after_execution" in data: + for f in data["after_execution"]: + f(knowledge) + elif example_type == 'text_example': affirmation = data['affirmation'] question = data['question']