install.fairie/dotfiles/.vim/plugged/ale/test/completion/test_completion_prefixes.vader
Git E2E Dev Test Username e149692cc9 git subrepo clone https://github.com/dense-analysis/ale.git ./dotfiles/.vim/plugged/ale
subrepo:
  subdir:   "dotfiles/.vim/plugged/ale"
  merged:   "e4b205440"
upstream:
  origin:   "https://github.com/dense-analysis/ale.git"
  branch:   "master"
  commit:   "e4b205440"
git-subrepo:
  version:  "0.4.3"
  origin:   "???"
  commit:   "???"
2022-10-18 10:37:09 -04:00

65 lines
2.2 KiB
Text

Given typescript():
let abc = y.
let foo = ab
let foo = (ab)
let string1 = '
let string2 = "
Execute(Completion should be done after dots in TypeScript):
AssertEqual '.', ale#completion#GetPrefix(&filetype, 1, 13)
Execute(Completion should be done after words in TypeScript):
AssertEqual 'ab', ale#completion#GetPrefix(&filetype, 2, 13)
Execute(Completion should be done after words in parens in TypeScript):
AssertEqual 'ab', ale#completion#GetPrefix(&filetype, 3, 14)
Execute(Completion should not be done after parens in TypeScript):
AssertEqual '', ale#completion#GetPrefix(&filetype, 3, 15)
Execute(Completion should be done after strings in TypeScript):
AssertEqual '''', ale#completion#GetPrefix(&filetype, 4, 16)
AssertEqual '"', ale#completion#GetPrefix(&filetype, 5, 16)
Execute(Completion prefixes should work for other filetypes):
AssertEqual 'ab', ale#completion#GetPrefix('xxxyyyzzz', 3, 14)
Execute(Completion prefixes should work for other filetypes):
AssertEqual 'ab', ale#completion#GetPrefix('xxxyyyzzz', 3, 14)
Given rust():
let abc = y.
let abc = String::
let foo = (ab)
Execute(Completion should be done after dots in Rust):
AssertEqual '.', ale#completion#GetPrefix(&filetype, 1, 13)
Execute(Completion should be done after colons in Rust):
AssertEqual '::', ale#completion#GetPrefix(&filetype, 2, 19)
Execute(Completion should be done after words in parens in Rust):
AssertEqual 'ab', ale#completion#GetPrefix(&filetype, 3, 14)
Execute(Completion should not be done after parens in Rust):
AssertEqual '', ale#completion#GetPrefix(&filetype, 3, 15)
Given lisp():
(minus-name
(full-name)
Execute(Completion should be done for function names with minuses in Lisp):
AssertEqual 'minus-name', ale#completion#GetPrefix(&filetype, 1, 12)
Execute(Completion should not be done after parens in Lisp):
AssertEqual '', ale#completion#GetPrefix(&filetype, 2, 12)
Given clojure():
(minus-name
(full-name)
Execute(Completion should be done for function names with minuses in Clojure):
AssertEqual 'minus-name', ale#completion#GetPrefix(&filetype, 1, 12)
Execute(Completion should not be done after parens in Clojure):
AssertEqual '', ale#completion#GetPrefix(&filetype, 2, 12)