Skip to content

Commit 58bb697

Browse files
committed
Add tet case to ensure sc-opts are passed to snippet compiler
1 parent 3051bb2 commit 58bb697

File tree

1 file changed

+11
-0
lines changed

1 file changed

+11
-0
lines changed

scaladoc-testcases/docs/_docs/index.md

Lines changed: 11 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,3 +22,14 @@ val renderer: Renderer = Renderer()
2222
extension (x: Self) def combine(y: Self): Self
2323
```
2424

25+
```scala sc:fail sc-opts:-Werror:true
26+
def exampleShouldError(input: Option[String]): Unit =
27+
input match
28+
case Some("foo") => ???
29+
```
30+
31+
```scala sc:compile sc-opts:-Werror:false
32+
def exampleShouldWarn(input: Option[String]): Unit =
33+
input match
34+
case Some("foo") => ???
35+
```

0 commit comments

Comments
 (0)