File tree Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Expand file tree Collapse file tree 2 files changed +10
-1
lines changed Original file line number Diff line number Diff line change @@ -25,7 +25,7 @@ def _hg_ls_files_and_dirs(toplevel):
25
25
out = subprocess .check_output ([
26
26
'hg' , 'files' ,
27
27
], cwd = toplevel , universal_newlines = True )
28
- for name in out .split ():
28
+ for name in out .splitlines ():
29
29
name = os .path .normcase (name ).replace ('/' , os .path .sep )
30
30
fullname = os .path .join (toplevel , name )
31
31
hg_files .add (fullname )
Original file line number Diff line number Diff line change @@ -51,6 +51,15 @@ def test_basic(inwd):
51
51
})
52
52
53
53
54
+ def test_whitespace (inwd ):
55
+ (inwd .cwd / 'adir' / 'space file' ).ensure (file = True )
56
+ inwd .add_and_commit ()
57
+ assert set (find_files ('adir' )) == _sep ({
58
+ 'adir/space file' ,
59
+ 'adir/filea' ,
60
+ })
61
+
62
+
54
63
def test_case (inwd ):
55
64
(inwd .cwd / 'CamelFile' ).ensure (file = True )
56
65
(inwd .cwd / 'file2' ).ensure (file = True )
You can’t perform that action at this time.
0 commit comments