view src/testdir/test_crypt.vim @ 10231:cbee14cc4da6 v8.0.0014

commit https://github.com/vim/vim/commit/1eceadaf481e34ed8155011534159775697ce884 Author: Bram Moolenaar <Bram@vim.org> Date: Mon Sep 26 20:14:56 2016 +0200 patch 8.0.0014 Problem: Crypt tests are old style. Solution: Convert to new style.
author Christian Brabandt <cb@256bit.org>
date Mon, 26 Sep 2016 20:30:04 +0200
parents 820fe7530856
children ebbc8d21105b
line wrap: on
line source

" Tests for encryption.

if !has('cryptv')
  finish
endif

func Common_head_only(text)
  " This was crashing Vim
  split Xtest.txt
  call setline(1, a:text)
  wq
  call feedkeys(":split Xtest.txt\<CR>foobar\<CR>", "tx")
  call delete('Xtest.txt')
  call assert_match('VimCrypt', getline(1))
  bwipe!
endfunc

func Test_head_only_2()
  call Common_head_only('VimCrypt~02!abc')
endfunc

func Test_head_only_3()
  call Common_head_only('VimCrypt~03!abc')
endfunc