Skip to content

Commit

Permalink
Prep tests for when SkipIf get merged into vader.vim
Browse files Browse the repository at this point in the history
I've just made a test run of the PR on vader.vim that adds two new
blocks that makes some tests skippable and it does work! The PR is
incomplete though and it's hard to tell when/if it'll ever get merged.

Nonetheless I'll keep the working test syntax if it can ever come in
hand. The best thing though would be if were able to fix the plugin's
filetype detection for vim, thus removing the need to skip tests.
  • Loading branch information
lelutin committed Aug 29, 2024
1 parent 86d5c8a commit a3ffb8e
Showing 1 changed file with 18 additions and 2 deletions.
20 changes: 18 additions & 2 deletions test/filetype/epuppet.vader
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,17 @@ Execute (epuppet test_with_leading_tag):
edit test/test-files/test_with_leading_tag.epp
AssertEqual &filetype, 'epuppet'

# TODO: this is passing for nvim but not vim
# If/when https://github.com/junegunn/vader.vim/pull/201 gets merged into
# vader.vim, we can use the following to skip the test on vim -- until we
# actually fix the filetype detection.
# Until SkipIf gets merged, though we need to keep the test commented out to
# avoid useless CI failure unrelated to other changes
#Given:
#
#SkipIf (ftdetect/puppet.vim is unable to match filetype with content header):
# if !has('nvim')
# VaderSkip
# endif
#Execute (epuppet perl with shebang):
# edit test/test-files/test_perl_with_shebang.epp
# AssertEqual &filetype, 'epuppet'
Expand All @@ -28,7 +38,13 @@ Execute (epuppet php with extension):
AssertEqual &filetype, 'epuppet'
AssertEqual b:epuppet_subtype, 'php'

# TODO: this is passing for nvim but not vim
# Same as above
#Given:
#
#SkipIf (ftdetect/puppet.vim is unable match filetype by path):
# if !has('nvim')
# VaderSkip
# endif
#Execute (epuppet apache conf with path and extension):
# edit test/test-files/etc/apache2/test.conf.epp
# AssertEqual &filetype, 'epuppet'
Expand Down

0 comments on commit a3ffb8e

Please sign in to comment.