diff options
author | 2025-02-06 22:45:56 +0000 | |
---|---|---|
committer | 2025-02-06 23:33:34 +0000 | |
commit | b6ed11f9a840aabe414f9d775ba60050b7a6a8b8 (patch) | |
tree | 8092e486d3c544638498e90a74e79d2d41078d20 | |
parent | 917b0ec873a3bd50808378fe0c41ec9c20efa3b0 (diff) |
Add a unit test for module name enforcement
With https://r.android.com/3478084, blueprint will become more strict on
allowing special chars in module names.
Test: m nothing --no-skip-soong-tests
Change-Id: I89fd7631d6e12e5af25641ca953f9e5659a9728c
-rw-r--r-- | android/module_test.go | 11 |
1 files changed, 11 insertions, 0 deletions
diff --git a/android/module_test.go b/android/module_test.go index 6e6d44909..3b81dedc7 100644 --- a/android/module_test.go +++ b/android/module_test.go @@ -1110,3 +1110,14 @@ func TestVintfFragmentModulesChecksPartition(t *testing.T) { "Module .+ and Vintf_fragment .+ are installed to different partitions.")). RunTestWithBp(t, bp) } + +func TestInvalidModuleName(t *testing.T) { + bp := ` + deps { + name: "fo o", + } + ` + prepareForModuleTests. + ExtendWithErrorHandler(FixtureExpectsOneErrorPattern(`should use a valid name`)). + RunTestWithBp(t, bp) +} |