mirror of
https://github.com/GrammaticalFramework/gf-core.git
synced 2026-04-11 13:59:31 -06:00
first draft of the new allocator with transactions support
This commit is contained in:
@@ -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):
|
||||
|
||||
Reference in New Issue
Block a user