This little project exercises most of the OCaml environment needed for CS 3110.
In the Ed terminal, run utop
. You should get a prompt like this:
utop #
Enter this then press return:
"hello ed";;
You should see this:
utop # "hello ed";;
- : string = "hello ed"
Run make main
from the root of this project. You should get output like this:
Testing Batteries...
The Batteries library is working.
Testing CSV (and file I/O)...
The CSV library is working.
Testing ANSITerminal...
If the ANSITerminal library is working, this text should be blue on black.
All tests completed.
Run dune test
. You should get output like this:
..
Ran: 2 tests in: 0.11 seconds.
OK
Then run make bisect
and open _coverage/index.html
. You should see 100% coverage of lib/lib.ml
.
Open "lib/lib.ml". You should see:
let inc x = 1 + x
Change that to:
let inc x =
1 + x
If Ed supports running an autoformatter, do whatever it takes to trigger that. (Save the file?) It should revert to its former single-line content.
This project does not yet attempt to test LWT or Menhir.