mirror of
https://github.com/roc-lang/roc.git
synced 2024-09-21 07:49:17 +03:00
Add a test for polymorphic dbgs
This commit is contained in:
parent
bd06714fd2
commit
a4f124687d
@ -568,7 +568,7 @@ mod cli_run {
|
||||
r#"
|
||||
This expectation failed:
|
||||
|
||||
14│ expect x != x
|
||||
18│ expect x != x
|
||||
^^^^^^
|
||||
|
||||
When it failed, these variables had these values:
|
||||
@ -576,8 +576,11 @@ mod cli_run {
|
||||
x : Num *
|
||||
x = 42
|
||||
|
||||
[<ignored for tests> 15:9] 42
|
||||
[<ignored for tests> 16:9] "Fjoer en ferdjer frieten oan dyn geve lea"
|
||||
[<ignored for tests> 19:9] 42
|
||||
[<ignored for tests> 20:9] "Fjoer en ferdjer frieten oan dyn geve lea"
|
||||
[<ignored for tests> 13:9] "abc"
|
||||
[<ignored for tests> 13:9] 10
|
||||
[<ignored for tests> 13:9] A (B C)
|
||||
Program finished!
|
||||
"#
|
||||
),
|
||||
|
@ -9,9 +9,17 @@ expect
|
||||
|
||||
a == b
|
||||
|
||||
polyDbg = \x ->
|
||||
dbg x
|
||||
x
|
||||
|
||||
main =
|
||||
x = 42
|
||||
expect x != x
|
||||
dbg x
|
||||
dbg "Fjoer en ferdjer frieten oan dyn geve lea"
|
||||
"Program finished!\n"
|
||||
|
||||
r = {x : polyDbg "abc", y: polyDbg 10u8, z : polyDbg (A (B C))}
|
||||
|
||||
when r is
|
||||
_ -> "Program finished!\n"
|
||||
|
Loading…
Reference in New Issue
Block a user