terminal/tools/tests.xml
Ian O'Neill c8f00df170
Fix code-format and test invocation through PowerShell
Fixes the `Invoke-CodeFormat` and `Invoke-OpenConsoleTests` functions in `OpenConsole.psm1` so that they can be run directly from PowerShell.

Addresses the issues found when creating #10447.

`Invoke-CodeFormat` did not work when invoked directly from PowerShell due to a relative path being passed into the .NET function `[IO.File]::WriteAllLines()`. The working directory for .NET objects does not change when you change directory in PowerShell, so the paths were being treated as relative to the initial working directory of the shell - which was not the terminal git repo.

`Invoke-OpenConsoleTests` had 3 issues:
1. The path to `TestHostApp` was wrong.
2. It would attempt to run the "in host app" tests both in the host app and not in the host app.
3. The test configuration in `tests.xml` wasn't in sync with the `runABC.cmd` files, so the remoting and control unit tests didn't run.

## Validation Steps Performed
1. Ran `Invoke-CodeFormat` and `runformat.cmd` from multiple directories and didn't see errors.
2. Ran `Invoke-OpenConsoleTests` and didn't see errors.
2021-06-21 16:52:59 +02:00

19 lines
1.4 KiB
XML

<!-- Used by Invoke-OpenConsoleTests in OpenConsole.psm1. Keep in sync with runABC.cmd files -->
<tests>
<test name="host" type="unit" binary="Conhost.Unit.Tests.dll" />
<test name="textBuffer" type="unit" binary="TextBuffer.Unit.Tests.dll" />
<test name="terminalCore" type="unit" binary="UnitTests_TerminalCore\Terminal.Core.Unit.Tests.dll" />
<test name="terminalApp" type="unit" binary="UnitTests_TerminalApp\Terminal.App.Unit.Tests.dll" />
<test name="localTerminalApp" type="unit" runInHostApp="true" binary="TerminalApp.LocalTests.dll" />
<test name="localSettingsModel" type="unit" runInHostApp="true" binary="SettingsModel.LocalTests.dll" />
<test name="unitRemoting" type="unit" binary="UnitTests_Remoting\Remoting.Unit.Tests.dll" />
<test name="unitControl" type="unit" binary="UnitTests_Control\Control.Unit.Tests.dll" />
<test name="interactivityWin32" type="unit" binary="Conhost.Interactivity.Win32.Unit.Tests.dll" />
<test name="terminal" type="unit" binary="ConParser.Unit.Tests.dll" />
<test name="adapter" type="unit" binary="ConAdapter.Unit.Tests.dll" />
<test name="types" type="unit" binary="Types.Unit.Tests.dll" />
<test name="til" type="unit" binary="til.unit.tests.dll" />
<test name="feature" type="ft" binary="Conhost.Feature.Tests.dll" />
<test name="uia" type="ft" binary="Conhost.UIA.Tests.dll" />
</tests>