Skip to content

Commit 937ba7d

Browse files
Add vulpix modification docs
1 parent fc023e9 commit 937ba7d

File tree

2 files changed

+30
-0
lines changed

2 files changed

+30
-0
lines changed
Lines changed: 30 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,30 @@
1+
# Test Vulpix Framework
2+
If you are modifying the Vulpix framework and need a playground with dummy tests to try out your modifications, do the following.
3+
4+
Create the directory structure for the playground:
5+
6+
```bash
7+
mkdir -pv tests/playground/run tests/playground/neg
8+
echo "stuff" > tests/playground/neg/Sample.scala
9+
echo 'object Test { def main(args: Array[String]): Unit = {println("Hi")} }' > tests/playground/run/Sample.scala
10+
```
11+
12+
In `CompilationTests.scala`:
13+
14+
```scala
15+
@Test def exampleNeg: Unit = {
16+
implicit val testGroup: TestGroup = TestGroup("exampleNeg")
17+
compileFilesInDir("tests/playground/neg", defaultOptions).checkExpectedErrors()
18+
}
19+
20+
@Test def exampleRun: Unit = {
21+
implicit val testGroup: TestGroup = TestGroup("exampleRun")
22+
compileFilesInDir("tests/playground/run", defaultOptions).checkRuns()
23+
}
24+
```
25+
26+
SBT:
27+
28+
```scala
29+
testOnly dotty.tools.dotc.CompilationTests -- *example*
30+
```

0 commit comments

Comments
 (0)