13 lines
465 B
Plaintext
13 lines
465 B
Plaintext
|
open Jest
|
||
|
open Reducer_TestHelpers
|
||
|
|
||
|
/*
|
||
|
You can wrap around any expression with inspect(expr) to log the value of that expression.
|
||
|
This is useful for debugging. inspect(expr) returns the value of expr, but also prints it out.
|
||
|
There is a second version of inspect that takes a label, which will print out the label and the value.
|
||
|
*/
|
||
|
describe("Debugging", () => {
|
||
|
testEvalToBe("inspect(1)", "Ok(1)")
|
||
|
testEvalToBe("inspect(1, \"one\")", "Ok(1)")
|
||
|
})
|