forked from aniani/vim
patch 7.4.2095
Problem: Man test fails when run with the GUI. Solution: Adjust for different behavior of GUI. Add assert_inrange().
This commit is contained in:
@@ -1,4 +1,4 @@
|
||||
*eval.txt* For Vim version 7.4. Last change: 2016 Jul 22
|
||||
*eval.txt* For Vim version 7.4. Last change: 2016 Jul 23
|
||||
|
||||
|
||||
VIM REFERENCE MANUAL by Bram Moolenaar
|
||||
@@ -1947,6 +1947,8 @@ assert_equal({exp}, {act} [, {msg}]) none assert {exp} is equal to {act}
|
||||
assert_exception({error} [, {msg}]) none assert {error} is in v:exception
|
||||
assert_fails({cmd} [, {error}]) none assert {cmd} fails
|
||||
assert_false({actual} [, {msg}]) none assert {actual} is false
|
||||
assert_inrange({lower}, {upper}, {actual} [, {msg}])
|
||||
none assert {actual} is inside the range
|
||||
assert_match({pat}, {text} [, {msg}]) none assert {pat} matches {text}
|
||||
assert_notequal({exp}, {act} [, {msg}]) none assert {exp} is not equal {act}
|
||||
assert_notmatch({pat}, {text} [, {msg}]) none assert {pat} not matches {text}
|
||||
@@ -2478,8 +2480,16 @@ assert_false({actual} [, {msg}]) *assert_false()*
|
||||
|v:errors|, like with |assert_equal()|.
|
||||
A value is false when it is zero. When {actual} is not a
|
||||
number the assert fails.
|
||||
When {msg} is omitted an error in the form "Expected False but
|
||||
got {actual}" is produced.
|
||||
When {msg} is omitted an error in the form
|
||||
"Expected False but got {actual}" is produced.
|
||||
|
||||
assert_inrange({lower}, {upper}, {actual} [, {msg}]) *assert_inrange()*
|
||||
This asserts number values. When {actual} is lower than
|
||||
{lower} or higher than {upper} an error message is added to
|
||||
|v:errors|.
|
||||
When {msg} is omitted an error in the form
|
||||
"Expected range {lower} - {upper}, but got {actual}" is
|
||||
produced.
|
||||
|
||||
*assert_match()*
|
||||
assert_match({pattern}, {actual} [, {msg}])
|
||||
@@ -2494,8 +2504,8 @@ assert_match({pattern}, {actual} [, {msg}])
|
||||
Use "^" and "$" to match with the start and end of the text.
|
||||
Use both to match the whole text.
|
||||
|
||||
When {msg} is omitted an error in the form "Pattern {pattern}
|
||||
does not match {actual}" is produced.
|
||||
When {msg} is omitted an error in the form
|
||||
"Pattern {pattern} does not match {actual}" is produced.
|
||||
Example: >
|
||||
assert_match('^f.*o$', 'foobar')
|
||||
< Will result in a string to be added to |v:errors|:
|
||||
|
||||
Reference in New Issue
Block a user