29.05.2015 Views

o_19mgorv9t13a3ko71fev19l81mqa.pdf

Create successful ePaper yourself

Turn your PDF publications into a flip-book with our unique Google optimized e-Paper software.

e included in new projects are excellent–but you can manually set up all of the content and configuration and, in doing so, learn<br />

more about the workings of the MVC Framework.<br />

When you have created the three projects, the Solution Explorer should look like Figure 7-2. I have deleted the Class1.cs<br />

file that Visual Studio adds to the SportsStore.Domain project. I will not be using it.<br />

Figure 7-2. The projects shown in the Solution Explorer window<br />

To make debugging easier, right-click the SportsStore.WebUI project and select Set as Startup<br />

Project from the pop-up menu (you will see the name turn bold). This means that when you select Start Debugging<br />

or Start without Debugging from the Debug menu, it is this project that will be started.<br />

Visual Studio will try to navigate to individual view files if you are editing them when you start the debugger, so right-click the<br />

SportsStore.WebUI project in the Solution Explorer and select Properties from the pop-up menu. Click on Web<br />

to open the web-related properties and select the Specific Page option. There is no need to enter a value into the<br />

Specific Page text field. Just selecting the option is enough to stop Visual Studio from trying to guess the URL you want<br />

to view and ensure that the browser requests the root URL for the application when you start the debugger.<br />

Installing the Tool Packages<br />

I will be using Ninject and Moq in this chapter. Select Tools Library Package Manger Package<br />

Manager Console in Visual Studio to open the NuGet command line and enter the following commands:<br />

164

Hooray! Your file is uploaded and ready to be published.

Saved successfully!

Ooh no, something went wrong!