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

Test failures in 1.10.0+ #56

Open
NoahTheDuke opened this issue Sep 11, 2023 · 0 comments
Open

Test failures in 1.10.0+ #56

NoahTheDuke opened this issue Sep 11, 2023 · 0 comments

Comments

@NoahTheDuke
Copy link

NoahTheDuke commented Sep 11, 2023

Hey friends,

I tried running the test suite with clojure 1.10.3 and ran into some failures because of hardcoded assumptions about Reflector.java that have changed since 1.8. I'm not sure what a viable solution here is, as the tests are predicated on correctly listing entirely implementation-dependent information:

(deftest check-assumptions-about-exception
(is (= "Message for you, Sir!" (.getMessage ex)))
(is (= "prone.stacks_test$create_ex" (.getClassName clj-frame)))
(is (= "invokeStatic" (.getMethodName clj-frame)))
(is (= "stacks_test.clj" (.getFileName clj-frame)))
(is (= 8 (.getLineNumber clj-frame)))
(is (= "clojure.lang.Reflector" (.getClassName java-frame)))
(is (= "invokeConstructor" (.getMethodName java-frame)))
(is (= "Reflector.java" (.getFileName java-frame)))
(is (= 180 (.getLineNumber java-frame))))

(deftest normalize-frame-test
(is (= {:class-path-url "prone/stacks_test.clj"
:loaded-from nil
:file-name "stacks_test.clj"
:method-name "create-ex"
:line-number 8
:package "prone.stacks-test"
:lang :clj}
(normalize-frame clj-frame)))
(is (= {:class-path-url "clojure/lang/Reflector.java"
:loaded-from (clj-version)
:file-name "Reflector.java"
:method-name "invokeConstructor"
:line-number 180
:class-name "Reflector"
:package "clojure.lang"
:lang :java}
(normalize-frame java-frame)))

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

1 participant