def check_skip_with_microversion(test_min_version, test_max_version, cfg_min_version, cfg_max_version):
 min_version = api_version_request.APIVersionRequest(test_min_version)
 max_version = api_version_request.APIVersionRequest(test_max_version)
 config_min_version = api_version_request.APIVersionRequest(cfg_min_version)
 config_max_version = api_version_request.APIVersionRequest(cfg_max_version)
 if ((min_version > max_version) or (config_min_version > config_max_version)):
  msg = ('Test Class versions [%s - %s]. Configuration versions [%s - %s].' % (min_version.get_string(), max_version.get_string(), config_min_version.get_string(), config_max_version.get_string()))
  raise exceptions.InvalidAPIVersionRange(msg)
 if ((max_version < config_min_version) or (config_max_version < min_version)):
  msg = ('The microversion range[%s - %s] of this test is out of the configuration range[%s - %s].' % (min_version.get_string(), max_version.get_string(), config_min_version.get_string(), config_max_version.get_string()))
  raise testtools.TestCase.skipException(msg)

def check_skip_with_microversion ( test_min_version , test_max_version , cfg_min_version , cfg_max_version ) : min_version = api_version_request . APIVersionRequest ( test_min_version ) max_version = api_version_request . APIVersionRequest ( test_max_version ) config_min_version = api_version_request . APIVersionRequest ( cfg_min_version ) config_max_version = api_version_request . APIVersionRequest ( cfg_max_version ) if ( ( min_version > max_version ) or ( config_min_version > config_max_version ) ) : msg = ( 'Test Class versions [%s - %s]. Configuration versions [%s - %s].' % ( min_version . get_string ( ) , max_version . get_string ( ) , config_min_version . get_string ( ) , config_max_version . get_string ( ) ) ) raise exceptions . InvalidAPIVersionRange ( msg ) if ( ( max_version < config_min_version ) or ( config_max_version < min_version ) ) : msg = ( 'The microversion range[%s - %s] of this test is out of the configuration range[%s - %s].' % ( min_version . get_string ( ) , max_version . get_string ( ) , config_min_version . get_string ( ) , config_max_version . get_string ( ) ) ) raise testtools . TestCase . skipException ( msg )
checks api microversions range and returns whether test needs to be skip compare the test and configured microversion range and returns whether test microversion range is out of configured one .