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

basilisp.test/are suppresses line numbers on test failures #635

Open
chrisrink10 opened this issue May 22, 2021 · 1 comment
Open

basilisp.test/are suppresses line numbers on test failures #635

chrisrink10 opened this issue May 22, 2021 · 1 comment
Labels
component:testing Issue pertaining to tests/testing issue-type:bug Something isn't working

Comments

@chrisrink10
Copy link
Member

basilisp.test/is fetches line numbers from the (is ...) form during macroexpansion to report line numbers of failing tests. It seems that are-based tests lose reader position when they're first read and therefore we end up getting line number outputs like this:

FAIL in (hierarchy-test) (test_core_fns.lpy:None)
     derived with keywords :: underive :: ancestors :: Test failure: (= nil (ancestors h :tests.basilisp.test-core-fns/isosceles))

    expected: nil
      actual: #{:tests.basilisp.test-core-fns/polygon}
@chrisrink10
Copy link
Member Author

In working on #643 I investigated a few different options for trying to thread the line number corresponding to the (are ...) form into the generated (is ...) assertions, but none of them seemed to be working. I still believe there's a solution here, but I think I'll need to spend a bit more time digging.

@chrisrink10 chrisrink10 removed this from the Release v0.1.0 milestone Jun 24, 2021
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
component:testing Issue pertaining to tests/testing issue-type:bug Something isn't working
Projects
Development

No branches or pull requests

1 participant