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

cider-test-run-test fails with (wrong-type-argument stringp (dict ... #18

Open
sktoiva opened this issue Aug 11, 2015 · 4 comments
Open

Comments

@sktoiva
Copy link

sktoiva commented Aug 11, 2015

I'm using Emacs 25.0.50.1 and CIDER 0.10.0snapshot.

Given the following example:

(deftest example1
  (checking "this-will-fail" 100
            [n gen/pos-int]
            (is (> 0 n))))

Running test with cider-test-run-test or cider-test-run-tests, the reporting will fail with following error message:

Debugger entered--Lisp error: (wrong-type-argument stringp (dict "fail" (0) "failing-size" 0 "num-tests" ...

I have tested it without the checking macro:

(deftest example2
  (testing "this-will-fail"
    (is (> 0 1))))

This works as intended, so currently I'm assuming the error has something to do with test.chuck and not CIDER itself.

However, invoking the tests with (clojure.test/run-tests) provides the intended output, so I'm a bit loss here where the problem might lie.

@gfredericks
Copy link
Owner

it looks as if the return value from calling the test function is making its way into cider as some kind of emacs data structure, and that cider is expecting a string for some reason.

@gfredericks
Copy link
Owner

alternatively, instead of being related to the test return value it might be related to something passed to the clojure.test reporting functions. @lackita any guesses?

@gfredericks
Copy link
Owner

@sktoiva I'm also curious what happens if you used defspec instead.

@sktoiva
Copy link
Author

sktoiva commented Aug 12, 2015

defspec works as intended, or at least so that the *cider-test-report* buffer contains information about failed tests and the specific information about how it failed is printed to *cider-repl*.

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

No branches or pull requests

2 participants