1" Test commands that are not compiled in a :def function
2
3source check.vim
4source vim9.vim
5
6def Test_edit_wildcards()
7  let filename = 'Xtest'
8  edit `=filename`
9  assert_equal('Xtest', bufname())
10
11  let filenr = 123
12  edit Xtest`=filenr`
13  assert_equal('Xtest123', bufname())
14
15  filenr = 77
16  edit `=filename``=filenr`
17  assert_equal('Xtest77', bufname())
18
19  edit X`=filename`xx`=filenr`yy
20  assert_equal('XXtestxx77yy', bufname())
21enddef
22
23def Test_hardcopy_wildcards()
24  CheckUnix
25  CheckFeature postscript
26
27  let outfile = 'print'
28  hardcopy > X`=outfile`.ps
29  assert_true(filereadable('Xprint.ps'))
30
31  delete('Xprint.ps')
32enddef
33
34def Test_syn_include_wildcards()
35  writefile(['syn keyword Found found'], 'Xthemine.vim')
36  let save_rtp = &rtp
37  &rtp = '.'
38
39  let fname = 'mine'
40  syn include @Group Xthe`=fname`.vim
41  assert_match('Found.* contained found', execute('syn list Found'))
42
43  &rtp = save_rtp
44  delete('Xthemine.vim')
45enddef
46
47
48" vim: ts=8 sw=2 sts=2 expandtab tw=80 fdm=marker
49