#17484: add tests for getpass.

Patch by Thomas Fenzl.
This commit is contained in:
R David Murray 2013-04-08 01:48:22 -04:00
parent 7efa3b8242
commit 319d58d599
3 changed files with 3 additions and 1 deletions

View File

@ -40,6 +40,7 @@ def unix_getpass(prompt='Password: ', stream=None):
"""
fd = None
tty = None
passwd = None
try:
# Always try reading and writing directly on the tty first.
fd = os.open('/dev/tty', os.O_RDWR|os.O_NOCTTY)

View File

@ -6,7 +6,7 @@ import unittest
class TestUntestedModules(unittest.TestCase):
def test_untested_modules_can_be_imported(self):
untested = ('bdb', 'encodings', 'formatter', 'getpass', 'imghdr',
untested = ('bdb', 'encodings', 'formatter', 'imghdr',
'keyword', 'macurl2path', 'nturl2path', 'tabnanny')
with support.check_warnings(quiet=True):
for name in untested:

View File

@ -367,6 +367,7 @@ Michael Farrell
Troy J. Farrell
Mark Favas
Boris Feld
Thomas Fenzl
Niels Ferguson
Sebastian Fernandez
Florian Festi