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

Integrated test runner does not show the exception stack trace #424

Closed
stefan-toubia opened this issue Oct 24, 2019 · 0 comments
Closed

Comments

@stefan-toubia
Copy link
Contributor

I am loving the integrated test running, it has made my workflow much more efficient, but I've been running into major problem, I cannot see the stack trace if one of my tests throw an error. Compare this to running circleci.test/run-tests and I do see a stack trace, which is very helpful when developing tests or doing TDD. It would be great to have this in the test runner!

This is a bit of a contrived example:

(testing "uncaught exception"
      (is (throw (Exception. "I have no stack trace"))))

Calva says:

ERROR in:upload-helpers-test: upload_helpers_test.clj, line 20: create-s3-key-test: uncaught exception:
  error: java.lang.Exception: I have no stack trace + "
  expected: (throw (Exception. "I have no stack trace"))

REPL terminal with CircleCI

ERROR in upload-helpers-test/ (create-s3-key-test) (upload_helpers_test.clj:20)
uncaught exception
expected: (throw (Exception. "something"))
  actual: java.lang.Exception: something
 at skipperlib.upload_helpers_test$fn__82210.invokeStatic (upload_helpers_test.clj:20)
    skipperlib.upload_helpers_test/fn (upload_helpers_test.clj:9)
    circleci.test$test_STAR_.invokeStatic (test.clj:74)
    circleci.test$test_STAR_.invoke (test.clj:70)
    circleci.test$test_var_STAR_$fn__2302$fn__2303$fn__2304.invoke (test.clj:91)
    clojure.test$default_fixture.invokeStatic (test.clj:687)
    clojure.test$default_fixture.invoke (test.clj:683)
    circleci.test$test_var_STAR_$fn__2302$fn__2303.invoke (test.clj:91)
    circleci.test$once_fixtures$fn__2270$fn__2271$fn__2272.invoke (test.clj:47)
    circleci.test$once_fixtures$fn__2270.invoke (test.clj:48)
    circleci.test$test_var_STAR_$fn__2302.invoke (test.clj:89)
    circleci.test$make_global_fixture$fn__2279.invoke (test.clj:55)
    circleci.test$test_var_STAR_.invokeStatic (test.clj:87)
    circleci.test$test_var_STAR_.invoke (test.clj:76)
    circleci.test$test_var.invokeStatic (test.clj:119)
    circleci.test$test_var.invoke (test.clj:103)
    circleci.test$test_all_vars.invokeStatic (test.clj:129)
    circleci.test$test_all_vars.invoke (test.clj:127)
    circleci.test$test_ns$fn__2336$fn__2337$fn__2338.invoke (test.clj:164)
    clojure.test$default_fixture.invokeStatic (test.clj:687)
    clojure.test$default_fixture.invoke (test.clj:683)
    circleci.test$once_fixtures$fn__2270.invoke (test.clj:48)
    circleci.test$test_ns$fn__2336$fn__2337.invoke (test.clj:156)
    circleci.test$make_global_fixture$fn__2279.invoke (test.clj:55)
    circleci.test$test_ns$fn__2336.invoke (test.clj:154)
    circleci.test$test_ns.invokeStatic (test.clj:153)
    circleci.test$test_ns.invoke (test.clj:131)
    circleci.test$run_selected_tests$fn__2346$iter__2347__2351$fn__2352.invoke (test.clj:190)
    clojure.lang.LazySeq.sval (LazySeq.java:42)
    clojure.lang.LazySeq.seq (LazySeq.java:51)
    clojure.lang.Cons.next (Cons.java:39)
    clojure.lang.RT.boundedLength (RT.java:1788)
    clojure.lang.RestFn.applyTo (RestFn.java:130)
    clojure.core$apply.invokeStatic (core.clj:667)
    clojure.core$apply.invoke (core.clj:660)
    circleci.test$run_selected_tests$fn__2346.invoke (test.clj:189)
    circleci.test$make_global_fixture$fn__2279.invoke (test.clj:55)
    circleci.test$run_selected_tests.invokeStatic (test.clj:188)
    circleci.test$run_selected_tests.invoke (test.clj:180)
    circleci.test$run_selected_tests.invokeStatic (test.clj:185)
    circleci.test$run_selected_tests.invoke (test.clj:180)
    circleci.test$run_tests.invokeStatic (test.clj:200)
    circleci.test$run_tests.doInvoke (test.clj:195)
    clojure.lang.RestFn.invoke (RestFn.java:408)
    user$eval82542.invokeStatic (form-init3945100861137048195.clj:1)
    user$eval82542.invoke (form-init3945100861137048195.clj:1)
    clojure.lang.Compiler.eval (Compiler.java:7176)
    clojure.lang.Compiler.eval (Compiler.java:7131)
    clojure.core$eval.invokeStatic (core.clj:3214)
    clojure.core$eval.invoke (core.clj:3210)
    clojure.main$repl$read_eval_print__9068$fn__9071.invoke (main.clj:414)
    clojure.main$repl$read_eval_print__9068.invoke (main.clj:414)
    clojure.main$repl$fn__9077.invoke (main.clj:435)
    clojure.main$repl.invokeStatic (main.clj:435)
    clojure.main$repl.doInvoke (main.clj:345)
    clojure.lang.RestFn.invoke (RestFn.java:1523)
    nrepl.middleware.interruptible_eval$evaluate.invokeStatic (interruptible_eval.clj:79)
    nrepl.middleware.interruptible_eval$evaluate.invoke (interruptible_eval.clj:55)
    nrepl.middleware.interruptible_eval$interruptible_eval$fn__917$fn__921.invoke (interruptible_eval.clj:142)
    clojure.lang.AFn.run (AFn.java:22)
    nrepl.middleware.session$session_exec$main_loop__1018$fn__1022.invoke (session.clj:171)
    nrepl.middleware.session$session_exec$main_loop__1018.invoke (session.clj:170)
    clojure.lang.AFn.run (AFn.java:22)
    java.lang.Thread.run (Thread.java:748)
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Projects
None yet
Development

No branches or pull requests

2 participants