[autotest] Do not enforce minimum available duts check for certain conditions

1. suite name is not in the white list defined in global config.
2. Autotest instance is not in lab, e.g., local setup or moblab.
3. Total number of all duts are less than the minimum requirement.

BUG=chromium:377063,chromium:377083
TEST=run_suite against local and cauotest instance, make sure all 3 conditions
are covered.

Change-Id: I7d2865e173a7bafc373cb4d08fa27d969b6cd79f
Reviewed-on: https://chromium-review.googlesource.com/201425
Commit-Queue: Dan Shi <dshi@chromium.org>
Tested-by: Dan Shi <dshi@chromium.org>
Reviewed-by: Simran Basi <sbasi@chromium.org>
diff --git a/server/site_utils.py b/server/site_utils.py
index f34c923..6f4c905 100644
--- a/server/site_utils.py
+++ b/server/site_utils.py
@@ -209,6 +209,16 @@
     return
 
 
+def is_in_lab():
+    """Check if current Autotest instance is in lab
+
+    @return: True if the Autotest instance is in lab.
+    """
+    test_server_name = global_config.global_config.get_config_value(
+              'SERVER', 'hostname')
+    return test_server_name.startswith('cautotest')
+
+
 def check_lab_status(build):
     """Check if the lab status allows us to schedule for a build.
 
@@ -222,9 +232,7 @@
 
     """
     # Ensure we are trying to schedule on the actual lab.
-    test_server_name = global_config.global_config.get_config_value(
-              'SERVER', 'hostname')
-    if not test_server_name.startswith('cautotest'):
+    if not is_in_lab():
         return
 
     # Download the lab status from its home on the web.