summaryrefslogtreecommitdiff
path: root/test
diff options
context:
space:
mode:
authorIan2020 <Ian2020@users.noreply.github.com>2020-04-28 18:20:10 +0100
committerIan2020 <Ian2020@users.noreply.github.com>2020-04-28 18:20:10 +0100
commitf67cb56e5e73f00da643b050bfb6ab6e4416c5a2 (patch)
tree71e0504cb0b6c5762b8faee919352336d031811b /test
parent3f3426515107ae62b2e0d158ab192fcec95cfd10 (diff)
downloadale-f67cb56e5e73f00da643b050bfb6ab6e4416c5a2.zip
Fix shell detection test, shellcheck function name has changed
Diffstat (limited to 'test')
-rw-r--r--test/test_shell_detection.vader28
1 files changed, 14 insertions, 14 deletions
diff --git a/test/test_shell_detection.vader b/test/test_shell_detection.vader
index 88ee462d..6452287f 100644
--- a/test/test_shell_detection.vader
+++ b/test/test_shell_detection.vader
@@ -15,7 +15,7 @@ Given(A file with a Bash hashbang):
Execute(/bin/bash should be detected appropriately):
AssertEqual 'bash', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'bash', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'bash', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'bash', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with /bin/sh):
#!/usr/bin/env sh -eu --foobar
@@ -23,7 +23,7 @@ Given(A file with /bin/sh):
Execute(/bin/sh should be detected appropriately):
AssertEqual 'sh', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'sh', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'sh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'sh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with bash as an argument to env):
#!/usr/bin/env bash
@@ -31,7 +31,7 @@ Given(A file with bash as an argument to env):
Execute(/usr/bin/env bash should be detected appropriately):
AssertEqual 'bash', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'bash', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'bash', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'bash', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with a tcsh hash bang and arguments):
#!/usr/bin/env tcsh -eu --foobar
@@ -39,7 +39,7 @@ Given(A file with a tcsh hash bang and arguments):
Execute(tcsh should be detected appropriately):
AssertEqual 'tcsh', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'tcsh', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'tcsh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'tcsh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with a zsh hash bang and arguments):
#!/usr/bin/env zsh -eu --foobar
@@ -47,7 +47,7 @@ Given(A file with a zsh hash bang and arguments):
Execute(zsh should be detected appropriately):
AssertEqual 'zsh', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'zsh', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'zsh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'zsh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with a csh hash bang and arguments):
#!/usr/bin/env csh -eu --foobar
@@ -55,7 +55,7 @@ Given(A file with a csh hash bang and arguments):
Execute(csh should be detected appropriately):
AssertEqual 'csh', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'csh', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'csh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'csh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with a ksh hashbang):
#!/bin/ksh
@@ -63,7 +63,7 @@ Given(A file with a ksh hashbang):
Execute(/bin/ksh should be detected appropriately):
AssertEqual 'ksh', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'ksh', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'ksh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'ksh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with a ksh as an argument to env):
#!/usr/bin/env ksh
@@ -71,7 +71,7 @@ Given(A file with a ksh as an argument to env):
Execute(ksh should be detected appropriately):
AssertEqual 'ksh', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'ksh', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'ksh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'ksh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with a sh hash bang and arguments):
#!/usr/bin/env sh -eu --foobar
@@ -79,24 +79,24 @@ Given(A file with a sh hash bang and arguments):
Execute(sh should be detected appropriately):
AssertEqual 'sh', ale#handlers#sh#GetShellType(bufnr(''))
AssertEqual 'sh', ale_linters#sh#shell#GetExecutable(bufnr(''))
- AssertEqual 'sh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'sh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file without a hashbang):
Execute(The bash dialect should be used for shellcheck if b:is_bash is 1):
let b:is_bash = 1
- AssertEqual 'bash', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'bash', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Execute(The sh dialect should be used for shellcheck if b:is_sh is 1):
let b:is_sh = 1
- AssertEqual 'sh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'sh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Execute(The ksh dialect should be used for shellcheck if b:is_kornshell is 1):
let b:is_kornshell = 1
- AssertEqual 'ksh', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'ksh', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with /bin/ash):
#!/bin/ash
@@ -106,7 +106,7 @@ Execute(The ash dialect should be used for the shell and the base function):
AssertEqual 'ash', ale_linters#sh#shell#GetExecutable(bufnr(''))
Execute(dash should be used for shellcheck, which has no ash dialect):
- AssertEqual 'dash', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'dash', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))
Given(A file with /bin/dash):
#!/bin/dash
@@ -116,4 +116,4 @@ Execute(The dash dialect should be used for the shell and the base function):
AssertEqual 'dash', ale_linters#sh#shell#GetExecutable(bufnr(''))
Execute(dash should be used for shellcheck):
- AssertEqual 'dash', ale_linters#sh#shellcheck#GetDialectArgument(bufnr(''))
+ AssertEqual 'dash', ale#handlers#shellcheck#GetDialectArgument(bufnr(''))