Skip to content

Define a tests system #35

@iamFIREcracker

Description

@iamFIREcracker

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

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions