Im trying to structure my winforms project in accordance with the suggested layout in this blog post Code Rant.
originally, i had managed to have multiple solution files, dont know how i managed it. Anyway ive heard there should only be one. Also been told to have one class per file (i sometimes had 2 or 3 in one class file.)
What im having problems understanding is what each of these should be. In the link he has 3 project for that solution.
[QUESTION] should i do the following: solution(right click)->Add->New Project->Winform Application, and then just delete out the form1.cs and Program.cs?
Ive tried solution(right click)->Add->Solution Folder but this doesnt give the same layout as he has.
[QUESTION] When should i use a class library in his example? Originally i had all my classes stored in folders in a class library.
[QUESTION] Where should my unit testing code go?
Any assistance would be appreciated.
I think all his projects have
ClassLibrarytype, because there is no references toSystem.Windows.Form.dll. To create same solution structure, just add threeClassLibraryprojects to your solution.Your unit testing should go to separate projects (also of type
ClassLibrary).