title: Unit testing of a class using nose
body: <p>Define a nose test class 'TestingCircleCreation' which tests the behavior of '<strong>init</strong>' method with below specified four tests.</p>
  
  <ol>
  <li><p>Define a nose test method 'test_creating_circle_with_numeric_radius', which creates a circle with radius 2.5 and check if it's radius matches to value 2.5</p></li>
  <li><p>Define a nose test method 'test_creating_circle_with_negative_radius', which checks if ValueError exception is raised with the error message "radius must be between 0 and 1000 inclusive", while creating circle of radius -2.5 . </p></li>
  </ol>
  
  <p>3.Define a nose test method 'test_creating_circle_with_greaterthan_radius', which checks if ValueError exception is raised with the error message "radius must be between 0 and 1000 inclusive" , while creating circle of radius 1000.1</p>
  
  <ol start="4">
  <li>Define a nose test method 'test_creating_circle_with_nonnumeric_radius', which checks if TypeError exception is raised with the error message "radius must be a number", while creating circle of radius 'hello' . </li>
  </ol>
  
  <p>i am not getting the expected output.
  Please suggest</p>
  
  <p>Code used:</p>
  
  <p>class TestCircleCreation(unittest.TestCase):</p>
  
  <pre><code>def test_creating_circle_with_numeric_radius(self):
  
      c1=Circle(2.5)
      self.assert_equal(c1.radius,2.5)
  
  
  def test_creating_circle_with_negative_radius(self):
  
      c1=Circle(2.5)
      self.assert_equal(c1.radius,2.5)
      self.assert_raises(ValueError, Circle, -2.5)
  
  
  def test_creating_circle_with_greaterthan_radius(self):
  
      c1=Circle(2.5)
      self.assert_equal(c1.radius,2.5) 
      self.assert_raises(ValueError, Circle, 1000.1)     
  
  
  def test_creating_circle_with_nonnumeric_radius(self):
  
      c1=Circle(2.5)
      self.assert_equal(c1.radius,2.5)
      self.assert_raises(TypeError, Circle, 'hello') 
  </code></pre>