How to use describe_fleets method in localstack

Best Python code snippet using localstack_python

aws_appstream_info.py

Source:aws_appstream_info.py Github

copy

Full Screen

...232 return paginator.paginate(233 Names=module.params['names']234 ), True235 else:236 return client.describe_fleets(237 Names=module.params['names']238 ), False239 elif module.params['describe_stacks']:240 if client.can_paginate('describe_stacks'):241 paginator = client.get_paginator('describe_stacks')242 return paginator.paginate(243 Names=module.params['names']244 ), True245 else:246 return client.describe_stacks(247 Names=module.params['names']248 ), False249 elif module.params['describe_directory_configs']:250 if client.can_paginate('describe_directory_configs'):...

Full Screen

Full Screen

waiter.py

Source:waiter.py Github

copy

Full Screen

1from typing import Dict2from typing import List3from botocore.waiter import Waiter4class FleetStarted(Waiter):5 def wait(self, Names: List = None, NextToken: str = None, WaiterConfig: Dict = None):6 """7 Polls :py:meth:`AppStream.Client.describe_fleets` every 30 seconds until a successful state is reached. An error is returned after 40 failed checks.8 See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/appstream-2016-12-01/DescribeFleets>`_9 10 **Request Syntax**11 ::12 waiter.wait(13 Names=[14 'string',15 ],16 NextToken='string',17 WaiterConfig={18 'Delay': 123,19 'MaxAttempts': 12320 }21 )22 :type Names: list23 :param Names:24 The names of the fleets to describe.25 - *(string) --*26 :type NextToken: string27 :param NextToken:28 The pagination token to use to retrieve the next page of results for this operation. If this value is null, it retrieves the first page.29 :type WaiterConfig: dict30 :param WaiterConfig:31 A dictionary that provides parameters to control waiting behavior.32 - **Delay** *(integer) --*33 The amount of time in seconds to wait between attempts. Default: 3034 - **MaxAttempts** *(integer) --*35 The maximum number of attempts to be made. Default: 4036 :returns: None37 """38 pass39class FleetStopped(Waiter):40 def wait(self, Names: List = None, NextToken: str = None, WaiterConfig: Dict = None):41 """42 Polls :py:meth:`AppStream.Client.describe_fleets` every 30 seconds until a successful state is reached. An error is returned after 40 failed checks.43 See also: `AWS API Documentation <https://docs.aws.amazon.com/goto/WebAPI/appstream-2016-12-01/DescribeFleets>`_44 45 **Request Syntax**46 ::47 waiter.wait(48 Names=[49 'string',50 ],51 NextToken='string',52 WaiterConfig={53 'Delay': 123,54 'MaxAttempts': 12355 }56 )57 :type Names: list58 :param Names:59 The names of the fleets to describe.60 - *(string) --*61 :type NextToken: string62 :param NextToken:63 The pagination token to use to retrieve the next page of results for this operation. If this value is null, it retrieves the first page.64 :type WaiterConfig: dict65 :param WaiterConfig:66 A dictionary that provides parameters to control waiting behavior.67 - **Delay** *(integer) --*68 The amount of time in seconds to wait between attempts. Default: 3069 - **MaxAttempts** *(integer) --*70 The maximum number of attempts to be made. Default: 4071 :returns: None72 """...

Full Screen

Full Screen

test_get_fleet.py

Source:test_get_fleet.py Github

copy

Full Screen

1import lobotomy2from manager import _controller3from manager import _types4fleet_data = {5 "FleetId": "fleet-123",6 "Tags": [7 {"Key": "size", "Value": "small"},8 {"Key": "sector", "Value": "primary"},9 {"Key": "fleet", "Value": "primary-small"},10 {"Key": "Foo", "Value": "bar"},11 ],12 "TargetCapacitySpecification": {"TotalTargetCapacity": 2},13}14@lobotomy.patch()15def test_get_fleet(lobotomized: "lobotomy.Lobotomy"):16 """Should retrieve and transform EC2 fleet data into a Fleet."""17 lobotomized.add_call("ec2", "describe_fleets", {"Fleets": [fleet_data]})18 configs = _types.ManagerConfigs()19 fleet_requirements = _types.FleetRequirements(20 configs=configs,21 sector="primary",22 size_spec=_types.SMALL_MEMORY_SPEC,23 )24 fleet = _controller.get_fleet(configs, fleet_requirements)25 assert fleet.identifier == "fleet-123"26 assert fleet.sector == "primary"27 assert fleet.name == "primary-small"...

Full Screen

Full Screen

Automation Testing Tutorials

Learn to execute automation testing from scratch with LambdaTest Learning Hub. Right from setting up the prerequisites to run your first automation test, to following best practices and diving deeper into advanced test scenarios. LambdaTest Learning Hubs compile a list of step-by-step guides to help you be proficient with different test automation frameworks i.e. Selenium, Cypress, TestNG etc.

LambdaTest Learning Hubs:

YouTube

You could also refer to video tutorials over LambdaTest YouTube channel to get step by step demonstration from industry experts.

Run localstack automation tests on LambdaTest cloud grid

Perform automation testing on 3000+ real desktop and mobile devices online.

Try LambdaTest Now !!

Get 100 minutes of automation test minutes FREE!!

Next-Gen App & Browser Testing Cloud

Was this article helpful?

Helpful

NotHelpful