8000 tests: Move base rule tests under tests instead of //tools/build_defs… · geaden/rules_python@4dfb78d · GitHub
[go: up one dir, main page]

Skip to content

Commit 4dfb78d

Browse files
authored
tests: Move base rule tests under tests instead of //tools/build_defs/python (bazel-contrib#1440)
The tools/build_defs/python path is an artifact of some Google-internal naming that isn't applicable to the rules_python source tree layout. With the Starlark implementation running in CI and working in some capacity, it's time to move them to a less mysterious location. * Also moves the py_wheel tests out of the base rule tests. Not sure how they ended up there. Work towards bazel-contrib#1069
1 parent 4862a8d commit 4dfb78d

File tree

13 files changed

+12
-12
lines changed

13 files changed

+12
-12
lines changed

tools/build_defs/python/tests/base_tests.bzl renamed to tests/base_rules/base_tests.bzl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -17,8 +17,8 @@ load("@rules_testing//lib:analysis_test.bzl", "analysis_test")
1717
load("@rules_testing//lib:truth.bzl", "matching")
1818
load("@rules_testing//lib:util.bzl", "PREVENT_IMPLICIT_BUILDING_TAGS", rt_util = "util")
1919
load("//python:defs.bzl", "PyInfo")
20-
load("//tools/build_defs/python/tests:py_info_subject.bzl", "py_info_subject")
21-
load("//tools/build_defs/python/tests:util.bzl", pt_util = "util")
20+
load("//tests/base_rules:py_info_subject.bzl", "py_info_subject")
21+
load("//tests/base_rules:util.bzl", pt_util = "util")
2222

2323
_tests = []
2424

tools/build_defs/python/tests/py_binary/py_binary_tests.bzl renamed to tests/base_rules/py_binary/py_binary_tests.bzl

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -15,7 +15,7 @@
1515

1616
load("//python:defs.bzl", "py_binary")
1717
load(
18-
"//tools/build_defs/python/tests:py_executable_base_tests.bzl",
18+
"//tests/base_rules:py_executable_base_tests.bzl",
1919
"create_executable_tests",
2020
)
2121

tools/build_defs/python/tests/py_executable_base_tests.bzl renamed to tests/base_rules/py_executable_base_tests.bzl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -16,8 +16,8 @@
1616
load("@rules_testing//lib:analysis_test.bzl", "analysis_test")
1717
load("@rules_testing//lib:truth.bzl", "matching")
1818
load("@rules_testing//lib:util.bzl", rt_util = "util")
19-
load("//tools/build_defs/python/tests:base_tests.bzl", "create_base_tests")
20-
load("//tools/build_defs/python/tests:util.bzl", "WINDOWS_ATTR", pt_util = "util")
19+
load("//tests/base_rules:base_tests.bzl", "create_base_tests")
20+
load("//tests/base_rules:util.bzl", "WINDOWS_ATTR", pt_util = "util")
2121

2222
_tests = []
2323

tools/build_defs/python/tests/py_library/py_library_tests.bzl renamed to tests/base_rules/py_library/py_library_tests.bzl

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -4,8 +4,8 @@ load("@rules_testing//lib:analysis_test.bzl", "analysis_test")
44
load("@rules_testing//lib:truth.bzl", "matching")
55
load("@rules_testing//lib:util.bzl", rt_util = "util")
66
load("//python:defs.bzl", "PyRuntimeInfo", "py_library")
7-
load("//tools/build_defs/python/tests:base_tests.bzl", "create_base_tests")
8-
load("//tools/build_defs/python/tests:util.bzl", pt_util = "util")
7+
load("//tests/base_rules:base_tests.bzl", "create_base_tests")
8+
load("//tests/base_rules:util.bzl", pt_util = "util")
99

1010
_tests = []
1111

tools/build_defs/python/tests/py_test/py_test_tests.bzl renamed to tests/base_rules/py_test/py_test_tests.bzl

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -17,17 +17,17 @@ load("@rules_testing//lib:analysis_test.bzl", "analysis_test")
1717
load("@rules_testing//lib:util.bzl", rt_util = "util")
1818
load("//python:defs.bzl", "py_test")
1919
load(
20-
"//tools/build_defs/python/tests:py_executable_base_tests.bzl",
20+
"//tests/base_rules:py_executable_base_tests.bzl",
2121
"create_executable_tests",
2222
)
23-
load("//tools/build_defs/python/tests:util.bzl", pt_util = "util")
23+
load("//tests/base_rules:util.bzl", pt_util = "util")
2424

2525
# Explicit Label() calls are required so that it resolves in @rules_python context instead of
2626
# @rules_testing context.
2727
_FAKE_CC_TOOLCHAIN = Label("//tests/cc:cc_toolchain_suite")
2828
_FAKE_CC_TOOLCHAINS = [str(Label("//tests/cc:all"))]
29-
_PLATFORM_MAC = Label("//tools/build_defs/python/tests:mac")
30-
_PLATFORM_LINUX = Label("//tools/build_defs/python/tests:linux")
29+
_PLATFORM_MAC = Label("//tests/base_rules:mac")
30+
_PLATFORM_LINUX = Label("//tests/base_rules:linux")
3131

3232
_tests = []
3333

0 commit comments

Comments
 (0)
0