aboutsummaryrefslogtreecommitdiff
path: root/src/test/scala/firrtlTests/FileUtilsSpec.scala
diff options
context:
space:
mode:
Diffstat (limited to 'src/test/scala/firrtlTests/FileUtilsSpec.scala')
-rw-r--r--src/test/scala/firrtlTests/FileUtilsSpec.scala11
1 files changed, 5 insertions, 6 deletions
diff --git a/src/test/scala/firrtlTests/FileUtilsSpec.scala b/src/test/scala/firrtlTests/FileUtilsSpec.scala
index 43d35048..5a438251 100644
--- a/src/test/scala/firrtlTests/FileUtilsSpec.scala
+++ b/src/test/scala/firrtlTests/FileUtilsSpec.scala
@@ -2,17 +2,16 @@
package firrtlTests
-
import firrtl.FileUtils
import org.scalatest.flatspec.AnyFlatSpec
import org.scalatest.matchers.should.Matchers
class FileUtilsSpec extends AnyFlatSpec with Matchers {
- private val sampleAnnotations: String = "annotations/SampleAnnotations.anno.json"
+ private val sampleAnnotations: String = "annotations/SampleAnnotations.anno.json"
private val sampleAnnotationsFileName: String = s"src/test/resources/$sampleAnnotations"
- behavior of "FileUtils.getLines"
+ behavior.of("FileUtils.getLines")
it should "read from a string filename" in {
FileUtils.getLines(sampleAnnotationsFileName).size should be > 0
@@ -22,7 +21,7 @@ class FileUtilsSpec extends AnyFlatSpec with Matchers {
FileUtils.getLines(new java.io.File(sampleAnnotationsFileName)).size should be > 0
}
- behavior of "FileUtils.getText"
+ behavior.of("FileUtils.getText")
it should "read from a string filename" in {
FileUtils.getText(sampleAnnotationsFileName).size should be > 0
@@ -32,13 +31,13 @@ class FileUtilsSpec extends AnyFlatSpec with Matchers {
FileUtils.getText(new java.io.File(sampleAnnotationsFileName)).size should be > 0
}
- behavior of "FileUtils.getLinesResource"
+ behavior.of("FileUtils.getLinesResource")
it should "read from a resource" in {
FileUtils.getLinesResource(s"/$sampleAnnotations").size should be > 0
}
- behavior of "FileUtils.getTextResource"
+ behavior.of("FileUtils.getTextResource")
it should "read from a resource" in {
FileUtils.getTextResource(s"/$sampleAnnotations").split("\n").size should be > 0