diff --git a/src/runner/koans.clj b/src/runner/koans.clj index fcbdaf8..bc7c514 100644 --- a/src/runner/koans.clj +++ b/src/runner/koans.clj @@ -47,9 +47,10 @@ (println "Problem in" file-path) (println "---------------------") (println "Assertion failed!") - (println (.replaceFirst (.getMessage (.getCause e)) - "^Assert failed: " - "")) + (let [actual-error (or (.getCause e) e) + message (or (.getMessage actual-error) + (.toString actual-error))] + (println (.replaceFirst message "^Assert failed: " ""))) false))) (defn namaste []