You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
A common pattern is defining a function while testing and using it in further tests. Right now each test is evaluated in it's own environment, so any inline definitions are unknown to successive tests.
One potential approach is to naively use the same ocaml terminal for each suite, and either only parsing and returning the outputs at the end of the suite or communicating/parsing with the program and returning results while running them.
Another is to find any let statements in suites and run them with any following tests in a suite (or parsing following tests to determine if they use the defined statements).
For example, this test defines the function sqrt to be used in following tests:
A common pattern is defining a function while testing and using it in further tests. Right now each test is evaluated in it's own environment, so any inline definitions are unknown to successive tests.
One potential approach is to naively use the same ocaml terminal for each suite, and either only parsing and returning the outputs at the end of the suite or communicating/parsing with the program and returning results while running them.
Another is to find any
let
statements in suites and run them with any following tests in a suite (or parsing following tests to determine if they use the defined statements).For example, this test defines the function
sqrt
to be used in following tests:The text was updated successfully, but these errors were encountered: