summaryrefslogtreecommitdiff
path: root/src/test
diff options
context:
space:
mode:
Diffstat (limited to 'src/test')
-rw-r--r--src/test/scala/chiselTests/Reg.scala10
1 files changed, 5 insertions, 5 deletions
diff --git a/src/test/scala/chiselTests/Reg.scala b/src/test/scala/chiselTests/Reg.scala
index fc2cbf9d..a92d5ebf 100644
--- a/src/test/scala/chiselTests/Reg.scala
+++ b/src/test/scala/chiselTests/Reg.scala
@@ -16,7 +16,7 @@ class RegSpec extends ChiselFlatSpec {
"A Reg" should "be of the same type and width as outType, if specified" in {
class RegOutTypeWidthTester extends BasicTester {
val reg = Reg(t=UInt(width=2), next=UInt(width=3), init=UInt(20))
- reg.width.get should be (2)
+ reg.getWidth should be (2)
}
elaborate{ new RegOutTypeWidthTester }
}
@@ -24,11 +24,11 @@ class RegSpec extends ChiselFlatSpec {
"A Reg" should "be of unknown width if outType is not specified and width is not forced" in {
class RegUnknownWidthTester extends BasicTester {
val reg1 = Reg(next=UInt(width=3), init=UInt(20))
- reg1.width.known should be (false)
+ reg1.isWidthKnown should be (false)
val reg2 = Reg(init=UInt(20))
- reg2.width.known should be (false)
+ reg2.isWidthKnown should be (false)
val reg3 = Reg(next=UInt(width=3), init=UInt(width=5))
- reg3.width.known should be (false)
+ reg3.isWidthKnown should be (false)
}
elaborate { new RegUnknownWidthTester }
}
@@ -36,7 +36,7 @@ class RegSpec extends ChiselFlatSpec {
"A Reg" should "be of width of init if outType and next are missing and init is a literal of forced width" in {
class RegForcedWidthTester extends BasicTester {
val reg2 = Reg(init=UInt(20, width=7))
- reg2.width.get should be (7)
+ reg2.getWidth should be (7)
}
elaborate{ new RegForcedWidthTester }
}