mirror of
https://github.com/nvbn/thefuck.git
synced 2025-01-18 20:11:17 +00:00
parent
c2df71caed
commit
8e8c80c227
@ -143,7 +143,9 @@ class TestCommand(object):
|
|||||||
([''], None),
|
([''], None),
|
||||||
(['', ''], None),
|
(['', ''], None),
|
||||||
(['ls', '-la'], 'ls -la'),
|
(['ls', '-la'], 'ls -la'),
|
||||||
(['ls'], 'ls')])
|
(['ls'], 'ls'),
|
||||||
|
(['echo \\ '], 'echo \\ '),
|
||||||
|
(['echo \\\n'], 'echo \\\n')])
|
||||||
def test_from_script(self, script, result):
|
def test_from_script(self, script, result):
|
||||||
if result:
|
if result:
|
||||||
assert Command.from_raw_script(script).script == result
|
assert Command.from_raw_script(script).script == result
|
||||||
|
@ -344,4 +344,4 @@ def format_raw_script(raw_script):
|
|||||||
else:
|
else:
|
||||||
script = ' '.join(raw_script)
|
script = ' '.join(raw_script)
|
||||||
|
|
||||||
return script.strip()
|
return script.lstrip()
|
||||||
|
Loading…
x
Reference in New Issue
Block a user