Add _error_checker() call on versions_client

There are two REST API operation methods (request and raw_request)
under tempest.lib and most service clients use request().
request() calls _error_checker() for translating HTTP error code to
the corresponding exception, however raw_request() doesn't do that
because of the raw method.
When an exception happens on service client methods which calls
raw_request(), now Tempest cannot translated and it makes some
unexpected situation like I6c05ad377847e2b67ab988efdba006f73cbafcfe

This patch adds _error_checker() call to them.

Change-Id: I9acf45eb1711683b47f0606ed7c1a9c8327ef241
diff --git a/releasenotes/notes/add-error-code-translation-to-versions-clients-acbc78292e24b014.yaml b/releasenotes/notes/add-error-code-translation-to-versions-clients-acbc78292e24b014.yaml
new file mode 100644
index 0000000..57bf47c
--- /dev/null
+++ b/releasenotes/notes/add-error-code-translation-to-versions-clients-acbc78292e24b014.yaml
@@ -0,0 +1,6 @@
+---
+upgrade:
+  - Add an error translation to list_versions() of versions_client of both
+    compute and network. This can affect users who are expecting that these
+    clients return error status code instead of the exception. It is needed
+    to change the code for handling the exception like the other clients code.
diff --git a/tempest/lib/services/compute/versions_client.py b/tempest/lib/services/compute/versions_client.py
index eb4e7e9..b2052c3 100644
--- a/tempest/lib/services/compute/versions_client.py
+++ b/tempest/lib/services/compute/versions_client.py
@@ -40,6 +40,7 @@
     def list_versions(self):
         version_url = self._get_base_version_url()
         resp, body = self.raw_request(version_url, 'GET')
+        self._error_checker(resp, body)
         body = json.loads(body)
         self.validate_response(schema.list_versions, resp, body)
         return rest_client.ResponseBody(resp, body)
@@ -56,6 +57,7 @@
         # we need a token for this request
         resp, body = self.raw_request(version_url, 'GET',
                                       {'X-Auth-Token': self.token})
+        self._error_checker(resp, body)
         body = json.loads(body)
         self.validate_response(schema.get_one_version, resp, body)
         return rest_client.ResponseBody(resp, body)
diff --git a/tempest/lib/services/network/versions_client.py b/tempest/lib/services/network/versions_client.py
index 0202927..a9c3bbf 100644
--- a/tempest/lib/services/network/versions_client.py
+++ b/tempest/lib/services/network/versions_client.py
@@ -35,6 +35,7 @@
         start = time.time()
         self._log_request_start('GET', version_url)
         response, body = self.raw_request(version_url, 'GET')
+        self._error_checker(response, body)
         end = time.time()
         self._log_request('GET', version_url, response,
                           secs=(end - start), resp_body=body)