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

.runsettings file with VS Mac and NUnit 3 VS Adapter #778

Open
LiohAu opened this issue Aug 20, 2020 · 5 comments
Open

.runsettings file with VS Mac and NUnit 3 VS Adapter #778

LiohAu opened this issue Aug 20, 2020 · 5 comments
Labels
External Tracked here, but must be fixed in external tool ReportedToMS VS Issue

Comments

@LiohAu
Copy link

LiohAu commented Aug 20, 2020

I don’t know if I am facing a bug or not, but the parameters of my .runsettings file are not accessible from the TestContext.Parameters variable when I run a test.

I am using VS Mac and I did not find a window to indicate the .runsettings to use, so I tried to add thoses lines of code to my .csproj, but that still does not work :

$(MSBuildProjectDirectory).runsettings

I am using NUnit with SPecFlow (if that matters).

Thanks for your help.

@OsirisTerje
Copy link
Member

image

If you don't see the same, please show a screenshot of how it looks on your side.

@LiohAu
Copy link
Author

LiohAu commented Aug 20, 2020

Here is how it looks like on my side :

Capture d’écran 2020-08-20 à 10 14 34

The "Custom parameters" things seems to open a window that is more related to command line parameters to be passed to mono OR environment variables to be set for running.

Here how this window looks like :

Capture d’écran 2020-08-20 à 10 19 12

@kendrahavens
Copy link

Runsettings support in VS for Mac is currently on the backlog. https://developercommunity.visualstudio.com/idea/562230/how-to-select-runsettings-file-n-visual-studio-201.html

In the meantime, my suggestion would be to use the integrated terminal in VS for Mac for test runs and specify the runsettings file at the command-line.

@OsirisTerje OsirisTerje added External Tracked here, but must be fixed in external tool ReportedToMS VS Issue and removed is:question labels Aug 24, 2020
@LiohAu
Copy link
Author

LiohAu commented Oct 22, 2020

Nothing new on that topic ? If creating an UI that allows selection of the runsettings file is too long, could we provide the runsettings by a parameter in the .config or by an environment variable ?

@denislutz
Copy link

Faced the same issue, here is how you can call it from commandline and provide a runsettings file

dotnet test Your.TestCases.csproj -s yourConfig.runsettings --filter "SomeFilterKeyWord"

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
External Tracked here, but must be fixed in external tool ReportedToMS VS Issue
Projects
None yet
Development

No branches or pull requests

4 participants