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
6738b115
Kaydet (Commit)
6738b115
authored
May 16, 2015
tarafından
Yury Selivanov
Dosyalara gözat
Seçenekler
Dosyalara Gözat
İndir
Eposta Yamaları
Sade Fark
Issue 24208: Fix tests -- don't create a tempdir in __init__.
üst
de12b79c
Hide whitespace changes
Inline
Side-by-side
Showing
1 changed file
with
3 additions
and
5 deletions
+3
-5
test_inspect.py
Lib/test/test_inspect.py
+3
-5
No files found.
Lib/test/test_inspect.py
Dosyayı görüntüle @
6738b115
...
...
@@ -288,9 +288,7 @@ class GetSourceBase(unittest.TestCase):
# Subclasses must override.
fodderModule
=
None
def
__init__
(
self
,
*
args
,
**
kwargs
):
unittest
.
TestCase
.
__init__
(
self
,
*
args
,
**
kwargs
)
def
setUp
(
self
):
with
open
(
inspect
.
getsourcefile
(
self
.
fodderModule
))
as
fp
:
self
.
source
=
fp
.
read
()
...
...
@@ -571,7 +569,7 @@ class TestBuggyCases(GetSourceBase):
self
.
assertSourceEqual
(
mod2
.
ClassWithMethod
.
method
,
118
,
119
)
class
TestNoEOL
(
GetSourceBase
):
def
__init__
(
self
,
*
args
,
**
kwargs
):
def
setUp
(
self
):
self
.
tempdir
=
TESTFN
+
'_dir'
os
.
mkdir
(
self
.
tempdir
)
with
open
(
os
.
path
.
join
(
self
.
tempdir
,
...
...
@@ -580,7 +578,7 @@ class TestNoEOL(GetSourceBase):
with
DirsOnSysPath
(
self
.
tempdir
):
import
inspect_fodder3
as
mod3
self
.
fodderModule
=
mod3
GetSourceBase
.
__init__
(
self
,
*
args
,
**
kwargs
)
super
()
.
setUp
(
)
def
tearDown
(
self
):
shutil
.
rmtree
(
self
.
tempdir
)
...
...
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