From b140d8259b115d04f228e5dd4f6c05f20c3e3562 Mon Sep 17 00:00:00 2001 From: del-zhenwu <56623710+del-zhenwu@users.noreply.github.com> Date: Thu, 26 Dec 2019 14:19:52 +0800 Subject: [PATCH] Update pip source (#822) * Update pip source * Update requirements * Remove query range case --- ci/jenkins/step/singleDevNightlyTest.groovy | 2 +- ci/jenkins/step/singleDevTest.groovy | 2 +- tests/milvus_python_test/requirements.txt | 15 --------------- tests/milvus_python_test/test_search_vectors.py | 16 ++++++++++------ 4 files changed, 12 insertions(+), 23 deletions(-) diff --git a/ci/jenkins/step/singleDevNightlyTest.groovy b/ci/jenkins/step/singleDevNightlyTest.groovy index 74a8768cba..823cc25660 100644 --- a/ci/jenkins/step/singleDevNightlyTest.groovy +++ b/ci/jenkins/step/singleDevNightlyTest.groovy @@ -1,6 +1,6 @@ timeout(time: 90, unit: 'MINUTES') { dir ("tests/milvus_python_test") { - sh 'python3 -m pip install -r requirements.txt' + sh 'python3 -m pip install -r requirements.txt -i http://pypi.douban.com/simple --trusted-host pypi.douban.com' sh "pytest . --alluredir=\"test_out/dev/single/sqlite\" --ip ${env.HELM_RELEASE_NAME}-engine.milvus.svc.cluster.local" } // mysql database backend test diff --git a/ci/jenkins/step/singleDevTest.groovy b/ci/jenkins/step/singleDevTest.groovy index 291b4470e5..0ad9e369bf 100644 --- a/ci/jenkins/step/singleDevTest.groovy +++ b/ci/jenkins/step/singleDevTest.groovy @@ -1,6 +1,6 @@ timeout(time: 60, unit: 'MINUTES') { dir ("tests/milvus_python_test") { - sh 'python3 -m pip install -r requirements.txt' + sh 'python3 -m pip install -r requirements.txt -i http://pypi.douban.com/simple --trusted-host pypi.douban.com' sh "pytest . --alluredir=\"test_out/dev/single/sqlite\" --level=1 --ip ${env.HELM_RELEASE_NAME}-engine.milvus.svc.cluster.local" } diff --git a/tests/milvus_python_test/requirements.txt b/tests/milvus_python_test/requirements.txt index 016c8dedfc..df3191ccd6 100644 --- a/tests/milvus_python_test/requirements.txt +++ b/tests/milvus_python_test/requirements.txt @@ -1,14 +1,4 @@ -astroid==2.2.5 -atomicwrites==1.3.0 -attrs==19.1.0 -importlib-metadata==0.15 -isort==4.3.20 -lazy-object-proxy==1.4.1 -mccabe==0.6.1 -more-itertools==7.0.0 numpy==1.16.3 -pluggy==0.12.0 -py==1.8.0 pylint==2.3.1 pytest==4.5.0 pytest-timeout==1.3.3 @@ -16,10 +6,5 @@ pytest-repeat==0.8.0 allure-pytest==2.7.0 pytest-print==0.1.2 pytest-level==0.1.1 -six==1.12.0 -typed-ast==1.3.5 -wcwidth==0.1.7 -wrapt==1.11.1 -zipp==0.5.1 scikit-learn>=0.19.1 pymilvus-test>=0.2.0 diff --git a/tests/milvus_python_test/test_search_vectors.py b/tests/milvus_python_test/test_search_vectors.py index 464a28efea..76bc81b384 100644 --- a/tests/milvus_python_test/test_search_vectors.py +++ b/tests/milvus_python_test/test_search_vectors.py @@ -449,7 +449,8 @@ class TestSearchBase: def get_invalid_range(self, request): yield request.param - def test_search_invalid_query_ranges(self, connect, table, get_invalid_range): + # disable + def _test_search_invalid_query_ranges(self, connect, table, get_invalid_range): ''' target: search table with query ranges method: search with the same query ranges @@ -477,7 +478,8 @@ class TestSearchBase: def get_valid_range_no_result(self, request): yield request.param - def test_search_valid_query_ranges_no_result(self, connect, table, get_valid_range_no_result): + # disable + def _test_search_valid_query_ranges_no_result(self, connect, table, get_valid_range_no_result): ''' target: search table with normal query ranges, but no data in db method: search with query ranges (low, low) @@ -505,7 +507,8 @@ class TestSearchBase: def get_valid_range(self, request): yield request.param - def test_search_valid_query_ranges(self, connect, table, get_valid_range): + # disable + def _test_search_valid_query_ranges(self, connect, table, get_valid_range): ''' target: search table with normal query ranges, but no data in db method: search with query ranges (low, normal) @@ -878,8 +881,9 @@ class TestSearchParamsInvalid(object): def get_query_ranges(self, request): yield request.param + # disable @pytest.mark.level(1) - def test_search_flat_with_invalid_query_range(self, connect, table, get_query_ranges): + def _test_search_flat_with_invalid_query_range(self, connect, table, get_query_ranges): ''' target: test search fuction, with the wrong query_range method: search with query_range @@ -893,9 +897,9 @@ class TestSearchParamsInvalid(object): with pytest.raises(Exception) as e: status, result = connect.search_vectors(table, 1, nprobe, query_vecs, query_ranges=query_ranges) - + # disable @pytest.mark.level(2) - def test_search_flat_with_invalid_query_range_ip(self, connect, ip_table, get_query_ranges): + def _test_search_flat_with_invalid_query_range_ip(self, connect, ip_table, get_query_ranges): ''' target: test search fuction, with the wrong query_range method: search with query_range