-
-
Notifications
You must be signed in to change notification settings - Fork 5
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
Support let expressions in describe and test functions #30
Comments
I wrote some code that can traverse complex code and grab tests along the way. It might be a bit too general for our use case, but it works. It's not pushed anywhere yet. Along the way, it grabs all the Another idea is to create an alias function task : Int -> String -> List Test -> Test
task _ = describe that I could also parse along the way, but that's a bit more convoluted. Oh, I just remembered @mpizenberg has already implemented something like that on his fork. Anyway, plenty of options, we should take this opportunity to extract the task ID and add a Thoughts? |
Oh, the name of that repo might be confusing you @jiegillet sorry. This repo is not actually a fork of exercism/elm-test-runner. It's the Elm part (an elm package: https://package.elm-lang.org/packages/mpizenberg/elm-test-runner/latest/) of mpizenberg/elm-test-rs, my rust test runner, which already has the ability to report tasks when they are numbered. The only thing needed to bring it to exercism/elm-test-runner is to update in it the version of elm-test-rs. Is it clearer? But all this is unrelated to the code here having an issue with |
Oh, I see, yes, I got confused by the name. So getting the task number is just a matter of updating |
Solves exercism#30. The code extractor can now: - Find test/describe inside of a let declaration - Find test/describe pretty much anywhere (if, record, tuple...) - Handle more than one top-level `Test` - Find tests in arbitrarily nested describe - Write test name as "describe name 1 > describe name 2 > ... > test name"
* Clean up elm.json dependencies. Closes #34. * Expand code parsing. Solves #30. The code extractor can now: - Find test/describe inside of a let declaration - Find test/describe pretty much anywhere (if, record, tuple...) - Handle more than one top-level `Test` - Find tests in arbitrarily nested describe - Write test name as "describe name 1 > describe name 2 > ... > test name" * Minimal changes to capture description hierarchy
The test runner cannot currently handle a let expression used inside a describe or test function, like below and in #29
The text was updated successfully, but these errors were encountered: