Skip to content

Organization of tests #30

Closed
Closed
@timbray

Description

@timbray

We have a lot of tests and some of them really aren’t “unit tests” but focused on coverage and concurrency, etc. Speaking as a developer, here are the things I want to do.

  1. Run unit tests in the directory I'm working in, the equivalent of go test.
  2. Run concurrency tests across all the directories. This is important since thread-safety is an important and advertised feature.
  3. Coverage tests, to support our coverage badge
  4. Linting tests
  5. Acceptance tests, including all of the above, when you think you’re ready to do a PR

I suppose the main activities would be (1), (2), and (3,4,5)

Notes.

  • For (1) we absolutely need to run in <10sec, so that a developer can run them every time they save a tiny change
  • (1) should include one benchmark test to catch performance regressions, which can easily creep in even on a minor change. I think TestCityLots is a good choice since it explores worst-case performance of the Flattener and Matcher.
  • The -race flag really slows things down, in particular the concurrency tests. I don't think it's really needed in case (1)?

If it were 20 years ago, I think I’d say “we need a Makefile”. Um… I think we need a Makefile?

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