squiggle/packages/squiggle-lang/__tests__/ReducerInterface/ReducerInterface_ExpressionValue_test.res

15 lines
344 B
Plaintext
Raw Normal View History

2022-03-24 12:41:31 +00:00
open Jest
open Expect
2022-03-29 09:09:59 +00:00
describe("ExpressionValue", () => {
2022-09-19 19:10:09 +00:00
test("argsToString", () => expect(
[IEvNumber(1.), IEvString("a")]->Reducer_Value.argsToString)->toBe("1,'a'")
)
2022-03-24 12:41:31 +00:00
2022-03-30 10:53:36 +00:00
test("toStringFunctionCall", () =>
2022-09-19 19:10:09 +00:00
expect(
("fn", [IEvNumber(1.), IEvString("a")])->Reducer_Value.toStringFunctionCall)->toBe("fn(1,'a')"
)
2022-03-24 12:41:31 +00:00
)
})