cognitect-labs / vase

Data driven microservices
Eclipse Public License 1.0
373 stars 42 forks source link

Trying to figure out how to run the tests in the lein template #88

Closed CalebMacdonaldBlack closed 6 years ago

CalebMacdonaldBlack commented 6 years ago

Description

I'm attempting to try out some changes to the lein template but I'm running into issues getting tests to run without editing the tests themselves.

In order to get tests to run I need to change line 21 in template/test/com/cognitect/vase/new_server_integration_test.clj from:

(def project-dir
  (->
   (ClassLoader/getSystemResource *file*)
   io/file .getParent io/file .getParent))

to:

(def project-dir (ClassLoader/getSystemResource *file*))

I then run lein test from within the template directory.

I've had a look around and I can't seem to find where these tests are being run. So I wonder if these tests are being run at all, even on CircleCI as I cannot see anything testing the lein template.

If the tests are in fact not being run on CircleCI and this is not intended, I could submit a PR to fix this. I think the readme could be improved in the template also on how to test.

mtnygard commented 6 years ago

Hi Caleb,

You're correct, the template is not being tested. I've done it by hand a few times but it definitely suffers from drift. I was never able to figure out how to CI test a lein template. A pull request on that would be most welcome!