Skip to content

Commit c2107ab

Browse files
authored
Merge pull request #23871 from drodriguez/build-script-rename-build-methods
[build-script] Rename all do_* methods to simply *.
2 parents 1fa7552 + a8297b8 commit c2107ab

File tree

7 files changed

+16
-16
lines changed

7 files changed

+16
-16
lines changed

utils/build-script

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -440,7 +440,7 @@ class BuildScriptInvocation(object):
440440
toolchain=self.toolchain,
441441
source_dir=self.workspace.source_dir("ninja"),
442442
build_dir=self.workspace.build_dir("build", "ninja"))
443-
ninja_build.do_build()
443+
ninja_build.build()
444444
self.toolchain.ninja = ninja_build.ninja_bin_path
445445

446446
def convert_to_impl_arguments(self):
@@ -980,8 +980,8 @@ class BuildScriptInvocation(object):
980980
source_dir=self.workspace.source_dir(product_source),
981981
build_dir=self.workspace.build_dir(
982982
host_target, product_name))
983-
product.do_build(host_target)
984-
product.do_test(host_target)
983+
product.build(host_target)
984+
product.test(host_target)
985985

986986
# Extract symbols...
987987
for host_target in all_hosts:

utils/swift_build_support/swift_build_support/products/benchmarks.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -28,10 +28,10 @@ def product_source_name(cls):
2828
def is_build_script_impl_product(cls):
2929
return False
3030

31-
def do_build(self, host_target):
31+
def build(self, host_target):
3232
run_build_script_helper(host_target, self, self.args)
3333

34-
def do_test(self, host_target):
34+
def test(self, host_target):
3535
"""Just run a single instance of the command for both .debug and
3636
.release.
3737
"""

utils/swift_build_support/swift_build_support/products/indexstoredb.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -27,10 +27,10 @@ def product_source_name(cls):
2727
def is_build_script_impl_product(cls):
2828
return False
2929

30-
def do_build(self, host_target):
30+
def build(self, host_target):
3131
run_build_script_helper('build', host_target, self, self.args)
3232

33-
def do_test(self, host_target):
33+
def test(self, host_target):
3434
if self.args.test and self.args.test_indexstoredb:
3535
run_build_script_helper('test', host_target, self, self.args)
3636

utils/swift_build_support/swift_build_support/products/ninja.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -32,7 +32,7 @@ def is_build_script_impl_product(cls):
3232
def ninja_bin_path(self):
3333
return os.path.join(self.build_dir, 'ninja')
3434

35-
def do_build(self):
35+
def build(self):
3636
if os.path.exists(self.ninja_bin_path):
3737
return
3838

utils/swift_build_support/swift_build_support/products/product.py

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -38,15 +38,15 @@ def is_build_script_impl_product(cls):
3838
"""
3939
return True
4040

41-
def do_build(self, host_target):
42-
"""do_build() -> void
41+
def build(self, host_target):
42+
"""build() -> void
4343
4444
Perform the build, for a non-build-script-impl product.
4545
"""
4646
raise NotImplementedError
4747

48-
def do_test(self, host_target):
49-
"""do_build() -> void
48+
def test(self, host_target):
49+
"""test() -> void
5050
5151
Run the tests, for a non-build-script-impl product.
5252
"""

utils/swift_build_support/swift_build_support/products/sourcekitlsp.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -23,11 +23,11 @@ def product_source_name(cls):
2323
def is_build_script_impl_product(cls):
2424
return False
2525

26-
def do_build(self, host_target):
26+
def build(self, host_target):
2727
indexstoredb.run_build_script_helper(
2828
'build', host_target, self, self.args)
2929

30-
def do_test(self, host_target):
30+
def test(self, host_target):
3131
if self.args.test and self.args.test_sourcekitlsp:
3232
indexstoredb.run_build_script_helper(
3333
'test', host_target, self, self.args)

utils/swift_build_support/tests/products/test_ninja.py

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -79,14 +79,14 @@ def test_ninja_bin_path(self):
7979

8080
self.assertEqual(ninja_build.ninja_bin_path, '/path/to/build/ninja')
8181

82-
def test_do_build(self):
82+
def test_build(self):
8383
ninja_build = Ninja(
8484
args=self.args,
8585
toolchain=self.toolchain,
8686
source_dir=self.workspace.source_dir('ninja'),
8787
build_dir=self.workspace.build_dir('build', 'ninja'))
8888

89-
ninja_build.do_build()
89+
ninja_build.build()
9090

9191
expect_env = ""
9292
if platform.system() == "Darwin":

0 commit comments

Comments
 (0)