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

For AI integration tests, use config including user secrets #5706

Merged
merged 4 commits into from
Nov 29, 2024

Conversation

SteveSandersonMS
Copy link
Member

@SteveSandersonMS SteveSandersonMS commented Nov 29, 2024

I was getting tired of having to remember to set environment variables and restart VS whenever I wanted to run the integration tests. We were also a bit out of line with our recommendations in using GetEnvironmentVariable directly instead of going through the IConfiguration abstraction which allows for multiple configuration sources.

With this change, you can set your config just once using dotnet user-secrets and it will be stored in your user profile in a way that's scoped to this repo. Instructions added to readme file.

Alternatively you can continue using environment variables (though the names have changed to match .NET config naming conventions).

@dotnet-comment-bot
Copy link
Collaborator

🎉 Good job! The coverage increased 🎉
Update MinCodeCoverage in the project files.

Project Expected Actual
Microsoft.Extensions.Caching.Hybrid 75 86
Microsoft.Extensions.Diagnostics.Probes 70 76

Full code coverage report: https://dev.azure.com/dnceng-public/public/_build/results?buildId=882370&view=codecoverage-tab

@SteveSandersonMS SteveSandersonMS merged commit 5161cb9 into main Nov 29, 2024
6 checks passed
@SteveSandersonMS SteveSandersonMS deleted the stevesa/ai-tests-use-usersecrets branch November 29, 2024 16:07
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

3 participants