From a42999a639b2916b769a85f37d037be314d9d61b Mon Sep 17 00:00:00 2001 From: w0rp Date: Sun, 15 Jul 2018 18:24:53 +0100 Subject: Massively reduce the amount of code needed for linter tests --- test/command_callback/test_fsc_command_callback.vader | 12 ++++-------- 1 file changed, 4 insertions(+), 8 deletions(-) (limited to 'test/command_callback/test_fsc_command_callback.vader') diff --git a/test/command_callback/test_fsc_command_callback.vader b/test/command_callback/test_fsc_command_callback.vader index 451fa108..5fb5e7fa 100644 --- a/test/command_callback/test_fsc_command_callback.vader +++ b/test/command_callback/test_fsc_command_callback.vader @@ -1,17 +1,13 @@ Before: - runtime ale_linters/scala/fsc.vim + call ale#assert#SetUpLinterTest('scala', 'fsc') After: - call ale#linter#Reset() + call ale#assert#TearDownLinterTest() Given scala(An empty Scala file): Execute(The default executable and command should be correct): - AssertEqual 'fsc', ale_linters#scala#fsc#GetExecutable(bufnr('')) - AssertEqual - \ ale#Escape('fsc') . ' -Ystop-after:parser %t', - \ ale_linters#scala#fsc#GetCommand(bufnr('')) + AssertLinter 'fsc', ale#Escape('fsc') . ' -Ystop-after:parser %t' Given scala.sbt(An empty SBT file): Execute(fsc should not be run for sbt files): - AssertEqual '', ale_linters#scala#fsc#GetExecutable(bufnr('')) - AssertEqual '', ale_linters#scala#fsc#GetCommand(bufnr('')) + AssertLinter '', '' -- cgit v1.2.3