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

Improve SqlDataRecord test coverage #25171

Closed
saurabh500 opened this issue Feb 23, 2018 · 7 comments
Closed

Improve SqlDataRecord test coverage #25171

saurabh500 opened this issue Feb 23, 2018 · 7 comments

Comments

@saurabh500
Copy link
Contributor

Improve SqlDataRecord test coverage.
cc @RemiBou

@RemiBou
Copy link
Contributor

RemiBou commented Feb 23, 2018

(dotnet/corefx@master...RemiBou:master)

Added 2 tests, is that what you are expecting ? It seems that the first test (SqlRecordFillTest) is quite big and my tests are testing way less things, what do you prefer ?

@saurabh500
Copy link
Contributor Author

@RemiBou I think you are on the right track. I prefer smaller tests. They are more focussed and easier to debug

@RemiBou
Copy link
Contributor

RemiBou commented Feb 23, 2018

@saurabh500 on GetOrdinal, can I change the initialisation of _fieldNameLookup with a Lazy<> ? Or is that out of scope ? Or even not a good idea (it'll make this method thread safe)

@saurabh500
Copy link
Contributor Author

I would say it is out of scope for now until we figure out that Thread Safety is really needed here. If you find along the way, during your involvement that Thread Safety can be utilized here, I would go for it.

@RemiBou
Copy link
Contributor

RemiBou commented Feb 23, 2018

Given that GetOrdinal is called on the [] accessor, someone might Parallelize some calls (that would be interesting only on record with a lot of columns), but that's not obvious though

@RemiBou
Copy link
Contributor

RemiBou commented Feb 23, 2018

dotnet/corefx@master...RemiBou:master

+43 lines covered, is that still on phase with your policy/pratice ?

@saurabh500
Copy link
Contributor Author

Good stuff @RemiBou You are on point.
I would recommend running the Visual Studio, Code formatter to format your code before you send a PR.

@msftgits msftgits transferred this issue from dotnet/corefx Jan 31, 2020
@msftgits msftgits added this to the 2.1.0 milestone Jan 31, 2020
@ghost ghost locked as resolved and limited conversation to collaborators Dec 18, 2020
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Projects
None yet
Development

No branches or pull requests

3 participants