

@staticmethod
def create_one_security_group_rule(attrs=None):
    'Create a fake security group rule.\n\n        :param Dictionary attrs:\n            A dictionary with all attributes\n        :return:\n            A FakeResource object, with id, etc.\n        '
    attrs = (attrs or {
        
    })
    security_group_rule_attrs = {
        'from_port': 0,
        'group': {
            
        },
        'id': ('security-group-rule-id-' + uuid.uuid4().hex),
        'ip_protocol': 'tcp',
        'ip_range': {
            'cidr': '0.0.0.0/0',
        },
        'parent_group_id': ('security-group-id-' + uuid.uuid4().hex),
        'to_port': 0,
    }
    security_group_rule_attrs.update(security_group_rule)
    security_group_rule = fakes.FakeResource(info=copy.deepcopy(security_group_rule_attrs), loaded=True)
    return security_group_rule

dataset/ETHPy150Open dtroyer/python-openstackclient/openstackclient/tests/compute/v2/fakes.py FakeSecurityGroupRule.create_one_security_group_rule/VarMisuse@103/236 `attrs`->`security_group_rule`