From b57db1579e0759bc53dff8228eb35c303f2d69c1 Mon Sep 17 00:00:00 2001 From: Erik Bernhardsson Date: Mon, 25 May 2015 19:08:00 -0400 Subject: [PATCH] run GloVe f=25 as a part of the test suite --- setup.cfg | 4 ++++ test/{_accuracy_test.py => accuracy_test.py} | 7 +++++++ 2 files changed, 11 insertions(+) create mode 100644 setup.cfg rename test/{_accuracy_test.py => accuracy_test.py} (95%) diff --git a/setup.cfg b/setup.cfg new file mode 100644 index 0000000..8bbe8b7 --- /dev/null +++ b/setup.cfg @@ -0,0 +1,4 @@ +[nosetests] +attr=!slow +nocapture=1 + diff --git a/test/_accuracy_test.py b/test/accuracy_test.py similarity index 95% rename from test/_accuracy_test.py rename to test/accuracy_test.py index dcae9a6..649efaf 100644 --- a/test/_accuracy_test.py +++ b/test/accuracy_test.py @@ -18,6 +18,7 @@ import os from annoy import AnnoyIndex import urllib import gzip +from nose.plugins.attrib import attr class AccuracyTest(unittest.TestCase): def _get_index(self, f, distance): @@ -67,20 +68,26 @@ class AccuracyTest(unittest.TestCase): def test_euclidean_25(self): self._test_index(25, 'euclidean', 47.34) + @attr('slow') def test_angular_50(self): self._test_index(50, 'angular', 31.00) + @attr('slow') def test_euclidean_50(self): self._test_index(50, 'euclidean', 33.04) + @attr('slow') def test_angular_100(self): self._test_index(100, 'angular', 24.50) + @attr('slow') def test_euclidean_100(self): self._test_index(100, 'euclidean', 25.10) + @attr('slow') def test_angular_200(self): self._test_index(200, 'angular', 15.18) + @attr('slow') def test_euclidean_200(self): self._test_index(200, 'euclidean', 17.99)