Loren Schlomer
hace 5 años
No se encontró ninguna clave conocida en la base de datos para esta firma
ID de clave GPG: 82E6D9D4AA4CBB83
Se han
modificado 3 ficheros con
20 adiciones y
1 borrados
-
cli/lesspass/core.py
-
cli/test-requirements.txt
-
cli/tests/test_interaction.py
|
|
@@ -52,3 +52,6 @@ def main(args=sys.argv[1:]): |
|
|
|
print("-" * 80) |
|
|
|
else: |
|
|
|
print(generated_password) |
|
|
|
|
|
|
|
if __name__ == '__main__': |
|
|
|
main() |
|
|
@@ -1,4 +1,5 @@ |
|
|
|
tox |
|
|
|
pytest |
|
|
|
flake8 |
|
|
|
mock |
|
|
|
mock |
|
|
|
pexpect |
|
|
@@ -0,0 +1,15 @@ |
|
|
|
import unittest |
|
|
|
import pexpect |
|
|
|
import signal |
|
|
|
import time |
|
|
|
|
|
|
|
class TestInteraction(unittest.TestCase): |
|
|
|
def test_keyboard_interrupt(self): |
|
|
|
|
|
|
|
p = pexpect.spawn('/bin/bash -c "python lesspass/core.py --prompt"') |
|
|
|
time.sleep(1) |
|
|
|
|
|
|
|
p.kill(signal.SIGINT) |
|
|
|
p.expect(pexpect.EOF) |
|
|
|
|
|
|
|
self.assertEqual(p.before, b'Site: ') |