Skip to content

Commit

Permalink
Add conftest.py
Browse files Browse the repository at this point in the history
So that we clear magma cache after each pytest func (see phanrahan/magma#220).
  • Loading branch information
rsetaluri committed Jul 23, 2018
1 parent 9ae1355 commit 217c537
Showing 1 changed file with 13 additions and 0 deletions.
13 changes: 13 additions & 0 deletions conftest.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
import pytest
from magma.circuit import magma_clear_circuit_cache
from magma import clear_cachedFunctions
import magma.backend.coreir_ as coreir_

collect_ignore = ["src"] # pip folder that contains dependencies like magma


@pytest.fixture(autouse=True)
def magma_test():
magma_clear_circuit_cache()
clear_cachedFunctions()
coreir_.__reset_context()

0 comments on commit 217c537

Please sign in to comment.