Skip to content

Commit

Permalink
Unskipped tests in test_actor.py (ray-project#21501)
Browse files Browse the repository at this point in the history
  • Loading branch information
czgdp1807 authored Jan 14, 2022
1 parent 7517aef commit f8bcb8a
Showing 1 changed file with 6 additions and 4 deletions.
10 changes: 6 additions & 4 deletions python/ray/tests/test_actor.py
Original file line number Diff line number Diff line change
Expand Up @@ -735,7 +735,6 @@ def f(self, y):
t.f(1)


@pytest.mark.skipif(sys.platform == "win32", reason="Failing on Windows.")
def test_actor_deletion(ray_start_regular_shared):
# Make sure that when an actor handles goes out of scope, the actor
# destructor is called.
Expand Down Expand Up @@ -1007,7 +1006,6 @@ def get_value(self):
actor_create_time - start, end - start))


@pytest.mark.skipif(sys.platform == "win32", reason="Failing on Windows.")
@pytest.mark.parametrize(
"exit_condition",
[
Expand Down Expand Up @@ -1036,7 +1034,9 @@ def exit(self):
ray.actor.exit_actor()

data = "hello"
tmpfile = tempfile.NamedTemporaryFile()
tmpfile = tempfile.NamedTemporaryFile("w+", suffix=".tmp", delete=False)
tmpfile.close()

a = A.remote(tmpfile.name, data)
ray.get(a.ready.remote())

Expand All @@ -1052,7 +1052,7 @@ def exit(self):
assert False, "Unrecognized condition"

def check_file_written():
with open(tmpfile.name) as f:
with open(tmpfile.name, "r") as f:
if f.read() == data:
return True
return False
Expand All @@ -1063,6 +1063,8 @@ def check_file_written():
else:
wait_for_condition(check_file_written)

os.unlink(tmpfile.name)


def test_return_actor_handle_from_actor(ray_start_regular_shared):
@ray.remote
Expand Down

0 comments on commit f8bcb8a

Please sign in to comment.