From 2cb43e4e41cf19aabef361724dccaae1334208c2 Mon Sep 17 00:00:00 2001 From: Tobias Platen Date: Mon, 9 Sep 2019 20:31:06 +0200 Subject: [PATCH] add unittest for tlb_content.py --- src/TLB/ariane/test/test_tlb_content.py | 22 ++++++++++++++++++++++ 1 file changed, 22 insertions(+) create mode 100644 src/TLB/ariane/test/test_tlb_content.py diff --git a/src/TLB/ariane/test/test_tlb_content.py b/src/TLB/ariane/test/test_tlb_content.py new file mode 100644 index 00000000..2261329f --- /dev/null +++ b/src/TLB/ariane/test/test_tlb_content.py @@ -0,0 +1,22 @@ +import sys +sys.path.append("../src") +sys.path.append("../../../TestUtil") + +from nmigen.compat.sim import run_simulation + +from TLB.ariane.tlb_content import TLBContent + +#def set_vaddr(addr): +# yield dut.lu_vaddr_i.eq(addr) +# yield dut.update_i.vpn.eq(addr>>12) + +def tbench(dut): + yield + yield + yield + +if __name__ == "__main__": + dut = TLBContent(4,4) + # + run_simulation(dut, tbench(dut), vcd_name="test_tlb_content.vcd") + print("TLBContent Unit Test Success") -- 2.30.2