From 1b0937dd894d4ea5d1c66f8037b4e1c4e2b888bd Mon Sep 17 00:00:00 2001 From: Jan Edmund Lazo Date: Mon, 24 May 2021 14:43:47 -0400 Subject: test/old: partial port of patch v8.2.1.0183 Prep for patch v8.2.0511. --- src/nvim/testdir/test_functions.vim | 18 +++++++++++------- 1 file changed, 11 insertions(+), 7 deletions(-) (limited to 'src/nvim/testdir/test_functions.vim') diff --git a/src/nvim/testdir/test_functions.vim b/src/nvim/testdir/test_functions.vim index 85d1bc7076..224ca257ab 100644 --- a/src/nvim/testdir/test_functions.vim +++ b/src/nvim/testdir/test_functions.vim @@ -28,12 +28,14 @@ func Test_empty() call assert_equal(0, empty(1)) call assert_equal(0, empty(-1)) - call assert_equal(1, empty(0.0)) - call assert_equal(1, empty(-0.0)) - call assert_equal(0, empty(1.0)) - call assert_equal(0, empty(-1.0)) - call assert_equal(0, empty(1.0/0.0)) - call assert_equal(0, empty(0.0/0.0)) + if has('float') + call assert_equal(1, empty(0.0)) + call assert_equal(1, empty(-0.0)) + call assert_equal(0, empty(1.0)) + call assert_equal(0, empty(-1.0)) + call assert_equal(0, empty(1.0/0.0)) + call assert_equal(0, empty(0.0/0.0)) + endif call assert_equal(1, empty([])) call assert_equal(0, empty(['a'])) @@ -115,7 +117,9 @@ func Test_strwidth() call assert_fails('call strwidth({->0})', 'E729:') call assert_fails('call strwidth([])', 'E730:') call assert_fails('call strwidth({})', 'E731:') - call assert_fails('call strwidth(1.2)', 'E806:') + if has('float') + call assert_fails('call strwidth(1.2)', 'E806:') + endif endfor set ambiwidth& -- cgit