<s> from tests import unittest <EOL> from boto3 . session import Session <EOL> from boto3 . resources . collection import ResourceCollection <EOL> class TestCollection ( unittest . TestCase ) : <EOL> def setUp ( self ) : <EOL> self . session = Session ( <EOL> aws_access_key_id = '<STR_LIT>' , aws_secret_access_key = '<STR_LIT>' , <EOL> region_name = '<STR_LIT>' ) <EOL> self . ec2_resource = self . session . resource ( '<STR_LIT>' ) <EOL> def test_can_use_collection_methods ( self ) : <EOL> self . assertIsInstance ( <EOL> self . ec2_resource . instances . all ( ) , ResourceCollection ) <EOL> def test_can_chain_methods ( self ) : <EOL> self . assertIsInstance ( <EOL> self . ec2_resource . instances . all ( ) . page_size ( <NUM_LIT:5> ) , ResourceCollection ) </s>
