Skip to content

Commit

Permalink
Add tests for annotation report
Browse files Browse the repository at this point in the history
  • Loading branch information
davidmezzetti committed Dec 10, 2020
1 parent 38e746c commit 4c73c93
Showing 1 changed file with 18 additions and 0 deletions.
18 changes: 18 additions & 0 deletions test/python/testreport.py
Original file line number Diff line number Diff line change
Expand Up @@ -53,3 +53,21 @@ def testReport2(self):
# Check file hashes
for name, value in hashes:
self.assertEqual(Utils.hashfile(Utils.PATH + "/" + name), value)

@unittest.skipIf(os.name == "nt", "Faiss not installed on Windows")
def testReport3(self):
"""
Runs test queries from report3.yml test file
"""

# Execute report
Execute.run(Utils.PATH + "/report3.yml", 1, "csv", Utils.PATH, None)
Execute.run(Utils.PATH + "/report3.yml", 1, "md", Utils.PATH, None)
Execute.run(Utils.PATH + "/report3.yml", 1, "ant", Utils.PATH, None, Utils.PATH)

hashes = [("AI.csv", "b47e96639a210d2089a5bd4e7e7bfc98"),
("Report3.md", "1a47340bc135fc086160c62f8731edee")]

# Check file hashes
for name, value in hashes:
self.assertEqual(Utils.hashfile(Utils.PATH + "/" + name), value)

0 comments on commit 4c73c93

Please sign in to comment.