Skip to content
Projeler
Gruplar
Parçacıklar
Yardım
Yükleniyor...
Oturum aç / Kaydol
Gezinmeyi değiştir
C
cpython
Proje
Proje
Ayrıntılar
Etkinlik
Cycle Analytics
Depo (repository)
Depo (repository)
Dosyalar
Kayıtlar (commit)
Dallar (branch)
Etiketler
Katkıda bulunanlar
Grafik
Karşılaştır
Grafikler
Konular (issue)
0
Konular (issue)
0
Liste
Pano
Etiketler
Kilometre Taşları
Birleştirme (merge) Talepleri
0
Birleştirme (merge) Talepleri
0
CI / CD
CI / CD
İş akışları (pipeline)
İşler
Zamanlamalar
Grafikler
Paketler
Paketler
Wiki
Wiki
Parçacıklar
Parçacıklar
Üyeler
Üyeler
Collapse sidebar
Close sidebar
Etkinlik
Grafik
Grafikler
Yeni bir konu (issue) oluştur
İşler
Kayıtlar (commit)
Konu (issue) Panoları
Kenar çubuğunu aç
Batuhan Osman TASKAYA
cpython
Commits
c4e78b11
Kaydet (Commit)
c4e78b11
authored
May 02, 2019
tarafından
Zackery Spytz
Kaydeden (comit)
Serhiy Storchaka
May 02, 2019
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
bpo-14546: Fix the argument handling in Tools/scripts/lll.py (GH-13026)
üst
0d5864fa
Hide whitespace changes
Inline
Side-by-side
Showing
3 changed files
with
42 additions
and
4 deletions
+42
-4
test_lll.py
Lib/test/test_tools/test_lll.py
+38
-0
2019-04-30-14-30-29.bpo-14546.r38Y-6.rst
...next/Tools-Demos/2019-04-30-14-30-29.bpo-14546.r38Y-6.rst
+1
-0
lll.py
Tools/scripts/lll.py
+3
-4
No files found.
Lib/test/test_tools/test_lll.py
0 → 100644
Dosyayı görüntüle @
c4e78b11
"""Tests for the lll script in the Tools/script directory."""
import
os
import
tempfile
from
test
import
support
from
test.test_tools
import
skip_if_missing
,
import_tool
import
unittest
skip_if_missing
()
class
lllTests
(
unittest
.
TestCase
):
def
setUp
(
self
):
self
.
lll
=
import_tool
(
'lll'
)
def
test_lll_multiple_dirs
(
self
):
with
tempfile
.
TemporaryDirectory
()
as
dir1
,
\
tempfile
.
TemporaryDirectory
()
as
dir2
:
fn1
=
os
.
path
.
join
(
dir1
,
'foo1'
)
fn2
=
os
.
path
.
join
(
dir2
,
'foo2'
)
for
fn
,
dir
in
(
fn1
,
dir1
),
(
fn2
,
dir2
):
open
(
fn
,
'w'
)
.
close
()
os
.
symlink
(
fn
,
os
.
path
.
join
(
dir
,
'symlink'
))
with
support
.
captured_stdout
()
as
output
:
self
.
lll
.
main
([
dir1
,
dir2
])
self
.
assertEqual
(
output
.
getvalue
(),
f
'{dir1}:
\n
'
f
'symlink -> {fn1}
\n
'
f
'
\n
'
f
'{dir2}:
\n
'
f
'symlink -> {fn2}
\n
'
)
if
__name__
==
'__main__'
:
unittest
.
main
()
Misc/NEWS.d/next/Tools-Demos/2019-04-30-14-30-29.bpo-14546.r38Y-6.rst
0 → 100644
Dosyayı görüntüle @
c4e78b11
Fix the argument handling in Tools/scripts/lll.py.
Tools/scripts/lll.py
Dosyayı görüntüle @
c4e78b11
...
@@ -13,8 +13,7 @@ def lll(dirname):
...
@@ -13,8 +13,7 @@ def lll(dirname):
full
=
os
.
path
.
join
(
dirname
,
name
)
full
=
os
.
path
.
join
(
dirname
,
name
)
if
os
.
path
.
islink
(
full
):
if
os
.
path
.
islink
(
full
):
print
(
name
,
'->'
,
os
.
readlink
(
full
))
print
(
name
,
'->'
,
os
.
readlink
(
full
))
def
main
():
def
main
(
args
):
args
=
sys
.
argv
[
1
:]
if
not
args
:
args
=
[
os
.
curdir
]
if
not
args
:
args
=
[
os
.
curdir
]
first
=
1
first
=
1
for
arg
in
args
:
for
arg
in
args
:
...
@@ -22,7 +21,7 @@ def main():
...
@@ -22,7 +21,7 @@ def main():
if
not
first
:
print
()
if
not
first
:
print
()
first
=
0
first
=
0
print
(
arg
+
':'
)
print
(
arg
+
':'
)
lll
(
arg
)
lll
(
arg
)
if
__name__
==
'__main__'
:
if
__name__
==
'__main__'
:
main
()
main
(
sys
.
argv
[
1
:]
)
Write
Preview
Markdown
is supported
0%
Try again
or
attach a new file
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment