For sevearl months I have been looking at the eXtreme Programming practice that says you must have automated acceptance tests and essentially ignoring it because I couldn't figure out how best to go about it.
After my time at ObjectMentor I have an approach. Here is what I envision:
- As part of requirements gathering/story creation first define what an acceptance test looks like, what is the language that one would use to run a specific test. This step is performed by collaboration between the engineers and the customers.
For example:
- PlaceItemUpForAuction("Cow");
- PlaceItemUpForAuction("Sheep");
- VerifyItemIsOnAuctionBlock("Sheep");
- BidOnItem("James", "Sheep", 30);
- BidOnItem("Mary", "Sheep", 45);
- BidOnItem("James", "Sheep", 59);
- VerifyCurrentWinner("Sheep", "James");
- VerifyCurrentHighBid("Sheep", 59);
- Write unit tests and code implementation for first acceptance test instruction.
- Create AuctionAcceptanceTestBase class inside unit test assembly with a static method called PlaceItemUpForAuction(string itemName).
- Repeat steps 2 and 3 for all acceptance test instructions.
Notes:
- There is not necessarily a acceptance test for every assembly.
1:56:30 PM
|
|