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

Babashka test runner #71

Closed
wants to merge 6 commits into from
Closed

Conversation

borkdude
Copy link
Contributor

@borkdude borkdude commented Dec 2, 2022

The test runner is currently using a dev version of babashka which implements some previous special-forms as macros.

@borkdude
Copy link
Contributor Author

borkdude commented Dec 2, 2022

I skipped some test namespaces due to the incompatibility with missionary:

Message:  Unable to resolve classname: org.reactivestreams.Publisher
Location: missionary/impl.clj:2:3

@borkdude
Copy link
Contributor Author

borkdude commented Dec 2, 2022

I'm sorry that I made some unnecessary whitespace changes as a result of activating the formatter in my editor. I can revert those if you want.

@borkdude
Copy link
Contributor Author

borkdude commented Dec 7, 2022

@dustingetz I released a new version of babashka and used that in the tests. PR should be good to go from my side.

@pmbauer
Copy link

pmbauer commented Jul 12, 2023

Locally, I've used a version of RCF and babashka with this pull applied. Any blockers to getting it merged?

@dustingetz
Copy link
Member

I attempted to merge today, there is a conflict with this commit: 2d1ef6f

@borkdude can you quickly spot the issue? I will take a closer look later, gtg

I f'ed up the PR, sorry, i guess i force pushed the wrong thing. Master currently has babashka support merged and pushed, but fails CI in babashka due to the conflict, which is a correct error (I bisected)

@dustingetz
Copy link
Member

rcf git:(babashka-dustin4) ./ci/run_tests_bb.sh
Running Babashka tests
----- Error --------------------------------------------------------------------
Type:     clojure.lang.ExceptionInfo
Message:  Method getName on class sci.lang.Namespace not allowed!
Data:     {:type :sci/error, :line 20, :column 1, :file "/Users/dustin/src/hf/rcf/test/hyperfiddle/rcf_test.cljc"}
Location: /Users/dustin/src/hf/rcf/test/hyperfiddle/rcf_test.cljc:20:1
Phase:    macroexpand

----- Context ------------------------------------------------------------------
16:                     :form4 (quote (inc 1)) ; interpreted as if evaluated after code emission  
17:                     :form5 (quote (quote (inc 1))) ; escaping interpretation
18:                     )))
19: 
20: #?(:clj
    ^--- Method getName on class sci.lang.Namespace not allowed!
21:    (tests
22:      "Custom var meta on def symbol are interpreted as if they were evaluated after emission."
23:      ;; CLJ only, no vars in cljs.
24:      (my-def ^{:form1 (quote (inc 1))
25:                :form2 (inc 1)}        ; read and evaluated as usual

----- Stack trace --------------------------------------------------------------
hyperfiddle.rcf/tests                          - /Users/dustin/src/hf/rcf/src/hyperfiddle/rcf.cljc:106:1
hyperfiddle.rcf-test/apply                     - /Users/dustin/src/hf/rcf/test/hyperfiddle/rcf_test.cljc:20:1
hyperfiddle.rcf-test                           - /Users/dustin/src/hf/rcf/test/hyperfiddle/rcf_test.cljc:20:1
clojure.core/apply                             - <built-in>
runner                                         - /Users/dustin/src/hf/rcf/bb/runner.clj:15:5
exec-d0f5b07e-cbd6-42af-82a4-361e5b511f13/exec - <expr>:22:1
exec-d0f5b07e-cbd6-42af-82a4-361e5b511f13      - <expr>:4:1
user-a5406db3-03a4-4cbd-80cd-08ebb1b8978d      - <expr>:26:1

@borkdude
Copy link
Contributor Author

Don't worry, I'll take a look :)

@dustingetz
Copy link
Member

Confirmed electric test suite passes with the babashka support applied, so this is all clear as soon as we fix the conflict. I took a closer look at the conflict and it is nontrivial.

@borkdude
Copy link
Contributor Author

@dustingetz Fixed in #79

@borkdude borkdude closed this Jul 20, 2023
@dustingetz
Copy link
Member

thank you!

@pmbauer
Copy link

pmbauer commented Jul 21, 2023 via email

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

Successfully merging this pull request may close these issues.

3 participants