[Negative] Create share over quota limit

This test ensures we are denied from creating new shares,
when hitting the quota enforcements.

Change-Id: Ice3acba7daecc5d6b1eeb094f26cbf1cd70aad90
diff --git a/manila_tempest_tests/tests/api/admin/test_quotas_negative.py b/manila_tempest_tests/tests/api/admin/test_quotas_negative.py
index ae87791..973be94 100644
--- a/manila_tempest_tests/tests/api/admin/test_quotas_negative.py
+++ b/manila_tempest_tests/tests/api/admin/test_quotas_negative.py
@@ -351,3 +351,17 @@
             share_type=share_type['name'],
             force=False,
             shares=st_q)
+
+    @tc.attr(base.TAG_NEGATIVE, base.TAG_API_WITH_BACKEND)
+    def test_create_share_over_quota_limit(self):
+        original_quota = self.shares_v2_client.show_quotas(
+            self.tenant_id)
+        self.create_share(share_type_id=self.share_type_id)
+        self.shares_v2_client.update_quotas(self.tenant_id, shares=1)
+        self.addCleanup(self.shares_v2_client.update_quotas,
+                        self.tenant_id, shares=original_quota['shares'])
+        self.shares_v2_client.show_quotas(self.tenant_id)
+
+        self.assertRaises(lib_exc.OverLimit,
+                          self.create_share,
+                          share_type_id=self.share_type_id)