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

Batch (console) runner for TestCentric #831

Open
CharliePoole opened this issue Oct 20, 2021 · 4 comments
Open

Batch (console) runner for TestCentric #831

CharliePoole opened this issue Oct 20, 2021 · 4 comments
Assignees
Labels
Feature A new feature. Needs Discussion We should discuss this with team and users before proceeding Normal Priority Normal priority issue
Milestone

Comments

@CharliePoole
Copy link
Contributor

TestCentric is currently the only standalone runner, which is able to run both .NET Core and .NET Framework tests together, in one run, and combine the results.

This makes having a batch runner, which could be used in a CI environment a very attractive proposition.

The GUI itself is already run in our own CI tests. However, this somewhat wasteful of resources in the general case. A batch runner would essentially just be a different front end, displaying only to console and saving a result file as is now done.

@CharliePoole CharliePoole self-assigned this Oct 20, 2021
@CharliePoole CharliePoole added Feature A new feature. Normal Priority Normal priority issue labels Oct 20, 2021
@CharliePoole CharliePoole added this to the 2.0.0 milestone Oct 20, 2021
@CharliePoole
Copy link
Contributor Author

CharliePoole commented Oct 20, 2021

Initial "specs" for the console runner...

Program Name

Executable is tc-console.exe. May also create tc.exe or an equivalent shell command to invoke it (see Command Syntax below).

Features

  • Run the tests specified in the command-line. Display an error message and return an error code if none are provided, otherwise, return an NUnit-compatible result code. Save result to TestResult.xml in the current directory by default, using nunit3 format.

  • Explore the tests specified in the command-line. Display an error message and return an error code if none are provided, otherwise, return an NUnit-compatible result code. Save result to TestResult.xml in the current directory by default, using nunit3 format.

  • Display or modify TestCentric settings from the command-line.

  • List extension points and installed extensions. Add, remove, enable and disable extensions.

  • Display the version of the runner and engine in use.

  • Display help messages.

Command Syntax

Two basic options...

  1. Files and options similar to NUnit. Examples...

    • tc-console mytests.dll
    • tc-console mytests.dll --explore
  2. Sub-Commands similar to git or dotnet (I'm inclining toward this option)

    • tc-console [run] mytests.dll // run sub-command is default if no command is given
    • tc-console explore mytests.dll

Note: In either case, we might allow use of tc rather than tc-console, e.g.: tc explore mytests.dll

Sub-Commands

If we go the sub-command route, the initial list I'm considering is...

  • run - to run tests
  • explore - to explore tests
  • extensions - to list, add, remove, enable and disable extensions.
  • settings - to list, add, update and remove application settings
  • version - to display version information
  • info - to display extended info (version + settings + extensions)
  • help - to display help text

@CharliePoole CharliePoole added the Needs Discussion We should discuss this with team and users before proceeding label Oct 20, 2021
@CharliePoole
Copy link
Contributor Author

@TestCentric/gui-team Any thoughts on this?

@immeraufdemhund
Copy link
Contributor

is there an option to continue watching the assembly and rerun all the tests like you would with npm test or simlar. I like it when I can just save my file and it runs my tests. It's harder for compiled tests I guess.. but that used to be an option right?

@CharliePoole
Copy link
Contributor Author

It was an NUnit V2 GUI option and it is still an option for the TestCentric GUI. It makes sense in a GUI, since the program is kept open all the time.

When a console runner is used, running on change is generally done by a separate watcher program, which launches it when it sees a change. While it could be done internally, I'm not sure I see the advantage.

@CharliePoole CharliePoole modified the milestones: 2.0.0, 2.1.0 Sep 30, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Feature A new feature. Needs Discussion We should discuss this with team and users before proceeding Normal Priority Normal priority issue
Projects
None yet
Development

No branches or pull requests

2 participants