title: Good Practice of Object Initialising IN TDD
body: <p>I just start working on TDD but i just need to know couple of things about object initializing in setup or local method.</p>
  
  <p>Let me explain bit more'.</p>
  
  <p><strong>Case 1:</strong></p>
  
  <pre><code>Public Class TestCase{
   LoginClass obj;
    public void TearUp(){
     obj = LoginClass
    }
  
  public void TearDown(){
  dispose(obj);
  }
  </code></pre>
  
  <p><strong>Case 2:</strong></p>
  
  <pre><code> Public Class TestCase2{
      public void Validate(){
       LoginClass obj = new LoginClass();
     }
       public void ValidateSharepoint(){
       LoginClass obj = new LoginClass();
     }
  
  }
  </code></pre>
  
  <p>So, There are two cases 
  Case 1: Object is initializing setUp method and dispose off TearDown Method. 
  Case 2: Object is initializing locally in methods.</p>
  
  <p>Both are doing same work but both have different cycle. </p>
  
  <p><strong>Which case follows the best practice?</strong>  </p>