Skip to content
New issue

Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? # to your account

online docs: list all modules #12

Closed
c-cube opened this issue Jan 31, 2020 · 4 comments
Closed

online docs: list all modules #12

c-cube opened this issue Jan 31, 2020 · 4 comments

Comments

@c-cube
Copy link
Contributor

c-cube commented Jan 31, 2020

currently https://gildor478.github.io/ounit/ounit2/index.html seems to be an introduction/entrypoint, which is good, but it lacks a list of all the available modules. So one has no way of discovering all the existing modules except for tab-completion with merlin (e.g. OUnitLoggerHTML? What does that do? Are there actually other runners provided with OUnit?)

@gildor478
Copy link
Owner

advanced modules are supposed to be hidden to normal users (they are more or less internal).

Normal users should only use OUnit2 (or OUnit if they are still on v1). I did that to restrict the usage of more advanced and unstable features. What is exposed in OUnit2 (the module) is what I commit to be stable.

@c-cube
Copy link
Contributor Author

c-cube commented Feb 1, 2020

But then I don't know, looking at the docs, how to do the following:

  • get colored output (the biggest feature advertised by alcotest 😅)
  • get junit reports, which I needed a while ago when I was using jenkins
  • write my own custom reporter

and I'm not even aware OUnit can do that.

@gildor478
Copy link
Owner

Good point, but they are activated using environment variable or command line flags. You don't need to know the code.

  • OUNIT_CI=true to get colors and CI integration
  • OUNIT_OUTPUT_HTML_DIR=... to get HTML rendering
  • OUNIT_OUTPUT_JUNIT_FILE=... to get a JUnit file

Writing your own custom reporter is an advanced topic and you should look at the code and copy paste one of the existing one -- it is unfortunately not really simple.

Maybe we should just this options to the main page of OUnit2 (except for the own custom reporter).

@c-cube
Copy link
Contributor Author

c-cube commented Feb 3, 2020

yes, if the main docs would mention all the supported flags (or even propose them as CLI arguments) that'd be very helpful. I'd always use the colorful output, I think :-)

edit: seems like some are already input args, that's cool. Still would help to have them in the docs.

gildor478 added a commit to gildor478/opam-repository that referenced this issue Jul 11, 2020
CHANGES:

### Changed
- Minimal OCaml version is now 4.04.

### Fixed
- Make colored output and JUnit features more prominent in the documentation.
  (Closes: gildor478/ounit#13, gildor478/ounit#12)
- Increase default timeouts, so that they work as well for slow architecture
  like s390x. The fastest timeout is now 20s (immediate test) and the longest
  is 1h (huge test). (Closes: gildor478/ounit#18)
# for free to join this conversation on GitHub. Already have an account? # to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants