summaryrefslogtreecommitdiff
path: root/test/handler
diff options
context:
space:
mode:
authorKarl Bartel <karl42@gmail.com>2019-09-19 20:40:00 +0200
committerw0rp <w0rp@users.noreply.github.com>2019-09-19 19:40:00 +0100
commitdc42c0f948d378557894fa09160d231b795dfca4 (patch)
tree24272669afde852252d220d912a178d410467a23 /test/handler
parent41ed10be4e67c1daf2772d8d59ad338d6d43ce90 (diff)
downloadale-dc42c0f948d378557894fa09160d231b795dfca4.zip
Add support for `solc` Solidity compiler (#2648)
* Add support for `solc` Solidity compiler * Set default value for `solidity_solc_options` * Add test for solc handler
Diffstat (limited to 'test/handler')
-rw-r--r--test/handler/test_solc_handler.vader30
1 files changed, 30 insertions, 0 deletions
diff --git a/test/handler/test_solc_handler.vader b/test/handler/test_solc_handler.vader
new file mode 100644
index 00000000..8c197507
--- /dev/null
+++ b/test/handler/test_solc_handler.vader
@@ -0,0 +1,30 @@
+Before:
+ runtime ale_linters/solidity/solc.vim
+
+After:
+ call ale#linter#Reset()
+
+Execute(Check solc output parsing):
+ AssertEqual
+ \ [
+ \ {
+ \ 'lnum': 40,
+ \ 'col': 48,
+ \ 'text': 'This declaration shadows an existing declaration.',
+ \ 'type': 'W',
+ \ },
+ \ {
+ \ 'lnum': 23,
+ \ 'col': 16,
+ \ 'text': 'Member "getSinleSignature" not found or not visible after argument-dependent lookup in type(contract OneToN).',
+ \ 'type': 'E',
+ \ },
+ \ ],
+ \ ale_linters#solidity#solc#Handle(bufnr(''), [
+ \ 'raiden_contracts/data/source/raiden/Token.sol:40:48: Warning: This declaration shadows an existing declaration.',
+ \ ' function decimals() external view returns (uint8 decimals);',
+ \ ' ^------------^',
+ \ '/home/karl/raiden-contracts/raiden_contracts/data/source/test/OneToNInternalsTest.sol:23:16: Error: Member "getSinleSignature" not found or not visible after argument-dependent lookup in type(contract OneToN).',
+ \ ' return OneToN.getSinleSignature(signatures, i);',
+ \ ' ^----------------------^',
+ \ ])