mirror of
https://github.com/wassname/ray.git
synced 2026-07-27 11:26:41 +08:00
Fix text verbosity in python 2.7 by running tests with pytest (#2470)
This commit is contained in:
committed by
Robert Nishihara
parent
fe65f9fbbc
commit
696a229ece
@@ -18,9 +18,10 @@ def factorial(n):
|
||||
return n * ray.get(factorial.remote(n - 1))
|
||||
|
||||
|
||||
assert ray.get(factorial.remote(0)) == 1
|
||||
assert ray.get(factorial.remote(1)) == 1
|
||||
assert ray.get(factorial.remote(2)) == 2
|
||||
assert ray.get(factorial.remote(3)) == 6
|
||||
assert ray.get(factorial.remote(4)) == 24
|
||||
assert ray.get(factorial.remote(5)) == 120
|
||||
def test_recursion():
|
||||
assert ray.get(factorial.remote(0)) == 1
|
||||
assert ray.get(factorial.remote(1)) == 1
|
||||
assert ray.get(factorial.remote(2)) == 2
|
||||
assert ray.get(factorial.remote(3)) == 6
|
||||
assert ray.get(factorial.remote(4)) == 24
|
||||
assert ray.get(factorial.remote(5)) == 120
|
||||
|
||||
Reference in New Issue
Block a user