Docs: using assertEqual instead of list.should.equal (#6707)

This commit is contained in:
Xiaodong Hu 2023-08-22 01:24:52 +09:00 committed by GitHub
parent d8a51aefec
commit 8535e93100
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -83,8 +83,7 @@ See the following example:
in_mem_client = boto3.client("s3") in_mem_client = boto3.client("s3")
buckets = in_mem_client.list_buckets()["Buckets"] buckets = in_mem_client.list_buckets()["Buckets"]
[b["Name"] for b in buckets].should.equal(["test"]) self.assertEqual([b["Name"] for b in buckets], ["test"])
This example shows it is possible to create state using the TreadedMotoServer, and access that state using the usual decorators. :raw-html:`<br />` This example shows it is possible to create state using the TreadedMotoServer, and access that state using the usual decorators. :raw-html:`<br />`
Note that the decorators will destroy any resources on start, so make sure to not accidentally destroy any resources created by the ThreadedMotoServer that should be kept. Note that the decorators will destroy any resources on start, so make sure to not accidentally destroy any resources created by the ThreadedMotoServer that should be kept.