Added fix for bug #774917.

This commit is contained in:
rygwdn@gmail.com 2011-05-02 14:56:27 -03:00
parent e566419c91
commit cd375f976c
2 changed files with 6 additions and 6 deletions

View File

@ -966,7 +966,7 @@ class SnippetManager(object):
) )
try: try:
rv = vim.eval("inputlist(%s)" % display) rv = vim.eval("inputlist([%s])" % vim_string(display))
if rv is None or rv == '0': if rv is None or rv == '0':
return None return None
rv = int(rv) rv = int(rv)

10
test.py
View File

@ -1858,29 +1858,29 @@ class MultiWord_SnippetOptions_ExpandWordSnippets_ExpandSuffix(
# Test for Bug #774917 # Test for Bug #774917
def _snip_quote(qt): def _snip_quote(qt):
return ( return (
("te" + qt + "st", "Expand me!", ""), ("te" + qt + "st", "Expand me" + qt + "!", "test: "+qt),
("te", "Bad", ""), ("te", "Bad", ""),
) )
class Snippet_With_SingleQuote(_VimTest): class Snippet_With_SingleQuote(_VimTest):
snippets = _snip_quote("'") snippets = _snip_quote("'")
keys = "te'st" + EX keys = "te'st" + EX
wanted = "Expand me!" wanted = "Expand me'!"
class Snippet_With_SingleQuote_List(_VimTest): class Snippet_With_SingleQuote_List(_VimTest):
snippets = _snip_quote("'") snippets = _snip_quote("'")
keys = "te" + LS + "1\n" keys = "te" + LS + "1\n"
wanted = "Expand me!" wanted = "Expand me'!"
class Snippet_With_DoubleQuote(_VimTest): class Snippet_With_DoubleQuote(_VimTest):
snippets = _snip_quote('"') snippets = _snip_quote('"')
keys = 'te"st' + EX keys = 'te"st' + EX
wanted = "Expand me!" wanted = "Expand me\"!"
class Snippet_With_DoubleQuote_List(_VimTest): class Snippet_With_DoubleQuote_List(_VimTest):
snippets = _snip_quote('"') snippets = _snip_quote('"')
keys = "te" + LS + "1\n" keys = "te" + LS + "1\n"
wanted = "Expand me!" wanted = "Expand me\"!"
###################### ######################
# SELECTING MULTIPLE # # SELECTING MULTIPLE #