Skip to content

Commit ea66f3d

Browse files
committed
Inserted blank lines for PEP8 compliance
1 parent d81b02b commit ea66f3d

1 file changed

Lines changed: 4 additions & 0 deletions

File tree

python/pyspark/sql/tests.py

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -120,10 +120,12 @@ def test_udf_with_callable(self):
120120
d = [Row(number=i, squared=i**2) for i in range(10)]
121121
rdd = self.sc.parallelize(d)
122122
data = self.sqlCtx.createDataFrame(rdd)
123+
123124
class PlusFour:
124125
def __call__(self, col):
125126
if col is not None:
126127
return col + 4
128+
127129
call = PlusFour()
128130
pudf = UserDefinedFunction(call, LongType())
129131
res = data.select(pudf(data['number']).alias('plus_four'))
@@ -133,9 +135,11 @@ def test_udf_with_partial_function(self):
133135
d = [Row(number=i, squared=i**2) for i in range(10)]
134136
rdd = self.sc.parallelize(d)
135137
data = self.sqlCtx.createDataFrame(rdd)
138+
136139
def some_func(col, param):
137140
if col is not None:
138141
return col + param
142+
139143
pfunc = functools.partial(some_func, param=4)
140144
pudf = UserDefinedFunction(pfunc, LongType())
141145
res = data.select(pudf(data['number']).alias('plus_four'))

0 commit comments

Comments
 (0)