title: Range in assert
body: <p>Here is my code,</p>
  <pre><code>def sample(self, f):
          g = f(1000)
          check = np.all(g &gt;= 0.0) and np.all(g &lt; 1.0)
          assert_equal(check, True)
  </code></pre>
  <p>I was attempting an assertion equivalent to the above something like</p>
  <pre><code> def test_random_vector_1(self, f):
          v = f(1000)
          self.assertTrue(0.0&lt;= v &lt;1.0)
        
  </code></pre>
  <p>However, I get an error that says assertTrue is not an attribute.
  Is there an alternative to make the code shorter?</p>