Which five actions should you perform in sequence?

DRAG DROP
You are building an ASP.NET application for a purchasing system.
The application has a method named CalculateBalance in the Purchasing class.
You need to create a unit test for the CalculateBalance method.
Which five actions should you perform in sequence? To answer, move the appropriate actions from the list of
actions to the answer area and arrange them in the correct order.
Select and Place:

DRAG DROP
You are building an ASP.NET application for a purchasing system.
The application has a method named CalculateBalance in the Purchasing class.
You need to create a unit test for the CalculateBalance method.
Which five actions should you perform in sequence? To answer, move the appropriate actions from the list of
actions to the answer area and arrange them in the correct order.
Select and Place:

Answer:

Explanation:
Step 1: Select the Purchasing Project and add a new Unit Test Project.
First we create a Unit Test Project within the current project.
Step 2:

You can turn an existing unit test into an ASP.NET unit test by configuring it, that is, by assigning values to
certain of the test’s custom attributes. You set these values in the code file that contains the unit test.
All unit tests require the [TestMethod] attribute.
Step 3: Build the solution
Step 4: Run all tests
Step 5: Debug the solution
After you run a unit test, if you chose to edit the test run configuration when you ran the test, you can open the
Code Coverage window to see what percentage of the methods in the code that you are testing were covered
by your unit tests.Incorrect:
Not:

You do not set up testing by creating copies of methods.
https://msdn.microsoft.com/en-us/library/ms182526(v=vs.90).aspx



Leave a Reply 3

Your email address will not be published. Required fields are marked *


Sinan Uysal

Sinan Uysal

Answer is wrong, Correct answer is:
1. Select the Purchasing project and add a new Unit test project
2. Create a reference to the Purchasing project in the unit test project. Then create a test class that has a copy of…….
3. Add the TestClass attribute to the test class and the…..
4. Build the solution
5. Run all tests

https://msdn.microsoft.com/en-us/library/ms182532.aspx

Pascal

Pascal

You dont need to build the solution since the reference has already been created, its a tricky question, just run all test and debug

Vincent

Vincent

2. Create a reference to the Purchasing project in the unit test project. Then create a test class that has a copy of…….

This step is half correct. You need to create a reference, but you do not have to create a copy of the method.