PY-12106 Add newline when moving function to new file

Update all the /refactoring/move test sources according to the new rule - an empty line is always added after the move

(cherry picked from commit c00d1a499fb9849650eb102dd8bb5380165a1eee)

IJ-CR-17177

GitOrigin-RevId: d436af21c20ddd08b78886a333e6f98c71bcc19b
This commit is contained in:
Daniil Kalinin
2021-11-16 12:21:46 +03:00
committed by intellij-monorepo-bot
parent ea525fb1fb
commit e7421b36cf
50 changed files with 58 additions and 49 deletions

View File

@@ -1,3 +1,3 @@
class B(object):
def __init__(self):
pass
pass

View File

@@ -15,4 +15,4 @@ class C(object):
return o.urlopen()
def g(self, x):
return 'f({0!r}) = {1!r}'.format(URLOpener(x), lib1.URLOpener(x))
return 'f({0!r}) = {1!r}'.format(URLOpener(x), lib1.URLOpener(x))

View File

@@ -6,4 +6,4 @@ class C1:
class C2:
print(B)
print(B)

View File

@@ -12,4 +12,4 @@ class C(object):
:type self: :class:`C`
:type other: :py:class:`b.C`
'''
return super(self, C).__eq__(other)
return super(self, C).__eq__(other)

View File

@@ -1,2 +1,2 @@
def func():
pass
pass

View File

@@ -1,2 +1,2 @@
def func():
pass
pass

View File

@@ -1,2 +1,2 @@
def func():
pass
pass

View File

@@ -3,4 +3,4 @@ from __future__ import print_function
class C:
pass
pass

View File

@@ -2,4 +2,4 @@ from __future__ import unicode_literals, annotations
class C:
pass
pass

View File

@@ -3,4 +3,4 @@ from lib import function1 as f1, function2 as f2
def func():
print(f1(), f2())
return f2()
return f2()

View File

@@ -9,4 +9,4 @@ def f(url):
'''Return the representation available at the URL.
'''
return urlopen(url).read()
return urlopen(url).read()

View File

@@ -1 +1 @@
VAR = 42
VAR = 42

View File

@@ -2,4 +2,4 @@ import lib1 as iks
def f(x):
return iks.I(x)
return iks.I(x)

View File

@@ -2,4 +2,4 @@ __author__ = 'catherine'
def function_1():
pass
pass

View File

@@ -2,4 +2,4 @@ __author__ = 'catherine'
def function_2():
pass
pass

View File

@@ -3,4 +3,4 @@ from lib1 import S, K
def f(x):
from lib1 import I
return S(K(I))(I)(42)
return S(K(I))(I)(42)

View File

@@ -7,4 +7,4 @@ def f():
class A:
def m(self):
f()
f()

View File

@@ -6,4 +6,4 @@ print(baz, quux)
def func():
print(foo, bar)
print(foo, bar)

View File

@@ -1,2 +1,2 @@
def func(n):
return func(n - 1) if n > 0 else True
return func(n - 1) if n > 0 else True

View File

@@ -2,4 +2,4 @@ import b
def func():
print(b)
print(b)

View File

@@ -3,4 +3,4 @@ def func():
class C:
pass
pass

View File

@@ -1,2 +1,2 @@
def func(n):
return func(n - 1) if n > 0 else True
return func(n - 1) if n > 0 else True

View File

@@ -2,4 +2,4 @@ import nspkg
def func():
print(nspkg)
print(nspkg)

View File

@@ -2,4 +2,4 @@ def f(url):
'''Return the representation available at the URL.
'''
return open(url).read()
return open(url).read()

View File

@@ -3,4 +3,4 @@ class Class1:
class Class2:
pass
pass

View File

@@ -2,4 +2,4 @@ import lib1.mod1
def f(x):
return lib1.mod1.k(x)(42)
return lib1.mod1.k(x)(42)

View File

@@ -1,2 +1,2 @@
def f(x):
return x
return x

View File

@@ -9,4 +9,4 @@ def some_other_fn():
print(a.something_else)
FOO = 1
FOO = 1

View File

@@ -2,4 +2,4 @@ from classFile import Pipeline
def fnToMove():
return Pipeline('name')
return Pipeline('name')

View File

@@ -7,4 +7,4 @@ print(Class1())
def func():
print(Class2())
print(Class2())

View File

@@ -2,4 +2,4 @@ from b import f
def g():
return f()
return f()

View File

@@ -1,2 +1,2 @@
def f():
pass
pass

View File

@@ -2,4 +2,4 @@ from p1 import m1
def f():
m1.g()
m1.g()

View File

@@ -1,3 +1,3 @@
from a import X, func, C
Y = X * func() + C().m()
Y = X * func() + C().m()

View File

@@ -6,4 +6,4 @@ def another():
def func():
return b
return b

View File

@@ -2,4 +2,4 @@ from a import f
def use_f():
f()
f()

View File

@@ -2,4 +2,4 @@ from b import foo
def use_foo():
print(foo)
print(foo)

View File

@@ -2,4 +2,4 @@ from b import foo as bar
def use_foo():
print(bar)
print(bar)

View File

@@ -9,4 +9,4 @@ def test():
b: 'aio.Condition' = aio.Condition()
c: 'datetime.timedelta' = datetime.timedelta(0)
d: 'ODict' = ODict()
S: TypeAlias = 'Set'
S: TypeAlias = 'Set'

View File

@@ -6,4 +6,4 @@ from typing import Text
def test(s, cond, td):
# type: (Text, aio.Condition, datetime.timedelta) -> ODict
return ODict()
return ODict()

View File

@@ -8,4 +8,4 @@ def test():
a = "a" # type: Text
b = aio.Condition() # type: aio.Condition
c = datetime.timedelta(0) # type: datetime.timedelta
d = ODict() # type: ODict
d = ODict() # type: ODict