Skip to content

Commit

Permalink
Update rdd pipe tests for checkCode
Browse files Browse the repository at this point in the history
(rather than mode)
  • Loading branch information
megatron-me-uk committed Jul 7, 2015
1 parent eb4801c commit ab9a2e1
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions python/pyspark/tests.py
Original file line number Diff line number Diff line change
Expand Up @@ -879,13 +879,12 @@ def test_pipe_functions(self):
rdd = self.sc.parallelize(data)
with QuietTest(self.sc):
self.assertEqual([], rdd.pipe('cc').collect())
self.assertRaises(Py4JJavaError, rdd.pipe('cc', mode='strict').collect)
self.assertRaises(Py4JJavaError, rdd.pipe('cc', checkCode=True).collect)
result = rdd.pipe('cat').collect()
result.sort()
[self.assertEqual(x, y) for x, y in zip(data, result)]
self.assertRaises(Py4JJavaError, rdd.pipe('grep 4', mode='strict').collect)
self.assertRaises(Py4JJavaError, rdd.pipe('grep 4', checkCode=True).collect)
self.assertEqual([], rdd.pipe('grep 4').collect())
self.assertEqual([], rdd.pipe('grep 4', mode='grep').collect())


class ProfilerTests(PySparkTestCase):
Expand Down

0 comments on commit ab9a2e1

Please sign in to comment.