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

Define a tests system #35

Open
iamFIREcracker opened this issue Jan 16, 2020 · 1 comment
Open

Define a tests system #35

iamFIREcracker opened this issue Jan 16, 2020 · 1 comment

Comments

@iamFIREcracker
Copy link

Hey,

Where do you stand on adding support for a "tests" system as well? Something along the lines of:

(asdf:defsystem #:(#| TMPL_VAR name |#)
  :description "Describe (#| TMPL_VAR name |#) here"
  :author "(#| TMPL_VAR author |#)"
  :license  "(#| TMPL_VAR license |#)"
  :version "0.0.1"
  :serial t(#| TMPL_IF depends-on |#)
  :depends-on (#| TMPL_VAR dependencies-string |#)(#| /TMPL_IF |#)
  :in-order-to ((test-op (test-op #:(#| TMPL_VAR name |#)/tests)))
  :components ((:file "package")
               (:file "(#| TMPL_VAR name |#)")))

(asdf:defsystem #:(#| TMPL_VAR name |#)/tests
  :description "Test suite for (#| TMPL_VAR name |#)"
  :author "(#| TMPL_VAR author |#)"
  :license  "(#| TMPL_VAR license |#)"
  :version "0.0.1"
  :serial t(#| TMPL_IF depends-on |#)
  :depends-on (#:(#| TMPL_VAR name |#))
  :perform (test-op (o c) ((declare (ignore o c))))
  :components ((:file "package")
               (:file "(#| TMPL_VAR name |#)")))

I am not confident with the templating engine, so it might not even work, but what I had in mind:

  • Define a new system, for tests
  • Add :in-order-to to the main system, to point to the tests system
  • Add dummy :perform (test-op... to the tests system

If you are open to this, I can put together a PR and actually test this works.

Thanks

@githubforced2fabad
Copy link

You can see my template project here has a test system. It works great. https://git.sr.ht/~charje/common-lisp-config/tree/master/item/project-template

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

2 participants