Commit f54dd17
committed
[SPARK-37252][PYTHON][TESTS] Ignore
### What changes were proposed in this pull request?
This PR aims to ignore `test_memory_limit` on non-Linux environment.
### Why are the changes needed?
Like the documentation apache#23664, it fails on non-Linux environment like the following MacOS example.
**BEFORE**
```
$ build/sbt -Phadoop-cloud -Phadoop-3.2 test:package
$ python/run-tests --modules pyspark-core
...
======================================================================
FAIL: test_memory_limit (pyspark.tests.test_worker.WorkerMemoryTest)
----------------------------------------------------------------------
Traceback (most recent call last):
File "/Users/dongjoon/APACHE/spark-merge/python/pyspark/tests/test_worker.py", line 212, in test_memory_limit
self.assertEqual(soft_limit, 2 * 1024 * 1024 * 1024)
AssertionError: 9223372036854775807 != 2147483648
----------------------------------------------------------------------
```
**AFTER**
```
...
Tests passed in 104 seconds
Skipped tests in pyspark.tests.test_serializers with /Users/dongjoon/.pyenv/versions/3.8.12/bin/python3:
test_serialize (pyspark.tests.test_serializers.SciPyTests) ... skipped 'SciPy not installed'
Skipped tests in pyspark.tests.test_worker with /Users/dongjoon/.pyenv/versions/3.8.12/bin/python3:
test_memory_limit (pyspark.tests.test_worker.WorkerMemoryTest) ... skipped "Memory limit feature in Python worker is dependent on Python's 'resource' module on Linux; however, not found or not on Linux."
```
### Does this PR introduce _any_ user-facing change?
No
### How was this patch tested?
Manual.
Closes apache#34527 from dongjoon-hyun/SPARK-37252.
Authored-by: Dongjoon Hyun <[email protected]>
Signed-off-by: Dongjoon Hyun <[email protected]>
(cherry picked from commit 2c7f201)
Signed-off-by: Dongjoon Hyun <[email protected]>test_memory_limit on non-Linux environment1 parent 6eff896 commit f54dd17
1 file changed
+3
-2
lines changed| Original file line number | Diff line number | Diff line change | |
|---|---|---|---|
| |||
16 | 16 | | |
17 | 17 | | |
18 | 18 | | |
| 19 | + | |
19 | 20 | | |
20 | 21 | | |
21 | 22 | | |
| |||
188 | 189 | | |
189 | 190 | | |
190 | 191 | | |
191 | | - | |
| 192 | + | |
192 | 193 | | |
193 | | - | |
| 194 | + | |
194 | 195 | | |
195 | 196 | | |
196 | 197 | | |
| |||
0 commit comments