Monitoring and Analyzing BuildsBuild information is provided in Visual Studio through the Team Build Browser. This browser window provides a list of completed or in-flight builds, and it functions as the principal mechanism for viewing build progress or completed summary reports. Introducing the Team Build BrowserThe Team Build Browser, shown in Figure 23.14, provides a snapshot of any build by indicating whether it succeeded, failed, or is in progress; the name of the build; the quality of the build; and the date it was completed.
Figure 23.14. The Team Build Browser.
Tip If you or other members of the project team want to be notified when a build has been completed, you can use the Team Foundation Server project alerts feature. TFS defines two build-related events that you can subscribe to: Build Completed and Build Quality Changed. The browser enables you to access the report for a specific build and set the build's quality state. Setting a Build's Quality StateTeam Foundation Build comes with a stock set of quality states that the QA group can select from when indicating the quality of a given build:
As part of the build process, the QA group would visit the Team Build Browser and change a build's quality state to indicate to the rest of the team what their tests have found. You can do this quite easily by clicking in the column and selecting one of the states, as shown in Figure 23.15.
Figure 23.15. Setting the build quality state.
In addition to the stock quality states, you can also add your own. Just select the Edit option in the Build Quality drop-down. Using the Edit Build Quality dialog box (see Figure 23.16), you can add new states or remove one of the existing ones.
Figure 23.16. Adding a new build quality state.The Build ReportTo view reports for both in-progress and completed builds, you double-click the build within the Team Build Browser. Each report is hosted within a document window opened in Visual Studio and has the following sections:
Figure 23.17 shows a build report open in Visual Studio.
Figure 23.17. A build report.
Work items once again provide a correlation mechanism for associating builds and other team project artifacts. For example, consider the following chain of information:
|
Summary
In this chapter, we covered the use of Team Foundation Build to automate and manage simple to complex build processes within a team project. Team Foundation Build allows you to treat builds as an integral piece to the team project.
On the server, Team Foundation Build provides a database, build engine, and common web services interface for defining, executing, and analyzing software builds. This chapter presented the logical and physical architecture of the Team Foundation Build components and showed how they coexist within the larger Visual Studio Team System technical framework. By using loosely coupled tiers, Team Foundation Build enables you to scale out build environments by assigning Build server functionality to a shared server, a dedicated server, or even multiple servers in a farm configuration.
On the client, a series of windows integrated into Visual Studio allows team members in all roles to easily participate in the build process. In this chapter, we described how the Team Explorer is used to define new build types and run those builds from within the IDE. And finally, this chapter toured the capabilities of the Team Build Browser to monitor and analyze the results of builds.