How to do it...

To manage build operations, perform the following steps:

  1. Make a minor change to any code in your project and check-in the changes.
  2. Then, open the Azure DevOps project and select Builds from the Pipelines menu. You should see something like the following:

  1. Clicking on the description under the Commit column will take us to the details of the build; click on this link.
  2. This will open the details of the build operation with the Console open by default. This verbosely lists every detail of the operation as it happens. Any errors or warnings are also listed here.
  3. Once complete, check for errors. These will show up on the failed task with a summary of the error displayed. At this stage, the most common error is that the model descriptor file was not checked in to source control. A typical error is EXEC(0,0): Warning : 1:22:57 PM: No Models returned by model info provider from metadata.
  1. You may also notice that, even though no error was shown, no tests were run. The console will provide another clue:
No test assemblies found matching the pattern: 'C:\DynamicsSDK\VSOAgent\_work\2\Bin\**\*Test*.dll'. 
It is looking for DLLs that contain Test. We can see that naming conventions are important, albeit, in this case, possibly inelegant. It is like this because there is no way the build agent can see that the class in the DLL extends SysTestCase.
  1. It is likely that the descriptor was not added to source control. To rectify this, begin by opening Visual Studio and selecting Team Explorer. From there, select Source Control Explorer.
  2. Check whether the Descriptor folder is added to each package. In the following screenshot, the Descriptor folder is not listed under any folder. This can happen based on the version of the development tools:

  1. We add the Descriptor file by right-clicking on the package folder (the first ConVehicleManagement node, in this case) and selecting Add Items to Folder.... Add the Descriptor folder, but nothing else.
  1. Once done, the list should resemble the following screenshot:

  1. Checking in the changes will automatically trigger a build in the Build - Dev - Continuous pipeline. On the Azure DevOps site, select the Build - Dev - Continuous pipeline and click on the active build. This will look as follows:

  1. The build in progress has a blue circular icon. Click on its description to open the build details and look at the Checkout node. You should see entries similar to the following code snippet:
C:\DynamicsSDK\VSOAgent\_work\1\s\Metadata\ConProductionIntegration:
Getting Descriptor
C:\DynamicsSDK\VSOAgent\_work\1\s\Metadata\ConProductionIntegration\Descriptor:
Getting ConProductionIntegration.xml
C:\DynamicsSDK\VSOAgent\_work\1\s\Metadata\ConVehicleManagement:
Getting Descriptor
C:\DynamicsSDK\VSOAgent\_work\1\s\Metadata\ConVehicleManagement\Descriptor:
Getting ConVehicleManagement.xml
C:\DynamicsSDK\VSOAgent\_work\1\s\Metadata\ConVehicleManagementTest:
Getting Descriptor
C:\DynamicsSDK\VSOAgent\_work\1\s\Metadata\ConVehicleManagementTest\Descriptor:
Getting ConVehicleManagementTest.xml
  1. Once the build has finished, you should see the following on the build's summary page:

  1. Should a test fail, we can view the output from the test case, the work item history, and the change history, and create a bug that can be assigned to a developer. This can be seen in the following screenshot:

The default is to show only failed tests; to view them all, click on the outcome (for example, Failed) next to the Outcome label and choose All.