summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--ui/build/build.go3
-rw-r--r--ui/build/test_build.go6
2 files changed, 8 insertions, 1 deletions
diff --git a/ui/build/build.go b/ui/build/build.go
index ea867826c..95d7831d2 100644
--- a/ui/build/build.go
+++ b/ui/build/build.go
@@ -427,6 +427,9 @@ func evaluateWhatToRun(config Config, verboseln func(v ...interface{})) int {
if config.Checkbuild() {
what |= RunBuildTests
}
+ if value, ok := config.environ.Get("RUN_BUILD_TESTS"); ok && value == "true" {
+ what |= RunBuildTests
+ }
if !config.SkipConfig() {
what |= RunProductConfig
} else {
diff --git a/ui/build/test_build.go b/ui/build/test_build.go
index 7a2fd1668..87bec93a2 100644
--- a/ui/build/test_build.go
+++ b/ui/build/test_build.go
@@ -76,8 +76,10 @@ func testForDanglingRules(ctx Context, config Config) {
// treated as an source file.
dexpreoptConfigFilePath := filepath.Join(outDir, "soong", "dexpreopt.config")
- // out/build_date.txt is considered a "source file"
+ // out/build_(date|hostname|number).txt is considered a "source file"
buildDatetimeFilePath := filepath.Join(outDir, "build_date.txt")
+ buildHostnameFilePath := filepath.Join(outDir, "soong", "build_hostname.txt")
+ buildNumberFilePath := filepath.Join(outDir, "soong", "build_number.txt")
// release-config files are generated from the initial lunch or Kati phase
// before running soong and ninja.
@@ -102,6 +104,8 @@ func testForDanglingRules(ctx Context, config Config) {
line == extraVariablesFilePath ||
line == dexpreoptConfigFilePath ||
line == buildDatetimeFilePath ||
+ line == buildHostnameFilePath ||
+ line == buildNumberFilePath ||
strings.HasPrefix(line, releaseConfigDir) ||
buildFingerPrintFilePattern.MatchString(line) {
// Leaf node is in one of Soong's bootstrap directories, which do not have