From 0df6e9e74771bc4ed536a2439749efb1bf7828ba Mon Sep 17 00:00:00 2001 From: Paul Brossier Date: Wed, 11 May 2016 07:06:08 +0200 Subject: [PATCH] python/tests/test_fvec.py: avoid import --- python/tests/test_fvec.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/python/tests/test_fvec.py b/python/tests/test_fvec.py index c147b1f6..088fe68e 100755 --- a/python/tests/test_fvec.py +++ b/python/tests/test_fvec.py @@ -61,8 +61,7 @@ class aubio_fvec_test_case(TestCase): a[1] = 1 self.assertEqual (alpha_norm(a, 1), 1) a = array([0, 1], dtype=float_type) - from math import sqrt - assert_almost_equal (alpha_norm(a, 2), sqrt(2)/2.) + assert_almost_equal (alpha_norm(a, 2), .5*2.**.5) def test_alpha_norm_of_none(self): self.assertRaises (ValueError, alpha_norm, None, 1) -- 2.11.0