Merge commit '7f13c9a3c31aa719144ca3afcad7af305dd2f6ed' into Carpetsmoker/relax-cmdline
This commit is contained in:
commit
b20267b57d
@ -133,7 +133,8 @@ class CommandRunner(QObject):
|
|||||||
Yields:
|
Yields:
|
||||||
ParseResult tuples.
|
ParseResult tuples.
|
||||||
"""
|
"""
|
||||||
if not text.strip():
|
text = text.strip().lstrip(':').strip()
|
||||||
|
if not text:
|
||||||
raise cmdexc.NoSuchCommandError("No command given")
|
raise cmdexc.NoSuchCommandError("No command given")
|
||||||
|
|
||||||
if aliases:
|
if aliases:
|
||||||
|
@ -538,6 +538,16 @@ Feature: Various utility commands.
|
|||||||
When I run :message-i "Hello World" (invalid command)
|
When I run :message-i "Hello World" (invalid command)
|
||||||
Then the error "message-i: no such command" should be shown
|
Then the error "message-i: no such command" should be shown
|
||||||
|
|
||||||
|
Scenario: Multiple leading : in command
|
||||||
|
When I run :::::set-cmd-text ::::message-i "Hello World"
|
||||||
|
And I run :command-accept
|
||||||
|
Then the message "Hello World" should be shown
|
||||||
|
|
||||||
|
Scenario: Whitespace in command
|
||||||
|
When I run : : set-cmd-text : : message-i "Hello World"
|
||||||
|
And I run :command-accept
|
||||||
|
Then the message "Hello World" should be shown
|
||||||
|
|
||||||
# We can't run :message-i as startup command, so we use
|
# We can't run :message-i as startup command, so we use
|
||||||
# :set-cmd-text
|
# :set-cmd-text
|
||||||
|
|
||||||
|
Loading…
Reference in New Issue
Block a user