Click here to Skip to main content
15,885,875 members
Home / Discussions / C#
   

C#

 
AnswerRe: Should I unit test private methods? PinPopular
Pete O'Hanlon6-Feb-18 0:11
mvePete O'Hanlon6-Feb-18 0:11 
GeneralRe: Should I unit test private methods? Pin
OriginalGriff6-Feb-18 0:53
mveOriginalGriff6-Feb-18 0:53 
GeneralRe: Should I unit test private methods? Pin
Hila Berger7-Feb-18 0:24
Hila Berger7-Feb-18 0:24 
GeneralRe: Should I unit test private methods? Pin
Pete O'Hanlon7-Feb-18 1:05
mvePete O'Hanlon7-Feb-18 1:05 
AnswerRe: Should I unit test private methods? Pin
Eddy Vluggen6-Feb-18 14:43
professionalEddy Vluggen6-Feb-18 14:43 
GeneralRe: Should I unit test private methods? Pin
Hila Berger6-Feb-18 23:58
Hila Berger6-Feb-18 23:58 
AnswerRe: Should I unit test private methods? Pin
GregoryPres7-Feb-18 22:14
GregoryPres7-Feb-18 22:14 
AnswerRe: Should I unit test private methods? Pin
Frygreen22-Feb-18 10:46
Frygreen22-Feb-18 10:46 
It depends on your risk-estimation.
If you think the private methods are fault-free. => No UnitTest
If you think the private methods can have bugs, but the consequences are tolerable. => No UnitTest
If you think the private methods can have bugs, but the consequences are NOT tolerable. => Unittest them.

Example 1:
If you are contributing "private" code to your team and you think some bugs are tolerable => No Unittest.

Example 2:
If your "private" code controls the cooling-system of a nuclear power-plant and you think the risk of bugs is tolerable => No UnitTest

If you consider your question in this way (as I do in practice), the answer is quite easy.
If you still don't know what to do, ask your boss, if he accepts bugs in "private" code or not.

modified 23-Feb-18 16:34pm.

QuestionLinq Query Limitations, more than one query fails Pin
Member 136243255-Feb-18 10:47
Member 136243255-Feb-18 10:47 
AnswerRe: Linq Query Limitations, more than one query fails Pin
Dave Kreskowiak5-Feb-18 10:55
mveDave Kreskowiak5-Feb-18 10:55 
GeneralRe: Linq Query Limitations, more than one query fails Pin
Member 136243255-Feb-18 11:09
Member 136243255-Feb-18 11:09 
GeneralRe: Linq Query Limitations, more than one query fails Pin
Member 136243255-Feb-18 11:14
Member 136243255-Feb-18 11:14 
GeneralRe: Linq Query Limitations, more than one query fails Pin
Member 136243255-Feb-18 11:20
Member 136243255-Feb-18 11:20 
QuestionPreferred connection to database, config or class? Pin
bjay tiamsic4-Feb-18 12:46
bjay tiamsic4-Feb-18 12:46 
AnswerRe: Preferred connection to database, config or class? Pin
OriginalGriff4-Feb-18 19:59
mveOriginalGriff4-Feb-18 19:59 
GeneralRe: Preferred connection to database, config or class? Pin
bjay tiamsic5-Feb-18 19:48
bjay tiamsic5-Feb-18 19:48 
GeneralRe: Preferred connection to database, config or class? Pin
Pete O'Hanlon5-Feb-18 20:06
mvePete O'Hanlon5-Feb-18 20:06 
AnswerRe: Preferred connection to database, config or class? Pin
Eddy Vluggen5-Feb-18 1:18
professionalEddy Vluggen5-Feb-18 1:18 
QuestionPeak Search Algorithm with sliding window and peak excursion Pin
Krellon31-Jan-18 22:46
Krellon31-Jan-18 22:46 
AnswerRe: Peak Search Algorithm with sliding window and peak excursion Pin
Pete O'Hanlon31-Jan-18 22:49
mvePete O'Hanlon31-Jan-18 22:49 
GeneralRe: Peak Search Algorithm with sliding window and peak excursion Pin
Krellon31-Jan-18 23:13
Krellon31-Jan-18 23:13 
GeneralRe: Peak Search Algorithm with sliding window and peak excursion Pin
Pete O'Hanlon1-Feb-18 3:32
mvePete O'Hanlon1-Feb-18 3:32 
GeneralRe: Peak Search Algorithm with sliding window and peak excursion Pin
Krellon1-Feb-18 4:45
Krellon1-Feb-18 4:45 
GeneralRe: Peak Search Algorithm with sliding window and peak excursion Pin
OriginalGriff1-Feb-18 4:46
mveOriginalGriff1-Feb-18 4:46 
GeneralRe: Peak Search Algorithm with sliding window and peak excursion Pin
Krellon1-Feb-18 5:02
Krellon1-Feb-18 5:02 

General General    News News    Suggestion Suggestion    Question Question    Bug Bug    Answer Answer    Joke Joke    Praise Praise    Rant Rant    Admin Admin   

Use Ctrl+Left/Right to switch messages, Ctrl+Up/Down to switch threads, Ctrl+Shift+Left/Right to switch pages.