Test Driven Development (TDD), and Refactoring Legacy Code Using C# (Canada) Training Class Presented by Hands-On Technology Transfer

0
67
Loading ....


presented by Hands-On Technology Transfer
View the Hands-On Technology Transfer Profile and Course Listings

Summary

This course provides students with hands on experience learning Test Driven Development (TDD) using NUnit and Microsofts Visual Studio. Students will build unit tests using mocks, fakes, stubs and drivers, and address issues working with databases and other systems.

Workshop Description/Agenda

This course provides students with hands on experience learning Test Driven Development (TDD) using NUnit and Microsoft’s Visual Studio. Students will build unit tests using mocks, fakes, stubs and drivers, and address issues working with databases and other systems. Student will create tests and code that will be more likely to meet and exceed requirements. Code that receives test coverage will not break existing systems, because tests are passed before code is checked in.

Students will spend time working with the issue involved in refactoring legacy code, or cutting into a living, breathing, system, safely. Students will work on looking for, or creating seams to more safely improve code or add features, and work on identifying code smells that need attention in a productive system.

Finally, students will explore dependency issues as well as techniques to better understand and improve complex systems.

Students will also examine TDD and refactoring legacy code in other languages like Java to gain a broader view of options and issues working in a multi-language shop. Comprehensive labs using C# provide facilitated hands on practice crucial to developing competence and confidence with the new skills being learned.

Course Prerequisites: C# programming experience and an understanding of object-oriented design principles.









Why Test? Think Twice, Write


Production Code Once

  • Safety Net of Automated Testing
  • Agile Development Concepts
  • Fewer Bugs, Less Stress
  • Smoother Production Rollouts

  • Write with Tests, as Fast or Faster
  • Make Changes More Safely
  • “Don’t Break the System”
Unit Testing

  • NUnit and Visual Studio
  • Start off Simple and Add More Tests
  • Making Tests Easy to Run
  • Red, Green Refactor
  • Assertion Methods
  • NUnit Cleanup Methods

  • Boundary Testing
  • Know Unit Test Limitations
Mocks, Fakes, Stubs and Drivers

  • TDD Development Patterns
  • Naming Conventions for Better Code
  • Mock Objects
  • Fakes
  • Stubs
  • Test Doubles

  • Self-Shunt Pattern
Database Unit Testing

  • Database Mocks and ADO.NET
  • Writing Database Tests
  • Setting Up Database Tests

  • Tearing Down Database Tests
  • Black Box Tests
  • White Box Testing
  • Database Sandboxes for Testing
  • ADO.NET Entity Framework Testing Issues
System, Regression and Acceptance Testing

  • Statistical Sampling
  • Usability Testing
  • Test Protocols

  • Regression Testing
  • Acceptance Testing
Patterns and Anti-Patterns in TDD

  • Factory Methods
  • Web GUI Testing

  • Coding to Interface References
  • Checking Parameters for Validity Test
  • Open/Closed Principle, Open to Extension, Closed to Change
  • Break Out Method/Object
  • Extract and Override Call
  • Extract and Override Factory Method

Continuous Integration Servers/Automated Testing

  • Early Warning of Conflicts
  • Metrics and Tools

  • Checking into Repository
    • Team Foundation Server (TFS)
    • Subversion
  • Continuous Integration Servers
  • Automate the Build/Deployment
Risks Changing Legacy/Production Systems

  • Refactoring
  • Coupling and Cohesion Issues
  • Taking Small Tested Steps
  • Anti-Pattern: Big Bang, Boom
Refactoring

  • Refactoring Existing Code
  • Restructuring
  • Improving Clarity and Maintainability
  • Fixing Broken Code

  • Breaking Code into Logical Pieces
  • Value of Testing
  • Pull Up – Push Down – Inheritance
Seam Model: Finding or Creating a Seam for Changes

  • Safely Cutting into a Living System
  • Sprout Method
  • Sprout Class
  • Wrap Class
  • Building Seems for Expansion and Testing

Code Coverage

  • White Box vs Black Box Testing
  • Code Coverage Increasing Over Time

  • Goal 80% or More Test Coverage
  • Statement Coverage
  • Condition Coverage
  • Path Coverage
  • Test Harnesses
  • Unit-Testing Harnesses

Code Smells

  • Recognizing Code Smells
    • Long Method
    • Large Class
    • Duplicate Code

    • Inappropriate Intimacy
    • Feature Envy
    • Excessive Use of Literals, Named Constants or Enums
  • Testing Code Smells
  • Fixing Smelly Code

Dependency Breaking

  • Testing Web Services
  • Making Defensive Copies

  • Using Enums Instead of Constants
  • Dealing with Hidden Dependencies
  • Design and Pinch Point Issues
Large Legacy Systems

  • Notes and Sketching

  • Listing Markup
  • Monster Methods and How to Refactor
  • Preserving Signatures
  • Creating and Using Interfaces

Who Should Attend

Additional Information

Training Provider: Hands-On Technology Transfer

Course Topics: Computers / IT Training >
Programming/Software

Training Course Summary: This course provides students with hands on experience learning Test Driven Development (TDD) using NUnit and Microsofts Visual Studio. Students will build unit tests using mocks, fakes, stubs and drivers, and address issues working with databases and other systems.

 


RELATED PRODUCTS
  • Create your own website and bring your idea to life with the help of software development.
  • Do Real Estate Development Like A Professional in 90 Days
  • Get instant access to this incredible hockey development program
  • Discover how you can create a content marketing strategy that will help you grow business
  • Every Online Marketer Must Answer The Content Question. Niche Content Library Is The Answer
  • No restriction PLR articles pack. 15000 no restriction PLR articles.
  • Designed to Increase Your Psychic Abilities in Just 7 Days
  • Get Erections Back It's worked for thousands, it will work for You.
  • Discover The Fat Loss Accelerators Workout Plans To Get Rid Of Your Ugly Belly Fat
  • Your source for monthly new email content for email marketing.
  • Ads by MyCBGenie 
     
    READ  Business Coaching Certification Training Training Class Presented by Academy of Business Training

    LEAVE A REPLY

    Please enter your comment!
    Please enter your name here