Skip to content
New issue

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

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

Already on GitHub? Sign in to your account

Proof of Concept: Test one function using testy #20

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

linus
Copy link

@linus linus commented Dec 13, 2022

This is just a PoC to show the feasability of doctest:ing the JSDoc
@examples instead of / in addition to other tests.

Because of require/import discrepancies, the test scaffolding needs
some import shenanigans.

Apart from that, the rounding needs to be handled somewhat differently.
This could be solved in other ways, if given a feature request to testy:

  • One could imagine the option to inject different expect-logic in the
    test suite (make expect behave more fuzzy).
  • Or, the option of injecting a helper function to use in @examples.
  • ... or other options.

In anticipation of a more thorough effort, though, it seems pertinent
to update and modernize the project first, though.

Nice library! 🙌

This is just a PoC to show the feasability of doctest:ing the JSDoc
@examples instead of / in addition to other tests.

Because of require/import discrepancies, the test scaffolding needs
some import shenanigans.

Apart from that, the rounding needs to be handled somewhat differently.
This could be solved in other ways, if given a feature request to testy:
- One could imagine the option to inject different expect-logic in the
test suite (make expect behave more fuzzy).
- Or, the option of injecting a helper function to use in @examples.
- ... or other options.

In anticipation of a more thorough effort, though, it seems pertinent
to update and modernize the project first, though.

Nice library! 🙌
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant