add LOCAL_DISABLE_TEST_CONFIG logic

Disable the generation of .config file when the variable
LOCAL_DISABLE_TEST_CONFIG is true.

Bug: 188927912
Test: rum 'm module-name' (`android_test_helper_app` type module)
Test: TreeHugger
Change-Id: I64372b4ba84fcf1af937abdee345ceb1d3c2f6c5
diff --git a/core/base_rules.mk b/core/base_rules.mk
index 5f654a6..1b7a279 100644
--- a/core/base_rules.mk
+++ b/core/base_rules.mk
@@ -759,6 +759,12 @@
 endif
 is_instrumentation_test :=
 
+# Currently this flag variable is true only for the `android_test_helper_app` type module
+# which should not have any .config file
+ifeq (true, $(LOCAL_DISABLE_TEST_CONFIG))
+  test_config :=
+endif
+
 # Make sure we only add the files once for multilib modules.
 ifdef $(my_prefix)$(LOCAL_MODULE_CLASS)_$(LOCAL_MODULE)_compat_files
   # Sync the auto_test_config value for multilib modules.