From d45418936c3b9df42447eec739fac4d0bd1bfba2 Mon Sep 17 00:00:00 2001 From: Robert Nishihara Date: Mon, 17 Aug 2020 18:56:17 -0700 Subject: [PATCH] Skip failing tests on Windows. (#10139) --- python/ray/tests/test_actor_resources.py | 1 + python/ray/tests/test_autoscaler_yaml.py | 8 +++++--- python/ray/tests/test_global_state.py | 2 +- python/ray/tests/test_output.py | 1 + python/ray/tests/test_typing.py | 2 ++ 5 files changed, 10 insertions(+), 4 deletions(-) diff --git a/python/ray/tests/test_actor_resources.py b/python/ray/tests/test_actor_resources.py index 37c1dcb01..82f4a9c98 100644 --- a/python/ray/tests/test_actor_resources.py +++ b/python/ray/tests/test_actor_resources.py @@ -83,6 +83,7 @@ def test_actor_class_methods(ray_start_regular): @pytest.mark.skipif( os.environ.get("RAY_USE_NEW_GCS") == "on", reason="Failing with new GCS API on Linux.") +@pytest.mark.skipif(sys.platform == "win32", reason="Failing on Windows.") def test_actor_gpus(ray_start_cluster): cluster = ray_start_cluster num_nodes = 3 diff --git a/python/ray/tests/test_autoscaler_yaml.py b/python/ray/tests/test_autoscaler_yaml.py index 6c8b76e90..b768ea531 100644 --- a/python/ray/tests/test_autoscaler_yaml.py +++ b/python/ray/tests/test_autoscaler_yaml.py @@ -1,9 +1,10 @@ import jsonschema import os -import unittest -import yaml -import urllib +import sys import tempfile +import unittest +import urllib +import yaml from ray.autoscaler.util import prepare_config, validate_config from ray.test_utils import recursive_fnmatch @@ -51,6 +52,7 @@ class AutoscalingConfigTest(unittest.TestCase): except jsonschema.ValidationError: pass + @unittest.skipIf(sys.platform == "win32", "Failing on Windows.") def testInvalidConfig(self): self._test_invalid_config( os.path.join("tests", "additional_property.yaml")) diff --git a/python/ray/tests/test_global_state.py b/python/ray/tests/test_global_state.py index 06152cca9..9cc5e623f 100644 --- a/python/ray/tests/test_global_state.py +++ b/python/ray/tests/test_global_state.py @@ -59,7 +59,7 @@ def test_uses_resources(ray_start_regular): @pytest.mark.skipif( pytest_timeout is None, reason="Timeout package not installed; skipping test that may hang.") -@pytest.mark.timeout(20) +@pytest.mark.timeout(120) def test_add_remove_cluster_resources(ray_start_cluster_head): """Tests that Global State API is consistent with actual cluster.""" cluster = ray_start_cluster_head diff --git a/python/ray/tests/test_output.py b/python/ray/tests/test_output.py index 04ef2126a..bac20e624 100644 --- a/python/ray/tests/test_output.py +++ b/python/ray/tests/test_output.py @@ -7,6 +7,7 @@ import ray from ray.test_utils import run_string_as_driver_nonblocking +@pytest.mark.skipif(sys.platform == "win32", reason="Failing on Windows.") def test_worker_stdout(): script = """ import ray diff --git a/python/ray/tests/test_typing.py b/python/ray/tests/test_typing.py index 512a53cea..de7a163c5 100644 --- a/python/ray/tests/test_typing.py +++ b/python/ray/tests/test_typing.py @@ -7,12 +7,14 @@ import pytest TYPING_TEST_DIRS = os.path.join(os.path.dirname(__file__), "typing_files") +@pytest.mark.skipif(sys.platform == "win32", reason="Failing on Windows.") def test_typing_good(): script = os.path.join(TYPING_TEST_DIRS, "check_typing_good.py") msg, _, status_code = mypy_api.run([script]) assert status_code == 0, msg +@pytest.mark.skipif(sys.platform == "win32", reason="Failing on Windows.") def test_typing_bad(): script = os.path.join(TYPING_TEST_DIRS, "check_typing_bad.py") msg, _, status_code = mypy_api.run([script])