Fixed unit test

This commit is contained in:
2020-01-31 20:13:17 +01:00
parent b9afcba61f
commit 78fc046f5a
9 changed files with 88 additions and 27 deletions
+5 -11
View File
@@ -18,7 +18,7 @@ class TestSheerkaHistoryManager(TestUsingMemoryBasedSheerka):
sheerka.evaluate_user_input("def concept five as 5")
sheerka.evaluate_user_input("five")
h = list(sheerka.history(-1)) # all
h = list(sheerka.history(-1)) # all
assert h == [
hist("five", True),
hist("def concept five as 5", True),
@@ -35,18 +35,12 @@ class TestSheerkaHistoryManager(TestUsingMemoryBasedSheerka):
h = list(sheerka.history(2))
assert h == [
hist("two", True),
hist("def concept two as 2", True)
hist("five", True),
hist("def concept five as 5", True)
]
h = list(sheerka.history(2, 2))
assert h == [
hist("xxx", False),
hist("one", True),
]
h = list(sheerka.history(-1))
assert h == [
hist("xxx", False),
hist("one", True),
hist("four", True),
hist("def concept four as 4", True),
]