first draft of the new allocator with transactions support

This commit is contained in:
Krasimir Angelov
2022-05-20 13:55:45 +02:00
parent 546dc01b5d
commit 5594679a83
24 changed files with 1582 additions and 2372 deletions

View File

@@ -27,18 +27,6 @@ def gr3(gr1):
t.createCategory("R", [(BIND_TYPE_EXPLICIT, "x", ty)], prob)
yield gr
@pytest.fixture(scope="function")
def gr4(gr2):
gr = gr2
gr.checkoutBranch("master")
yield gr
@pytest.fixture(scope="function")
def gr5(gr3):
gr = gr3
gr.checkoutBranch("bar_branch")
yield gr
@pytest.fixture(scope="function")
def gr6(gr1):
gr = gr1
@@ -47,12 +35,6 @@ def gr6(gr1):
t.dropCategory("S")
yield gr
# general
def test_checkout_non_existant(gr1):
with pytest.raises(KeyError):
gr1.checkoutBranch("abc")
# gr1
def test_original_functions(gr1):
@@ -118,14 +100,6 @@ def test_branched_category_context(gr3):
def test_branched_function_type(gr3):
assert gr3.functionType("bar") == ty
# gr4, 5
def test_branched_functions(gr4):
assert gr4.functions == ["c", "foo", "ind", "s", "z"]
def test_branched_functions(gr5):
assert gr5.functions == ["bar", 'c', 'floatLit', 'ind', 'intLit', 'nat', 's', 'stringLit', 'z']
# gr6
def test_reduced_functions(gr6):