Fix accessing shared policies, add assoc tests

This patch is two-fold:
1. Previously, policies that were created using the 'shared=True' flag
   were not accessible to other tenants, since the context used to
   search the policies was not elevated. This patch elevates the context
   prior to retrieving the policy, and if a match was found, makes sure
   that the user has permissions to access it (either the policy is
   shared or it's from the same tenant id).
2. Tests for both associations and disassociations of policies to both
   networks and ports are added in this patch, to make sure coverage is
   good and that the problem is fixed.

Change-Id: Idec13ff4ec575b6d0c0a455c1b3bd9d9700ff7fb
diff --git a/neutron/tests/tempest/services/network/json/network_client.py b/neutron/tests/tempest/services/network/json/network_client.py
index bc8eaa2..c01c83c 100644
--- a/neutron/tests/tempest/services/network/json/network_client.py
+++ b/neutron/tests/tempest/services/network/json/network_client.py
@@ -653,12 +653,6 @@
         self.expected_success(200, resp.status)
         return service_client.ResponseBody(resp, body)
 
-    def get_qos_policy(self, policy_id):
-        uri = '%s/qos/policies/%s' % (self.uri_prefix, policy_id)
-        resp, body = self.get(uri)
-        self.expected_success(200, resp.status)
-        return service_client.ResponseBody(resp, body)
-
     def create_bandwidth_limit_rule(self, policy_id, max_kbps, max_burst_kbps):
         uri = '%s/qos/policies/%s/bandwidth_limit_rules' % (
             self.uri_prefix, policy_id)