HyukjinKwon commented on a change in pull request #29057:
URL: https://github.com/apache/spark/pull/29057#discussion_r452756207



##########
File path: dev/run-tests.py
##########
@@ -595,13 +601,28 @@ def main():
 
     changed_modules = None
     changed_files = None
-    if test_env == "amplab_jenkins" and os.environ.get("AMP_JENKINS_PRB"):
+    should_only_test_modules = "TEST_ONLY_MODULES" in os.environ
+    included_tags = []
+    if should_only_test_modules:
+        str_test_modules = [m.strip() for m in 
os.environ.get("TEST_ONLY_MODULES").split(",")]
+        test_modules = [m for m in modules.all_modules if m.name in 
str_test_modules]
+        # Directly uses test_modules as changed modules to apply tags and 
environments
+        # as if all specified test modules are changed.
+        changed_modules = test_modules
+        str_excluded_tags = os.environ.get("TEST_ONLY_EXCLUDED_TAGS", None)
+        str_included_tags = os.environ.get("TEST_ONLY_INCLUDED_TAGS", None)
+        excluded_tags = []
+        if str_excluded_tags:
+            excluded_tags = [t.strip() for t in str_excluded_tags.split(",")]
+        included_tags = []
+        if str_included_tags:
+            included_tags = [t.strip() for t in str_included_tags.split(",")]
+    elif test_env == "amplab_jenkins" and os.environ.get("AMP_JENKINS_PRB"):
         target_branch = os.environ["ghprbTargetBranch"]
         changed_files = identify_changed_files_from_git_commits("HEAD", 
target_branch=target_branch)
         changed_modules = determine_modules_for_files(changed_files)
         excluded_tags = determine_tags_to_exclude(changed_modules)
-
-    if not changed_modules:
+    else:

Review comment:
       Oh, okay. let me just change it back




----------------------------------------------------------------
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

For queries about this service, please contact Infrastructure at:
[email protected]



---------------------------------------------------------------------
To unsubscribe, e-mail: [email protected]
For additional commands, e-mail: [email protected]

Reply via email to