Seddryck / NBi

NBi is a testing framework (add-on to NUnit) for Business Intelligence and Data Access. The main goal of this framework is to let users create tests with a declarative approach based on an Xml syntax. By the means of NBi, you don't need to develop C# or Java code to specify your tests! Either, you don't need Visual Studio or Eclipse to compile your test suite. Just create an Xml file and let the framework interpret it and play your tests. The framework is designed as an add-on of NUnit but with the possibility to port it easily to other testing frameworks.
http://www.nbi.io
Apache License 2.0
106 stars 37 forks source link

Read environment variables from process rather than user scope #718

Closed fmms closed 1 year ago

fmms commented 1 year ago

Adjust to expected behavior and easier use in build systems.

Documentation of the different scopes of environment variables is at https://learn.microsoft.com/en-us/dotnet/api/system.environment.getenvironmentvariable?view=net-7.0#system-environment-getenvironmentvariable(system-string) .

Solves #717

I have not tested this myself as I have no corresponding build environment, but this should solve it ...

Seddryck commented 1 year ago

Thx I'll check this tonight.

Seddryck commented 1 year ago

The issue is related to this part of the doc regarding environment variables

If there is no parent process, per-machine and per-user environment variables are used instead. For example, a new console window has all per-machine and per-user environment variables defined at the time it was launched.

In the case of NUnit there is a parent process, so per-user environment variables are not pushed in the process scope.

Seddryck commented 1 year ago

I Can't figure out why the test is not working on AppVeyor when it works on Visual Studio. I took the time to review some details in the setup of the test environment on AppVeyor (QA related) but it's just to be sure that we are not blocked further. Will probably give another try tonight.

fmms commented 1 year ago

thank you so much for fixing this @Seddryck . You will be part of my presentation at SQL Konferenz. ;) When will 1.24 be released?

Seddryck commented 1 year ago

thank you so much for fixing this @Seddryck .

Just find out the issue with tests running in parallel and adding/removing the same variables.

You will be part of my presentation at SQL Konferenz. ;)

I saw that ... FYI I presented NBi 6-7 years ago at SQL Konferenz :-D

When will 1.24 be released?

I'll do some dependencies bump and then will release 1.24

fmms commented 1 year ago

i was in your audience at SQL Konferenz back then... ;)