Skip to content

Platform-specific grouping of tests for npm test #41

Closed
@CMCDragonkai

Description

@CMCDragonkai

Specification

It would be ideal that upon running npm test or npm run test that it would execute all general tests, and then detect which platform we are on, and run platform-specific tests.

This would require the ability to "tag" certain tests to only be performed for platform specific group. Tagging would allow us to set the os.platform(), os.arch() and other arbitrary tags to be required.

Seems like there are 3 general solutions:

  1. Using jest-group-runner - this relies on comment annotations, and it seems to be file-specific
  2. Using separate directories and testing for platform requirements in a the shell - this is complicated by the fact that windows doesn't have the same shell
  3. Using conditional test functions - this requires creating some conditional utility functions, and this becomes specific a single test function, perhaps conditional describe can also be used

Additional context

Tasks

  1. ...
  2. ...
  3. ...

Metadata

Metadata

Assignees

Labels

Type

No type

Projects

No projects

Milestone

No milestone

Relationships

None yet

Development

No branches or pull requests

Issue actions