view src/testdir/test_charsearch_utf8.vim @ 32659:4e2d73ee7350 v9.0.1661

patch 9.0.1661: BUCK files are not recognized Commit: https://github.com/vim/vim/commit/b46e0f3263acd99c61df06ee3c4d1f6e0b471bc3 Author: Son Luong Ngoc <sluongng@gmail.com> Date: Sat Jun 24 17:11:04 2023 +0100 patch 9.0.1661: BUCK files are not recognized Problem: BUCK files are not recognized. Solution: Recognize BUCK files as "bzl". (Son Luong Ngoc, closes https://github.com/vim/vim/issues/12564)
author Bram Moolenaar <Bram@vim.org>
date Sat, 24 Jun 2023 18:15:05 +0200
parents f5946a50c931
children 448aef880252
line wrap: on
line source

" Tests for related f{char} and t{char} using utf-8.

" Test for t,f,F,T movement commands
func Test_search_cmds()
  new!
  call setline(1, "・最初から最後まで最強のVimは最高")
  1
  normal! f最
  call assert_equal([0, 1, 4, 0], getpos('.'))
  normal! ;
  call assert_equal([0, 1, 16, 0], getpos('.'))
  normal! 2;
  call assert_equal([0, 1, 43, 0], getpos('.'))
  normal! ,
  call assert_equal([0, 1, 28, 0], getpos('.'))
  call assert_equal('最', getcharsearch().char)
  call setcharsearch({'char' : ''})
  call assert_equal('', getcharsearch().char)
  call assert_beeps('normal ;')
  call assert_equal([0, 1, 28, 0], getpos('.'))
  call assert_beeps('normal ,')
  call assert_equal([0, 1, 28, 0], getpos('.'))
  bw!
endfunc

" vim: shiftwidth=2 sts=2 expandtab