

@mock.patch('boto3.resources.factory.WaiterAction')
def test_resource_waiter_calls_waiter_method(self, waiter_action_cls):
    model = {
        'waiters': {
            'Exists': {
                'waiterName': 'BucketExists',
                'params': [{
                    'target': 'Bucket',
                    'source': 'identifier',
                    'name': 'Name',
                }],
            },
        },
    }
    defs = {
        'Bucket': {
            
        },
    }
    service_model = ServiceModel({
        
    })
    waiter_action = waiter_action_cls.return_value
    resource = self.load('test', model, defs, service_model)()
    waiter_action.wait_until_exists('arg1', arg2=2)
    waiter_action.assert_called_with(resource, 'arg1', arg2=2)

dataset/ETHPy150Open boto/boto3/tests/unit/resources/test_factory.py TestResourceFactory.test_resource_waiter_calls_waiter_method/VarMisuse@116/181 `resource`->`waiter_action`