Mercurial > vim
annotate src/testdir/test_recover.vim @ 12265:03e4be2e3d53 v8.0.1012
patch 8.0.1012: MS-Windows: problem with $HOME when is was set internally
commit https://github.com/vim/vim/commit/48340b62e812dc9280f621a2eb6db76d43555c66
Author: Bram Moolenaar <Bram@vim.org>
Date: Tue Aug 29 22:08:53 2017 +0200
patch 8.0.1012: MS-Windows: problem with $HOME when is was set internally
Problem: MS-Windows: Problem with $HOME when is was set internally.
Solution: Only use the $HOME default internally. (Yasuhiro Matsumoto, closes
#2013)
author | Christian Brabandt <cb@256bit.org> |
---|---|
date | Tue, 29 Aug 2017 22:15:05 +0200 |
parents | 0cafb01af1b6 |
children | 4767939d10cc |
rev | line source |
---|---|
10896
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
1 " Test :recover |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
2 |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
3 func Test_recover_root_dir() |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
4 " This used to access invalid memory. |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
5 split Xtest |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
6 set dir=/ |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
7 call assert_fails('recover', 'E305:') |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
8 close! |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
9 |
11432
0cafb01af1b6
patch 8.0.0600: test_recover fails on some systems
Christian Brabandt <cb@256bit.org>
parents:
10898
diff
changeset
|
10 if has('win32') || filewritable('/') == 2 |
10898
cc3f6ad092c2
patch 8.0.0338: :recover test fails on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
10896
diff
changeset
|
11 " can write in / directory on MS-Windows |
cc3f6ad092c2
patch 8.0.0338: :recover test fails on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
10896
diff
changeset
|
12 set dir=/notexist/ |
cc3f6ad092c2
patch 8.0.0338: :recover test fails on MS-Windows
Christian Brabandt <cb@256bit.org>
parents:
10896
diff
changeset
|
13 endif |
10896
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
14 call assert_fails('split Xtest', 'E303:') |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
15 set dir& |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
16 endfunc |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
17 |
d513b653f5d0
patch 8.0.0337: invalid memory access in :recover command
Christian Brabandt <cb@256bit.org>
parents:
diff
changeset
|
18 " TODO: move recover tests from test78.in to here. |