aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/test/scala/firrtlTests/AnnotationTests.scala7
-rw-r--r--src/test/scala/firrtlTests/FirrtlSpec.scala4
-rw-r--r--src/test/scala/firrtlTests/PassTests.scala3
3 files changed, 3 insertions, 11 deletions
diff --git a/src/test/scala/firrtlTests/AnnotationTests.scala b/src/test/scala/firrtlTests/AnnotationTests.scala
index 3e93081e..c8b83bd2 100644
--- a/src/test/scala/firrtlTests/AnnotationTests.scala
+++ b/src/test/scala/firrtlTests/AnnotationTests.scala
@@ -49,13 +49,6 @@ class AnnotationTests extends AnnotationSpec with Matchers {
Annotation(ComponentName(s, ModuleName(mod, CircuitName("Top"))), classOf[Transform], value)
def manno(mod: String): Annotation =
Annotation(ModuleName(mod, CircuitName("Top")), classOf[Transform], "some value")
- // TODO unify with FirrtlMatchers, problems with multiple definitions of parse
- def dontTouch(path: String): Annotation = {
- val parts = path.split('.')
- require(parts.size >= 2, "Must specify both module and component!")
- val name = ComponentName(parts.tail.mkString("."), ModuleName(parts.head, CircuitName("Top")))
- DontTouchAnnotation(name)
- }
"Loose and Sticky annotation on a node" should "pass through" in {
val input: String =
diff --git a/src/test/scala/firrtlTests/FirrtlSpec.scala b/src/test/scala/firrtlTests/FirrtlSpec.scala
index a45af8c7..07f83142 100644
--- a/src/test/scala/firrtlTests/FirrtlSpec.scala
+++ b/src/test/scala/firrtlTests/FirrtlSpec.scala
@@ -11,7 +11,7 @@ import org.scalatest.prop._
import scala.io.Source
import firrtl._
-import firrtl.Parser.IgnoreInfo
+import firrtl.Parser.UseInfo
import firrtl.annotations._
import firrtl.transforms.{DontTouchAnnotation, NoDedupAnnotation}
import firrtl.util.BackendCompilationUtilities
@@ -100,7 +100,7 @@ trait FirrtlMatchers extends Matchers {
require(!s.contains("\n"))
s.replaceAll("\\s+", " ").trim
}
- def parse(str: String) = Parser.parse(str.split("\n").toIterator, IgnoreInfo)
+ def parse(str: String) = Parser.parse(str.split("\n").toIterator, UseInfo)
/** Helper for executing tests
* compiler will be run on input then emitted result will each be split into
* lines and normalized.
diff --git a/src/test/scala/firrtlTests/PassTests.scala b/src/test/scala/firrtlTests/PassTests.scala
index e22fd513..7fa7e8ef 100644
--- a/src/test/scala/firrtlTests/PassTests.scala
+++ b/src/test/scala/firrtlTests/PassTests.scala
@@ -13,9 +13,8 @@ import logger._
// An example methodology for testing Firrtl Passes
// Spec class should extend this class
-abstract class SimpleTransformSpec extends FlatSpec with Matchers with Compiler with LazyLogging {
+abstract class SimpleTransformSpec extends FlatSpec with FirrtlMatchers with Compiler with LazyLogging {
// Utility function
- def parse(s: String): Circuit = Parser.parse(s.split("\n").toIterator, infoMode = UseInfo)
def squash(c: Circuit): Circuit = RemoveEmpty.run(c)
// Executes the test. Call in tests.