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

Fix | Fix Unit Tests for GetSqlServerSPN #2442

Open
wants to merge 8 commits into
base: main
Choose a base branch
from

Conversation

arellegue
Copy link
Contributor

@arellegue arellegue commented Apr 3, 2024

This PR is for the addition of Unit Tests of the GetSqlServerSPNs function of SNIProxy class.

The unit tests is to ensure that the GetSqlServerSPNs function returns a port number for TCP protocol and returns an instance name for NP protocol.

In addition, unit tests were added to test the DataTestUtility.ParseDataSource function.

Added unit test to test GetSqlServerSPNs function to return port number for TCP and instance name for NP.
@DavoudEshtehari DavoudEshtehari added this to the 6.0-preview1 milestone Apr 12, 2024
@DavoudEshtehari DavoudEshtehari added 🐛 Bug! Something isn't right ! netcore labels Apr 12, 2024
Copy link

codecov bot commented Apr 26, 2024

Codecov Report

Attention: Patch coverage is 85.37549% with 37 lines in your changes are missing coverage. Please review.

Project coverage is 72.68%. Comparing base (9056f13) to head (1b6fe95).
Report is 40 commits behind head on main.

❗ Current head 1b6fe95 differs from pull request most recent head b2ef4c5. Consider uploading reports for the commit b2ef4c5 to get more accurate results

Files Patch % Lines
...qlClient/src/Microsoft/Data/SqlClient/TdsParser.cs 81.37% 19 Missing ⚠️
...crosoft/Data/SqlClient/SSPI/SSPIContextProvider.cs 64.70% 6 Missing ⚠️
...t/Data/SqlClient/SSPI/NativeSSPIContextProvider.cs 85.71% 3 Missing ⚠️
...icrosoft/Data/SqlClient/Server/MetadataUtilsSmi.cs 85.71% 3 Missing ⚠️
...icrosoft/Data/SqlClient/SqlSequentialTextReader.cs 81.25% 3 Missing ⚠️
.../netcore/src/Microsoft/Data/SqlClient/TdsParser.cs 87.50% 1 Missing ⚠️
...osoft/Data/SqlClient/TdsParserStateObjectNative.cs 66.66% 1 Missing ⚠️
...nt/netfx/src/Microsoft/Data/SqlClient/TdsParser.cs 85.71% 1 Missing ⚠️
Additional details and impacted files
@@            Coverage Diff             @@
##             main    #2442      +/-   ##
==========================================
+ Coverage   66.85%   72.68%   +5.82%     
==========================================
  Files         304      313       +9     
  Lines       61576    61727     +151     
==========================================
+ Hits        41168    44865    +3697     
+ Misses      20408    16862    -3546     
Flag Coverage Δ
addons 92.88% <ø> (∅)
netcore 76.95% <91.11%> (+5.88%) ⬆️
netfx 70.40% <83.33%> (+5.80%) ⬆️

Flags with carried forward coverage won't be shown. Click here to find out more.

☔ View full report in Codecov by Sentry.
📢 Have feedback on the report? Share it here.

…ion of InstanceName property.

Add IntanceName initialization using reflection instead in the unit test instead.
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
🐛 Bug! Something isn't right ! netcore
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

4 participants