Add test case for --null option

pull/264/head
Junegunn Choi 9 years ago
parent 81ffde92fb
commit 45a3655eaf

@ -536,6 +536,13 @@ class TestGoFZF < TestBase
ensure
File.unlink tempname
end
def test_null
lines = `find .`.split($/)
assert_equal lines.last, `find . | #{FZF} -e -f "^#{lines.last}$"`.chomp
assert_equal lines.last, `find . -print0 | #{FZF} --null -e -f "^#{lines.last}$"`.chomp
end
private
def writelines path, lines
File.unlink path while File.exists? path

Loading…
Cancel
Save