blob: 264ce5fa30c7161c5ff961d0fe706347ab3f644a (
plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
|
; See LICENSE for license details.
circuit SimpleExtModuleTester :
extmodule SimpleExtModule :
input foo : UInt<16>
output bar : UInt<16>
module SimpleExtModuleTester :
input clk : Clock
input reset : UInt<1>
inst dut of SimpleExtModule
dut.foo <= UInt(1234)
when not(reset) :
when neq(dut.bar, UInt(1234)) :
printf(clk, not(reset), "Assertion failed\nTest Failed!\n")
stop(clk, not(reset), 1)
else :
stop(clk, not(reset), 0)
|