Simplify some code and format some tests better

This commit is contained in:
w0rp
2017-04-24 21:11:27 +01:00
parent 689921d7e3
commit 99afe586b3
8 changed files with 195 additions and 245 deletions

View File

@@ -1,8 +1,18 @@
Execute(The Rust handler should handle rustc output):
AssertEqual
\ [
\ {'lnum': 15, 'bufnr': 347, 'vcol': 0, 'nr': -1, 'type': 'E', 'col': 418, 'text': 'expected one of `.`, `;`, `?`, `}`, or an operator, found `for`'},
\ {'lnum': 13, 'bufnr': 347, 'vcol': 0, 'nr': -1, 'type': 'E', 'col': 407, 'text': 'no method named `wat` found for type `std::string::String` in the current scope'},
\ {
\ 'lnum': 15,
\ 'type': 'E',
\ 'col': 418,
\ 'text': 'expected one of `.`, `;`, `?`, `}`, or an operator, found `for`',
\ },
\ {
\ 'lnum': 13,
\ 'type': 'E',
\ 'col': 407,
\ 'text': 'no method named `wat` found for type `std::string::String` in the current scope',
\ },
\ ],
\ ale#handlers#rust#HandleRustErrorsForFile(347, 'src/playpen.rs', [
\ '',
@@ -16,8 +26,18 @@ Execute(The Rust handler should handle rustc output):
Execute(The Rust handler should handle cargo output):
AssertEqual
\ [
\ {'lnum': 15, 'bufnr': 347, 'vcol': 0, 'nr': -1, 'type': 'E', 'col': 11505, 'text': 'expected one of `.`, `;`, `?`, `}`, or an operator, found `for`'},
\ {'lnum': 13, 'bufnr': 347, 'vcol': 0, 'nr': -1, 'type': 'E', 'col': 11494, 'text': 'no method named `wat` found for type `std::string::String` in the current scope'},
\ {
\ 'lnum': 15,
\ 'type': 'E',
\ 'col': 11505,
\ 'text': 'expected one of `.`, `;`, `?`, `}`, or an operator, found `for`',
\ },
\ {
\ 'lnum': 13,
\ 'type': 'E',
\ 'col': 11494,
\ 'text': 'no method named `wat` found for type `std::string::String` in the current scope',
\ },
\ ],
\ ale#handlers#rust#HandleRustErrorsForFile(347, 'src/playpen.rs', [
\ '',