import json
import logging
+import os
import random
import re
import string
import time
+import unittest
from collections import namedtuple
from functools import wraps
from typing import List, Optional, Tuple, Type, Union
raise err
return wrapper
return decorator
+
+
+skip_unless_dashboard_pr = unittest.skipUnless(
+ os.environ.get('ghprbPullTitle', '').startswith('mgr/dashboard:'),
+ 'Skipping because PR title does not start with mgr/dashboard')
from cryptography.hazmat.primitives.hashes import SHA1
from cryptography.hazmat.primitives.twofactor.totp import TOTP
-from .helper import DashboardTestCase, JLeaf, JList, JObj
+from .helper import (DashboardTestCase, JLeaf, JList, JObj,
+ skip_unless_dashboard_pr)
logger = logging.getLogger(__name__)
return self._get('/api/rgw/user/{}?stats={}'.format(uid, stats))
+@skip_unless_dashboard_pr
class RgwSiteTest(RgwTestCase):
AUTH_ROLES = ['rgw-manager']