This issue tracker has been migrated to GitHub, and is currently read-only.
For more information, see the GitHub FAQs in the Python's Developer Guide.

classification
Title: test_pathlib should use can_symlink or skip_unless_symlink from test.support
Type: enhancement Stage: resolved
Components: Tests Versions: Python 3.6
process
Status: closed Resolution: fixed
Dependencies: Superseder:
Assigned To: Nosy List: berker.peksag, brett.cannon, pitrou, serhiy.storchaka, vajrasky
Priority: normal Keywords: patch

Created on 2013-11-26 07:03 by vajrasky, last changed 2022-04-11 14:57 by admin. This issue is now closed.

Files
File name Uploaded Description Edit
use_can_symlink_from_test_support.patch vajrasky, 2013-11-26 07:03 review
Pull Requests
URL Status Linked Edit
PR 822 merged ppperry, 2017-03-26 13:51
Messages (7)
msg204456 - (view) Author: Vajrasky Kok (vajrasky) * Date: 2013-11-26 07:03
Right now, Lib/test/test_pathlib.py uses custom checking symbolic link function. But in test.support, we have those functions already (can_symlink and skip_unless_symlink). The only feature that test.support checking symbolic link functions don't have is getting the reason why we don't have symbolic link support. But we can create a separate ticket to add that feature in test.support.

Attached the patch to use can_symlink and skip_unless_symlink. It also removed unnecessary import.
msg204531 - (view) Author: Antoine Pitrou (pitrou) * (Python committer) Date: 2013-11-26 20:35
Mmh... The reason it's like that is that pathlib is originally 2.7-compatible (and I'd like to do a 1.0 release on PyPI by the Python 3.4 timeframe). How about we defer this to Python 3.5, to make merging easier ?
msg204560 - (view) Author: Vajrasky Kok (vajrasky) * Date: 2013-11-27 07:07
> How about we defer this to Python 3.5, to make merging easier ?

Sure.
msg290512 - (view) Author: Serhiy Storchaka (serhiy.storchaka) * (Python committer) Date: 2017-03-26 07:08
Can you create a pull request on GitHub Vajrasky?
msg290514 - (view) Author: Vajrasky Kok (vajrasky) * Date: 2017-03-26 08:00
Okay, Serhiy. I'll create a pull request.
msg290523 - (view) Author: Vajrasky Kok (vajrasky) * Date: 2017-03-26 10:45
Okay, this is the pull request: https://github.com/python/cpython/pull/822
msg290752 - (view) Author: Brett Cannon (brett.cannon) * (Python committer) Date: 2017-03-28 19:32
New changeset ec1f5df46ed37aa3e839d20298c4b361a9a74bc4 by Brett Cannon (Vajrasky Kok) in branch 'master':
bpo-19791: Use functions from test support to check the symlink support. (GH-822)
https://github.com/python/cpython/commit/ec1f5df46ed37aa3e839d20298c4b361a9a74bc4
History
Date User Action Args
2022-04-11 14:57:54adminsetgithub: 63990
2017-03-28 19:33:28brett.cannonsetstatus: open -> closed
resolution: fixed
stage: patch review -> resolved
2017-03-28 19:32:38brett.cannonsetnosy: + brett.cannon
messages: + msg290752
2017-03-26 13:51:56ppperrysetpull_requests: + pull_request729
2017-03-26 10:45:53vajraskysetmessages: + msg290523
2017-03-26 08:00:49vajraskysetmessages: + msg290514
2017-03-26 07:08:44serhiy.storchakasetnosy: + serhiy.storchaka
messages: + msg290512
2016-04-16 20:37:09berker.peksagsetnosy: + berker.peksag
stage: patch review
type: behavior -> enhancement

versions: + Python 3.6, - Python 3.5
2013-11-27 07:07:10vajraskysetmessages: + msg204560
versions: + Python 3.5, - Python 3.4
2013-11-26 20:35:17pitrousetmessages: + msg204531
2013-11-26 07:03:08vajraskycreate