@@ -8,7 +8,7 @@ msgstr ""
8
8
"Project-Id-Version : Python 3.12\n "
9
9
"Report-Msgid-Bugs-To : \n "
10
10
"POT-Creation-Date : 2023-09-09 00:03+0000\n "
11
- "PO-Revision-Date : 2024-04-09 00:31 +0800\n "
11
+ "PO-Revision-Date : 2024-05-06 08:22 +0800\n "
12
12
"Last-Translator : Liang-Bo Wang <me@liang2.tw>\n "
13
13
"Language-Team : Chinese - TAIWAN (https://github.com/python/python-docs-zh- "
14
14
"tw)\n "
@@ -17,7 +17,7 @@ msgstr ""
17
17
"Content-Type : text/plain; charset=UTF-8\n "
18
18
"Content-Transfer-Encoding : 8bit\n "
19
19
"Plural-Forms : nplurals=1; plural=0;\n "
20
- "X-Generator : Poedit 3.4.1 \n "
20
+ "X-Generator : Poedit 3.4.2 \n "
21
21
22
22
#: ../../library/unittest.mock-examples.rst:2
23
23
msgid ":mod:`unittest.mock` --- getting started"
@@ -1057,8 +1057,8 @@ msgid ""
1057
1057
"*spec* (or *spec_set*) argument so that the ``MagicMock`` created only has "
1058
1058
"dictionary magic methods available:"
1059
1059
msgstr ""
1060
- "*第三個*\\ 選擇是使用 ``MagicMock``,但傳入 ``dict`` 作為 *spec*(或 "
1061
- "*spec_set*)引數,以使被建立的 ``MagicMock`` 僅具有字典可用的魔術方法:"
1060
+ "*第三個*\\ 選擇是使用 ``MagicMock``,但傳入 ``dict`` 作為 *spec* (或 "
1061
+ "*spec_set*\\ )引數,以使被建立的 ``MagicMock`` 僅具有字典可用的魔術方法:"
1062
1062
1063
1063
#: ../../library/unittest.mock-examples.rst:1034
1064
1064
msgid ""
@@ -1121,7 +1121,7 @@ msgid ""
1121
1121
"signature is that it takes arbitrary keyword arguments (``**kwargs``) which "
1122
1122
"are then passed onto the mock constructor:"
1123
1123
msgstr ""
1124
- "``Mock``(及其各種形式)使用名為 ``_get_child_mock`` 的方法來為屬性和回傳值"
1124
+ "``Mock`` (及其各種形式)使用名為 ``_get_child_mock`` 的方法來為屬性和回傳值"
1125
1125
"建立這些 \" 子 mock\" 。你可以透過置換此方法來防止你的子類別被用為屬性。其簽名"
1126
1126
"是取用任意的關鍵字引數(``**kwargs``\\ ),然後將其傳遞給 mock 建構函式:"
1127
1127
@@ -1280,8 +1280,8 @@ msgid ""
1280
1280
"about the order. In this case you can pass ``any_order=True`` to "
1281
1281
"``assert_has_calls``:"
1282
1282
msgstr ""
1283
- "有時可能會對一個 mock 進行多次呼叫,而你只對斷言其中\\ *某些*\\ 呼叫感興趣。你 "
1284
- "甚至可能不關心順序 。在這種情況下,你可以將 ``any_order=True`` 傳遞給 "
1283
+ "有時可能會對一個 mock 進行多次呼叫,而你只對斷言其中\\ *某些*\\ 呼叫感興趣。"
1284
+ "你甚至可能不關心順序 。在這種情況下,你可以將 ``any_order=True`` 傳遞給 "
1285
1285
"``assert_has_calls``:"
1286
1286
1287
1287
#: ../../library/unittest.mock-examples.rst:1271
@@ -1305,8 +1305,8 @@ msgid ""
1305
1305
"attributes of this object then we can create a matcher that will check these "
1306
1306
"attributes for us."
1307
1307
msgstr ""
1308
- "假設我們預期某個物件會被傳進 mock,預設情況下,該 mock 會根據物件識別性 "
1309
- "進行相等比較 (對使用者定義類別的 Python 預設行為)。要使用 :meth:`~Mock."
1308
+ "假設我們預期某個物件會被傳進 mock,預設情況下,該 mock 會根據物件識別性進行相 "
1309
+ "等比較 (對使用者定義類別的 Python 預設行為)。要使用 :meth:`~Mock."
1310
1310
"assert_called_with`,我們需要傳入完全相同的物件。如果我們只對該物件的某些屬性"
1311
1311
"感興趣,那麼我們可以建立一個匹配器來為我們檢查這些屬性。"
1312
1312
@@ -1342,9 +1342,10 @@ msgid ""
1342
1342
"raised:"
1343
1343
msgstr ""
1344
1344
"``Matcher`` 是用我們想要比較的 ``Foo`` 物件和比較函式實例化的。在 "
1345
- "``assert_called_with`` 中,``Matcher`` 相等方法將被呼叫,它將呼叫 mock 時傳入的物件"
1346
- "與我們建立匹配器時傳入的物件進行比較。如果它們匹配,則 ``assert_called_with`` 會通"
1347
- "過,如果它們不匹配,則會引發 :exc:`AssertionError`:"
1345
+ "``assert_called_with`` 中,``Matcher`` 相等方法將被呼叫,它將呼叫 mock 時傳入"
1346
+ "的物件與我們建立匹配器時傳入的物件進行比較。如果它們匹配,則 "
1347
+ "``assert_called_with`` 會通過,如果它們不匹配,則會引發 :exc:"
1348
+ "`AssertionError`:"
1348
1349
1349
1350
#: ../../library/unittest.mock-examples.rst:1339
1350
1351
msgid ""
@@ -1363,7 +1364,7 @@ msgid ""
1363
1364
"integration/#module-hamcrest.library.integration.match_equality>`_)."
1364
1365
msgstr ""
1365
1366
"從版本 1.5 開始,Python 測試函式庫 `PyHamcrest <https://pyhamcrest."
1366
- "readthedocs.io/>`_ 以其相等匹配器的形式,提供了類似的功能,在這裡可能是有用的 "
1367
- "(\\ `hamcrest.library.integration.match_equality <https://pyhamcrest."
1367
+ "readthedocs.io/>`_ 以其相等匹配器的形式,提供了類似的功能,在這裡可能是有用 "
1368
+ "的 (\\ `hamcrest.library.integration.match_equality <https://pyhamcrest."
1368
1369
"readthedocs.io/en/release-1.8/integration/#module-hamcrest.library."
1369
1370
"integration.match_equality>`_\\ )。"
0 commit comments