summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorw0rp <devw0rp@gmail.com>2017-03-06 23:15:28 +0000
committerw0rp <devw0rp@gmail.com>2017-03-06 23:15:34 +0000
commit75a2dc5ff5f1975b1a80b59704ffdfd1902b050f (patch)
tree71d0eea5647cccaceda29757af7ca292c536bfd8 /test
parent70fb1606adbbcfd29ba54b22f9b85fa8e3bd8e64 (diff)
downloadale-75a2dc5ff5f1975b1a80b59704ffdfd1902b050f.zip
Complain loudly when other conflicting plugins are installed
Diffstat (limited to 'test')
-rw-r--r--test/test_conflicting_plugin_warnings.vader70
1 files changed, 70 insertions, 0 deletions
diff --git a/test/test_conflicting_plugin_warnings.vader b/test/test_conflicting_plugin_warnings.vader
new file mode 100644
index 00000000..ebf53c8a
--- /dev/null
+++ b/test/test_conflicting_plugin_warnings.vader
@@ -0,0 +1,70 @@
+Execute(The after file should have been loaded for real):
+ Assert g:loaded_ale_after
+
+Before:
+ silent! cd /testplugin/test
+ cd ..
+ unlet! g:loaded_ale_after
+
+After:
+ cd test
+ let g:loaded_ale_after = 1
+ let g:ale_emit_conflict_warnings = 1
+ unlet! g:loaded_syntastic_plugin
+ unlet! g:loaded_neomake
+ unlet! g:loaded_validator_plugin
+
+Execute(ALE should not warn when nothing extra is installed):
+ " Nothing should be thrown when loading the after file.
+ source after/plugin/ale.vim
+
+Execute(ALE should warn users when Syntastic is installed):
+ let g:loaded_syntastic_plugin = 1
+
+ AssertThrows source after/plugin/ale.vim
+ AssertEqual
+ \ 'ALE conflicts with Syntastic'
+ \ . '. Uninstall it, or disable this warning with '
+ \ . '`let g:ale_emit_conflict_warnings = 0` in your vimrc file, '
+ \ . '*before* plugins are loaded.',
+ \ g:vader_exception
+
+Execute(ALE should not warn about Syntastic when the flag is set):
+ let g:loaded_syntastic_plugin = 1
+ let g:ale_emit_conflict_warnings = 0
+
+ source after/plugin/ale.vim
+
+Execute(ALE should warn users when Neomake is installed):
+ let g:loaded_neomake = 1
+
+ AssertThrows source after/plugin/ale.vim
+ AssertEqual
+ \ 'ALE conflicts with Neomake'
+ \ . '. Uninstall it, or disable this warning with '
+ \ . '`let g:ale_emit_conflict_warnings = 0` in your vimrc file, '
+ \ . '*before* plugins are loaded.',
+ \ g:vader_exception
+
+Execute(ALE should not warn about Neomake when the flag is set):
+ let g:loaded_neomake = 1
+ let g:ale_emit_conflict_warnings = 0
+
+ source after/plugin/ale.vim
+
+Execute(ALE should warn users when Validator is installed):
+ let g:loaded_validator_plugin = 1
+
+ AssertThrows source after/plugin/ale.vim
+ AssertEqual
+ \ 'ALE conflicts with Validator'
+ \ . '. Uninstall it, or disable this warning with '
+ \ . '`let g:ale_emit_conflict_warnings = 0` in your vimrc file, '
+ \ . '*before* plugins are loaded.',
+ \ g:vader_exception
+
+Execute(ALE should not warn about Validator when the flag is set):
+ let g:loaded_validator_plugin = 1
+ let g:ale_emit_conflict_warnings = 0
+
+ source after/plugin/ale.vim