Remove old BUILD file merging code

It's not needed anymore since aosp/2197837,
it should've been removed in that cl but I forgot.

Bug: 234167862
Test: ./build/bazel/ci/bp2build.sh
Change-Id: I3d67a6e1894ad401525070ad37d3158708898306
This commit is contained in:
Cole Faust
2022-08-31 14:48:26 -07:00
parent 52d9b95f54
commit ea602c5a41
5 changed files with 9 additions and 124 deletions

View File

@@ -1299,9 +1299,7 @@ func TestCombineBuildFilesBp2buildTargets(t *testing.T) {
name: "fg_foo",
bazel_module: { label: "//other:fg_foo" },
}`,
ExpectedBazelTargets: []string{
`// BUILD file`,
},
ExpectedBazelTargets: []string{},
Filesystem: map[string]string{
"other/BUILD.bazel": `// BUILD file`,
},
@@ -1319,9 +1317,7 @@ func TestCombineBuildFilesBp2buildTargets(t *testing.T) {
name: "foo",
bazel_module: { label: "//other:foo" },
}`,
ExpectedBazelTargets: []string{
`// BUILD file`,
},
ExpectedBazelTargets: []string{},
Filesystem: map[string]string{
"other/BUILD.bazel": `// BUILD file`,
},
@@ -1349,7 +1345,6 @@ func TestCombineBuildFilesBp2buildTargets(t *testing.T) {
},
ExpectedBazelTargets: []string{
MakeBazelTargetNoRestrictions("filegroup", "fg_foo", map[string]string{}),
`// definition for fg_bar`,
},
},
{
@@ -1375,7 +1370,6 @@ func TestCombineBuildFilesBp2buildTargets(t *testing.T) {
}`,
ExpectedBazelTargets: []string{
MakeBazelTargetNoRestrictions("filegroup", "fg_bar", map[string]string{}),
`// BUILD file`,
},
},
}
@@ -1420,9 +1414,6 @@ func TestCombineBuildFilesBp2buildTargets(t *testing.T) {
if actualCount != expectedCount {
t.Errorf("Expected %d bazel target, got %d\n%s", expectedCount, actualCount, bazelTargets)
}
if !strings.Contains(bazelTargets.String(), "Section: Handcrafted targets. ") {
t.Errorf("Expected string representation of bazelTargets to contain handcrafted section header.")
}
for i, target := range bazelTargets {
actualContent := target.content
expectedContent := testCase.ExpectedBazelTargets[i]