This attribute can be specified on a test class. There can be multiple instances of this attribute to specify more than one item. The item path can be absolute or relative. Relative paths are relative to the RelativePathRoot setting found in the .testrunconfig file.
The following examples demonstrate different usage of the DeploymentItemAttribute:
[DeploymentItem("file1.xml")] Deploys an item named file1.xml located at the RelativeRootPath. The file is deployed to the deployment root directory.
[DeploymentItem("file2.xml", "DataFiles")] Deploys an item named file2.xml located at the RelativeRootPath. The file is deployed to the DataFiles subdirectory of the deployment root directory.
[DeploymentItem("C:\\MyDataFiles\\")] Deploys all items and directories found within the MyDataFiles directory. This does not create the MyDataFiles directory underneath the deployment directory. All files and directories within MyDataFiles will be deployed to the deployment root directory. To copy the entire MyDataFiles directory structure, you must specify MyDataFiles as an output directory.
Of course, the truth of the matter is that I would rather use MBUnit :)
For those of you using VSTS for Database Professionals or Team Suite, you have the ability to create unit tests for your database stored procs, functions, views, and constraints. Sachin Rekhi has posted a nice little whitepaper on how to get started with Database Unit Testing.
I find writing DB unit tests much like writing them in C# except for one thing that threw me a curve ball. Besides the main test code, database tests have a 'pre-test' and 'post-test' code sections. But, unlike the [TestInitialize] and [TestCleanup] designated methods in .NET testing that are specified once but run the same for every test method in the test class, 'pre-test' and 'post-test' SQL scripts are specific for each test script. So, if you need to initialize some data in the database, you'll need to copy the 'pre-test' script for each individual test. Likewise, you'll need a copy of the 'post-test' script for every one, too. It seems like there should be an area to factor out common setup and cleanup SQL code for database testing, too.
Caleb and I have been working with VSTS and TFS quite a bit lately. I have much to post about problems and solutions we've encountered (soon). But until then, here's list from Brian Harry, a VSTS Product Group Manager at MS, about the list of features in TFS 2008. I'm especially intersted in the continuous integration feature since most of our customers are using Agile processes and interested in CI. I also like the idea of halting check-ins until the CI build is fixed.
A couple of cool new tools have just come out for Visual Studio.
Resharper 3.0 just came out of beta and is now generally available. Many of us at Improving use the heck out of this great VS plug-in. Refactoring, common code-gen, running NUnit tests, and just generally making Visual Studio better makes Resharper well worth the price.
I know several customers and partner firms exploring the use of Team Foundation Server as the new basis for source control management (SCM) within their organizations. One of the big concerns is support for older tools like VS2003 and VB6. It's been in beta fro a while, but MS finally released the Visual Studio Team Foundation Server MSSCCI Provider which provides the API for legacy source control clients to access TFS. Note that each user still has to have a Team Client CAL. So, it's really just for backwards compatibility, not an alternative to VS2005 team editions and the associated licensing costs.
SP1 for Team Foundation Server (eval, workgroup, and licensed editions)
SP1 for VS2005 Express Editions
VS2005 Update for compatibility with Vista (update still in beta)
I've been running the VS2005 SP1 and TFS SP1 patches since their release and am pretty pleased. I haven't encountered any crashes or unexplained behavior since installing.
But unfortunately, to run under Vista you're still supposed to start Visual Studio as an Administrator. I guess they have a ways to go in teaching VS to play nice with the Least-Privileged User Account features.
Team edition for Database professionals is out, and it contains database refactoring support. Very cool. From the Agile Databases yahoo group. I am pretty excited about this one, and I don't really even consider myself to be a database guy. Databases are usually one of the biggest interia fields in a solution, and automated support for refactoring will immprove the situation greatly. I am glad that Scott Ambler has been pushing on this button for a while with his agile data site and the new Martin Fowler series book on Database Refactoring. I haven't bought it yet. Anyone have any thoughts?
Clients and friends have asked me about using Team Foundation Server as a source control management system in conjunction with Visual Studio 2003 or VB6. I remembered hearing about something in the works for VS2003, so thought I'd look it up. Here is the Team Foundation Server MSSCCI Provider, which according to the page works for:
SQL Server 2005 Management Studio
Note that this is just an adapter from the regular TFS client to the MSSCCI spec. So, before installing, you must first install the Visual Studio 2005 Team Explorer. The Team Explorer is the TFS client that comes with TFS and includes a VS2005 shell if you don't already have it installed.
Ken Schwaber and Conchango have released SCRUM Process Guidance for VSTS. I am including his entire posting from the scrumdevelopment yahoo group. It is a very active group, and you can find some really insightful commentary there. Definitely consider subscribing.
I have worked closely over the last eighteen months with ConChango, a UK based consultancy, to prepare guidance for managing projects using Scrum. This work was prompted by our mutual concern over the quality and misdirection of Microsoft's initial contents, which badly represented Agile. I feared that, without adequate alternative, many Agile and Scrum "newbies" would think that the MS work actually had some resemblance to the real stuff.
I was and still am delighted with Conchango's help in this initiative.
They have not only invested strongly, but they have become potent Scrum advocates in the UK and throughout Europe. Even better, they did so without any direct belief in product sales or direct payback. Colin Bird, Howard vanRooijen, Ian Shimmings, and Steve Garnett all went way above and beyond their normal work to make this happen. As a result, the VSTS Scrum for Team Systems is now available, after an extensive Beta, as free downloads for use with VSTS, or as a standalone guidance system.
I am delighted to recommend that everyone take a look at this work.
See below for more details,
"Over the weekend we launched the microsite with the new process and multimedia guidance that we filmed when you were last over (I know I worked you hard - but I think the finished version was worth it). you can find it at: http://scrumforteamsystem.com/ProcessGuidance/ - we have also made the guidance available as a separate download, so that people can get access to the content even if they don't live in a Microsoft / Team System world – you can get access to the downloads from http://scrumforteamsystem.com/cs/forums/2/ShowPost.aspx
- I thought it might be a useful resource for your Certification Courses or people who are interested in getting started.
So far we've had 70 downloads in the first 12 hours and the first blog post I've found has been very flattering:
"I've been testing their Scrum for Team System product for awhile now and now they've released it as freeware...The add-in is pretty slick and covers all the major aspects of Scrum and is a much better implementation (IMHO) over something like MSF for Agile (that comes OOTB with TFS)"