Skip to content

Commit f60dd3b

Browse files
authored
change: Enable galactus integ tests (#4376)
* feat: Enable galactus integ tests * fix flake8 * fix doc8 * trying to see if it works with slow tests * small fixes in import error * fix missing import * try to remove some dependencies from requirement to see if pr test can be fixed * fix flake8 * Enable more tests * Add rerun annotation and further remove dependencies * comment out 2 integ tests * Remove local mode test for now * fix flake8
1 parent 2a6e479 commit f60dd3b

File tree

3 files changed

+206
-171
lines changed

3 files changed

+206
-171
lines changed

tests/integ/sagemaker/serve/constants.py

+13-14
Original file line numberDiff line numberDiff line change
@@ -12,24 +12,23 @@
1212
# language governing permissions and limitations under the License.
1313
from __future__ import absolute_import
1414

15-
# import os
15+
import os
1616
import platform
1717

18-
# from tests.integ import DATA_DIR
18+
from tests.integ import DATA_DIR
1919

20-
# SERVE_IN_PROCESS_TIMEOUT = 5
21-
# SERVE_MODEL_PACKAGE_TIMEOUT = 10
22-
# SERVE_LOCAL_CONTAINER_TIMEOUT = 10
20+
SERVE_IN_PROCESS_TIMEOUT = 5
21+
SERVE_MODEL_PACKAGE_TIMEOUT = 10
22+
SERVE_LOCAL_CONTAINER_TIMEOUT = 10
2323
SERVE_SAGEMAKER_ENDPOINT_TIMEOUT = 15
24-
# SERVE_SAVE_TIMEOUT = 2
24+
SERVE_SAVE_TIMEOUT = 2
2525

26-
# NOT_RUNNING_ON_PY38 = platform.python_version_tuple()[1] != "8"
27-
NOT_RUNNING_ON_PY310 = platform.python_version_tuple()[1] != "10"
28-
# NOT_RUNNING_ON_INF_EXP_DEV_PIPELINE = os.getenv("TEST_OWNER") != "INF_EXP_DEV"
26+
PYTHON_VERSION_IS_NOT_38 = platform.python_version_tuple()[1] != "8"
27+
PYTHON_VERSION_IS_NOT_310 = platform.python_version_tuple()[1] != "10"
2928

30-
# XGB_RESOURCE_DIR = os.path.join(DATA_DIR, "serve_resources", "xgboost")
31-
# PYTORCH_SQUEEZENET_RESOURCE_DIR = os.path.join(DATA_DIR, "serve_resources", "pytorch")
32-
# TF_EFFICIENT_RESOURCE_DIR = os.path.join(DATA_DIR, "serve_resources", "tensorflow")
33-
# HF_DIR = os.path.join(DATA_DIR, "serve_resources", "hf")
29+
XGB_RESOURCE_DIR = os.path.join(DATA_DIR, "serve_resources", "xgboost")
30+
PYTORCH_SQUEEZENET_RESOURCE_DIR = os.path.join(DATA_DIR, "serve_resources", "pytorch")
31+
TF_EFFICIENT_RESOURCE_DIR = os.path.join(DATA_DIR, "serve_resources", "tensorflow")
32+
HF_DIR = os.path.join(DATA_DIR, "serve_resources", "hf")
3433

35-
# BYOC_IMAGE_URI_TEMPLATE = "661407751302.dkr.ecr.{}.amazonaws.com/byoc-integ-test-images:{}"
34+
BYOC_IMAGE_URI_TEMPLATE = "661407751302.dkr.ecr.{}.amazonaws.com/byoc-integ-test-images:{}"

tests/integ/sagemaker/serve/test_serve_js_happy.py

+3-2
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
from sagemaker.serve.builder.schema_builder import SchemaBuilder
1818
from tests.integ.sagemaker.serve.constants import (
1919
SERVE_SAGEMAKER_ENDPOINT_TIMEOUT,
20-
NOT_RUNNING_ON_PY310,
20+
PYTHON_VERSION_IS_NOT_310,
2121
)
2222

2323
from tests.integ.timeout import timeout
@@ -47,9 +47,10 @@ def happy_model_builder(sagemaker_session):
4747

4848

4949
@pytest.mark.skipif(
50-
NOT_RUNNING_ON_PY310,
50+
PYTHON_VERSION_IS_NOT_310,
5151
reason="The goal of these test are to test the serving components of our feature",
5252
)
53+
@pytest.mark.slow_test
5354
def test_happy_tgi_sagemaker_endpoint(happy_model_builder, gpu_instance_type):
5455
logger.info("Running in SAGEMAKER_ENDPOINT mode...")
5556
caught_ex = None

0 commit comments

Comments
 (0)