Changeset 139:be5626eee037 for livetest.py
- Timestamp:
- 17/03/10 02:10:37 (2 years ago)
- Branch:
- default
- Files:
-
- 1 modified
-
livetest.py (modified) (2 diffs)
Legend:
- Unmodified
- Added
- Removed
-
livetest.py
r138 r139 330 330 None, None, None, 331 331 '<1A472770E042064698CB5ADC83A12ACD39455AAB@ABC>') 332 332 333 334 def test_partial_fetch(client): 335 clear_folder(client, 'INBOX') 336 client.append('INBOX', MULTIPART_MESSAGE) 337 client.select_folder('INBOX') 338 msg_id = client.search()[0] 339 340 resp = client.fetch(msg_id, ['BODY[]<0.20>']) 341 body = resp[msg_id]['BODY[]<0>'] 342 assert len(body) == 20 343 assert body.startswith('From: Bob Smith') 344 345 resp = client.fetch(msg_id, ['BODY[]<2.25>']) 346 body = resp[msg_id]['BODY[]<2>'] 347 assert len(body) == 25 348 assert body.startswith('om: Bob Smith') 349 333 350 334 351 def assert_raises(exception_class, func, *args, **kwargs): … … 357 374 test_search(client) 358 375 test_fetch(client) 376 test_partial_fetch(client) 359 377 test_copy(client) 360 378
