Skip to content

Commit

Permalink
Test a whole help line
Browse files Browse the repository at this point in the history
  • Loading branch information
atugushev committed Feb 16, 2019
1 parent 7818a5d commit 082fabe
Showing 1 changed file with 8 additions and 1 deletion.
9 changes: 8 additions & 1 deletion tests/test_cli.py
Original file line number Diff line number Diff line change
Expand Up @@ -447,5 +447,12 @@ def test_default_index_url():
status, output = _invoke([sys.executable, '-m', 'piptools', 'compile', '--help'])
output = output.decode('utf-8')

# Click's subprocess output has \r\r\n line endings on win py27. Fix it.
output = output.replace('\r\r', '\r')

assert status == 0
assert 'http://example.com' in output
expected = (
' -i, --index-url TEXT Change index URL (defaults to' + os.linesep +
' http://example.com)' + os.linesep
)
assert expected in output

0 comments on commit 082fabe

Please sign in to comment.