Update generated python proto, removing Image.ImageType.

Update the generated python protos. This removes the enum Image.ImageType
which is moved to chromiumos common.proto to be shared with BuilderConfig.
Fix up tests which were still using the old proto.

TEST=./run_tests
BUG=None

Change-Id: I6e393d3e307d23f6be4e4b9aa76e74a63b0009aa
Reviewed-on: https://chromium-review.googlesource.com/c/chromiumos/chromite/+/1611016
Reviewed-by: Jason Clinton <jclinton@chromium.org>
Commit-Queue: David Burger <dburger@chromium.org>
Tested-by: David Burger <dburger@chromium.org>
diff --git a/api/controller/image_unittest.py b/api/controller/image_unittest.py
index f35e87a..f26abb1 100644
--- a/api/controller/image_unittest.py
+++ b/api/controller/image_unittest.py
@@ -11,6 +11,7 @@
 import os
 
 from chromite.api.gen.chromite.api import image_pb2
+from chromite.api.gen.chromiumos import common_pb2
 from chromite.api.controller import image as image_controller
 from chromite.lib import constants
 from chromite.lib import cros_build_lib
@@ -46,13 +47,13 @@
                                    board=u'board', config=mock.ANY)
 
     # Should be using a value that's provided.
-    input_proto.image_types.append(image_pb2.Image.DEV)
+    input_proto.image_types.append(common_pb2.DEV)
     image_controller.Create(input_proto, output_proto)
     build_patch.assert_called_with(images=[constants.IMAGE_TYPE_DEV],
                                    board=u'board', config=mock.ANY)
 
-    input_proto.image_types.append(image_pb2.Image.BASE)
-    input_proto.image_types.append(image_pb2.Image.TEST)
+    input_proto.image_types.append(common_pb2.BASE)
+    input_proto.image_types.append(common_pb2.TEST)
     expected_images = [constants.IMAGE_TYPE_BASE, constants.IMAGE_TYPE_DEV,
                        constants.IMAGE_TYPE_TEST]
     image_controller.Create(input_proto, output_proto)
@@ -98,7 +99,7 @@
 
   def testNoBuildTargetFails(self):
     """Make sure it fails with no build target."""
-    request = self._GetInput(image_type=image_pb2.Image.TEST)
+    request = self._GetInput(image_type=common_pb2.TEST)
     response = self._GetOutput()
 
     with self.assertRaises(cros_build_lib.DieSystemExit):
@@ -114,7 +115,7 @@
 
   def testTestImage(self):
     """Make sure the test image identification works properly."""
-    request = self._GetInput(board='board', image_type=image_pb2.Image.TEST)
+    request = self._GetInput(board='board', image_type=common_pb2.TEST)
     response = self._GetOutput()
     create_patch = self.PatchObject(image_service, 'CreateVm',
                                     return_value='/vm/path')
@@ -125,7 +126,7 @@
 
   def testNonTestImage(self):
     """Make sure the test image identification works properly."""
-    request = self._GetInput(board='board', image_type=image_pb2.Image.BASE)
+    request = self._GetInput(board='board', image_type=common_pb2.BASE)
     response = self._GetOutput()
     create_patch = self.PatchObject(image_service, 'CreateVm',
                                     return_value='/vm/path')