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

Patch cljs tests #159

Merged
merged 5 commits into from
Mar 1, 2016
Merged

Patch cljs tests #159

merged 5 commits into from
Mar 1, 2016

Conversation

yurrriq
Copy link
Collaborator

@yurrriq yurrriq commented Mar 1, 2016

Subsumes #157.

ERROR in (set-semigroup) (:)
Uncaught exception, not in assertion.
expected: nil
  actual: #object[RangeError RangeError: Maximum call stack size exceeded]

See failing test output.

Stephen Nelson and others added 5 commits March 1, 2016 11:53
The function in question is marked internal, so this should not be a
breaking API change.
try-either was previously not implemented for clojurescript, causing
try-success-test and try-exception-test to fail.

This requires the try-either macro to detect when it is being expanded
in a cljs namespace, as reader conditionals have already been expanded
by the time macros are evaluated.

See https://groups.google.com/forum/#!topic/clojurescript/iBY5HaQda4A
for a discussion of the approach used.
Added type hints to avoid reflecting on fields at runtime. This should
provide a significant performance improvement for hot code.

Note, there is a trade-off with this approach: third party types will
no longer be useable in place of cats types because the field references
are no longer reflectively looked up by name but statically determined.
If this becomes a problem a better approach would be to add protocols for
retrieving shared values instead of direct field access.
The cljs tests should fail for this commit.

- Cosmetic tweaks
- Rename main to -main
- Use when-not and (aget js/process "exit")
  instead of (set! (.-exitCode js/process) n)

See #158
@yurrriq
Copy link
Collaborator Author

yurrriq commented Mar 1, 2016

@sfnelson et al., feel free to make a PR against patch-cljs-tests with a fix for the call stack size error.

@sfnelson
Copy link
Contributor

sfnelson commented Mar 1, 2016

I think the call stack size error is unrelated to the other changes. It occurred in a different function for me while I was running tests earlier today.

@yurrriq
Copy link
Collaborator Author

yurrriq commented Mar 1, 2016

The failure seems rather arbitrary and, as you say, unrelated to these changes. I was able to restart the build and turn everything green.

yurrriq added a commit that referenced this pull request Mar 1, 2016
@yurrriq yurrriq merged commit c6a2254 into master Mar 1, 2016
@sfnelson
Copy link
Contributor

sfnelson commented Mar 1, 2016

I had to leave the tests running for 10 minutes before it occurred for me locally. I think it depends on the seed given to quick-check, which unfortunately isn't printed when tests fail.

@ghost ghost deleted the patch-cljs-tests branch March 1, 2016 09:02
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.

2 participants