Geeks With Blogs
Josh Reuben
  • Ensure your developers build code to meet the spec (the contract of customer requirements) in a timely manner
  • Ensure your developers build code changes that don’t break the spec and that pass functional requirements
  • Ensure your developers build code which is robust (not fragile) and that meets design and code quality guidelines
  • Make sure that the technical analyst provides appropriate specs!
  • Keep it deliverable – compile-able. No point building mounds of UML diagrams that don’t stay in synch with the project
  • consists of: Use Case Scenarios, Interfaces, Code Contracts, Unit Tests, pre & post conditions.
  • To plug in Use Case Scenarios, need a generic baseline architecture.
  • Scenarios and Tasks
    • Each use case focuses on describing how an end user or client can achieve a goal.
    • Forces you to think about the spec functional requirements.
    • decompose into Tasks
    • Scenarios and their Tasks map to VSTS.
    • checkin policies force developers to associate each changeset with a task – track progress, avoid unnecessary work.
    • From nouns in scenarios identify entities. Each task maps to a method.
    • Consider Workflows – each scenario maps to a sequential or state machine Workflow and each task maps to an Activity
  • VSTS benefits
    • 20 tools in one
    • Integrated work item list – scenarios, bugs, tasks, tests, QoS
    • Source control with Checkin policies
    • Database schema version control, comparison and test data generation
    • Real Project health tracking via reportage
    • Integrated testing environment – 6 types of test: regression, web, load, custom, manual
    • Build & test servers
  • Interfaces for Design By Contract
    • define precise verifiable interface specifications for software components
    • In VS, can generate classes from Interfaces, then automatically construct class diagram
    • Each interface method should map to a task
    • The interfaces force the developer to implement all tasks
  • Interface Code Contracts
    • See previous post!
    • Applies Preconditions and Postconditions -
using System.Diagnostics.Contracts;
[ContractClass(typeof(IFooContract ))]
interface IFoo
int Count { get; }
void Put(int value );
sealed class IFooContract : IFoo
int Count
CodeContract.Ensures( 0 <= CodeContract.Result<int>() );
return CodeContract.Result<int>(); // dummy return
void Put(int value)
CodeContract.Requires( 0 <= value );
  • Ensure code standards in [relevant] rules are met – checks: Correctness, Library design , Localization , Naming conventions , Performance , Security
  • Analyzes the compiled code for conformance to Microsoft's .NET Framework Design Guidelines.
·         One of the easiest “code smells” to deodorise is that of "duplicate code" - Simian is a Similarity Analyser that detects duplications in source code (C#, C, C++ ASP, XML, HTML etc); once detected you can easily locate the duplication and perform an "Extract Method" refactor in Visual Studio.
  • Simian is a command line tool - but you can integrate it into Visual Studio via the extensibility of the External Tools menu. Here is an example of the standard output produced by Simian when run against some source code:
Similarity Analyser 2.2.23 -
Copyright (c) 2003-08 RedHill Consulting Pty. Ltd. All rights reserved.
Simian is not free unless used solely for non-commercial or evaluation purposes.
{failOnDuplication=true, ignoreCharacterCase=true, ignoreCurlyBraces=true, ignoreIdentifierCase=true, ignoreModifiers=true, ignoreStringCase=true, threshold=6}
Found 6 duplicate lines in the following files:
 Between lines 201 and 207 in /Users/haruki_zaemon/Projects/redhill/simian/build/dist/src/java/awt/image/
 Between lines 1305 and 1311 in /Users/haruki_zaemon/Projects/redhill/simian/build/dist/src/java/awt/image/
Found 6 duplicate lines in the following files:
 Between lines 920 and 926 in /Users/haruki_zaemon/Projects/redhill/simian/build/dist/src/com/sun/imageio/plugins/jpeg/
 Between lines 908 and 914 in /Users/haruki_zaemon/Projects/redhill/simian/build/dist/src/com/sun/imageio/plugins/jpeg/
  • enforce a common set of best practices for layout, readability, maintainability, and documentation of C# source code.
  • produce elegant, consistent code that your team members and others who view your code will find highly readable.
  • Ensure that all methods work – that changes to code don’t break other methods
  • Generate a Test project – each [Task mapped] method should have a postcondition test
  • Regression test – attach the util to the DLL
  • Automatically generate unit tests using Pex:
Enterprise Library and Policy Injection
  • Improved Productivity (satisfy common application concerns out of the box) , Configuration Driven Design
  • EntLib application blocks - Caching , Data Access (redundant), Cryptography , Exception Handling , Logging , Security , Validation
  • Policy Injection – Aspect oriented programming - separate?cross-cutting logic from domain-specific logic. Inversion of Control - instead of the programmer specifying cross-cutting functionality via function calls, instead register desired responses to particular policy rule defined events.
  • Eg for a function - inject validation, tracing , exception handling , Authorization, caching, update performance counters. Using the PIAB, such functionality would be introduced through the creation of policies that define the implementation details needed at run time. Policies can be applied to objects through configuration or by decorating classes with attributes. Each policy has a set of matching rules to determine where it should be applied, and a collection of handlers that determine which behaviors should be introduced when invoking methods on the object. The PIAB comes with a number of useful handlers for validation, logging, exception handling, managing performance counters, authorization, and caching. Many of these handlers leverage EntLibs other application blocks. PIAB supports matching rules based on types, assemblies, member names, method signatures, namespaces, parameter types, property types, return types, custom attributes, tags

Posted on Saturday, November 22, 2008 8:32 AM TFS ALM | Back to top

Related Posts on Geeks With Blogs Matching Categories

Comments on this post: Dev Team Management best practices

# re: Dev Team Management best practices
Requesting Gravatar...
Your post is truly filled with valuable info and was a pleasure going through it ... But to get back to the beginning of your post when you wrote about the GOALS...first thing that came to mind was..this man is dead on...but right after that I just realized that a lot of the things you mentioned are easier to do in theory and very hard to do in practice..(I am still talking about the goals)....
Left by neongreen on Nov 26, 2008 4:41 PM

# re: Dev Team Management best practices
Requesting Gravatar...
Many thanks for that tutorial.
Left by rowery dzieciece on Sep 16, 2010 5:50 AM

# re: Dev Team Management best practices
Requesting Gravatar...
This tutorial is really significant to learn now. - Antiquities of California
Left by Lira Sale on Dec 22, 2016 4:33 PM

Your comment:
 (will show your gravatar)

Copyright © JoshReuben | Powered by: