[autotest] Inject a dictionary of vars into suite control files

Currently we inject a bunch of variables into suite control files that are
passed to dynamic_suites. This makes changing dynamic_suites interface hard
as we need to push to both the lab and moblab. Switch to inject the dictionary
directly in suite control files. After the change, the dictionary and the
bunch of variables will coexist.

BUG=chromium:480684
TEST=Test with unittest and moblab

Change-Id: I6d1491f8502c0409039b687f0ff77775e1036693
Reviewed-on: https://chromium-review.googlesource.com/269224
Tested-by: Shuqian Zhao <shuqianz@chromium.org>
Reviewed-by: Aviv Keshet <akeshet@chromium.org>
Reviewed-by: Simran Basi <sbasi@chromium.org>
Commit-Queue: Shuqian Zhao <shuqianz@chromium.org>
diff --git a/server/cros/dynamic_suite/tools.py b/server/cros/dynamic_suite/tools.py
index a09be3b..e3d8b54 100644
--- a/server/cros/dynamic_suite/tools.py
+++ b/server/cros/dynamic_suite/tools.py
@@ -148,7 +148,9 @@
             control_file += "%s=%s\n" % (key, repr(value))
         else:
             control_file += "%s=%r\n" % (key, value)
-    return control_file + control_file_in
+
+    args_dict_str = "%s=%s\n" % ('args_dict', repr(vars))
+    return control_file + args_dict_str + control_file_in
 
 
 def is_usable(host):