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

Eliminate implementation-specific tests #150

Open
canweriotnow opened this issue Nov 1, 2016 · 2 comments
Open

Eliminate implementation-specific tests #150

canweriotnow opened this issue Nov 1, 2016 · 2 comments
Labels

Comments

@canweriotnow
Copy link
Contributor

Inspired by a review of #149 (fix for #148) - a new test was failing based on a (IMHO) poorly constructed state atom in the robot-names exercise example; one of the beauties of Clojure, and, a fortiori, testing in Clojure is being able to test pure functions with pure functions, rather than relying on underlying implementation details for mutable state.

This issue calls for a review of all tests in @exercism/clojure and there related examples to ensure that tests only check for functionality without relying on the behavior of particular stateful constructs to pass.

@bobbicodes
Copy link
Member

I understand this is from 5 years ago but I think it raises a strong point that likely should still be visited! I imagine that many of the unit tests were ported from other tracks without much regard for how we would actually do it ;)

@rthouvenin
Copy link

I was also very surprised to see that the tests expect reset-name to have side-effects rather than return a robot with a different name. This is unlike any clojure code I've seen

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants