neovim 0.7.0 → 0.7.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (73) hide show
  1. checksums.yaml +5 -5
  2. data/.gitignore +3 -1
  3. data/.rubocop.yml +118 -0
  4. data/.travis.yml +1 -1
  5. data/CHANGELOG.md +5 -0
  6. data/Rakefile +29 -16
  7. data/VimFlavor +1 -0
  8. data/appveyor.yml +2 -0
  9. data/lib/neovim/api.rb +2 -1
  10. data/lib/neovim/buffer.rb +7 -15
  11. data/lib/neovim/client.rb +3 -3
  12. data/lib/neovim/connection.rb +6 -7
  13. data/lib/neovim/event_loop.rb +3 -3
  14. data/lib/neovim/executable.rb +1 -0
  15. data/lib/neovim/host.rb +12 -12
  16. data/lib/neovim/line_range.rb +16 -16
  17. data/lib/neovim/logging.rb +14 -14
  18. data/lib/neovim/message.rb +7 -7
  19. data/lib/neovim/plugin/dsl.rb +4 -4
  20. data/lib/neovim/plugin/handler.rb +3 -3
  21. data/lib/neovim/remote_object.rb +3 -3
  22. data/lib/neovim/ruby_provider.rb +11 -15
  23. data/lib/neovim/ruby_provider/buffer_ext.rb +1 -0
  24. data/lib/neovim/ruby_provider/vim.rb +14 -2
  25. data/lib/neovim/ruby_provider/window_ext.rb +1 -0
  26. data/lib/neovim/session.rb +7 -10
  27. data/lib/neovim/version.rb +1 -1
  28. data/lib/neovim/window.rb +3 -3
  29. data/neovim.gemspec +5 -4
  30. data/script/{dump_api → dump_api.rb} +0 -0
  31. data/script/{generate_docs → generate_docs.rb} +0 -0
  32. data/script/{j2mp → j2mp.rb} +0 -0
  33. data/script/{mp2j → mp2j.rb} +0 -0
  34. data/script/run_acceptance.rb +35 -0
  35. data/script/validate_docs.rb +29 -0
  36. data/spec/acceptance/rplugin_autocmd_spec.vim +20 -10
  37. data/spec/acceptance/rplugin_command_spec.vim +54 -56
  38. data/spec/acceptance/rplugin_function_spec.vim +28 -22
  39. data/spec/acceptance/ruby_spec.vim +40 -48
  40. data/spec/acceptance/rubydo_spec.vim +40 -52
  41. data/spec/acceptance/rubyfile/nested.rb +1 -1
  42. data/spec/acceptance/rubyfile_spec.vim +57 -63
  43. data/spec/acceptance/runtime/init.vim +4 -3
  44. data/spec/acceptance/runtime/rplugin/ruby/autocmds.rb +6 -2
  45. data/spec/acceptance/runtime/rplugin/ruby/commands.rb +17 -16
  46. data/spec/acceptance/runtime/rplugin/ruby/functions.rb +8 -8
  47. data/spec/helper.rb +2 -2
  48. data/spec/neovim/api_spec.rb +1 -1
  49. data/spec/neovim/client_spec.rb +10 -10
  50. data/spec/neovim/connection_spec.rb +5 -6
  51. data/spec/neovim/current_spec.rb +12 -12
  52. data/spec/neovim/executable_spec.rb +2 -2
  53. data/spec/neovim/host/loader_spec.rb +2 -2
  54. data/spec/neovim/host_spec.rb +7 -7
  55. data/spec/neovim/line_range_spec.rb +16 -16
  56. data/spec/neovim/logging_spec.rb +7 -7
  57. data/spec/neovim/plugin_spec.rb +6 -6
  58. data/spec/neovim/ruby_provider/buffer_ext_spec.rb +2 -2
  59. data/spec/neovim/ruby_provider/vim_spec.rb +4 -4
  60. data/spec/neovim/ruby_provider/window_ext_spec.rb +8 -8
  61. data/spec/neovim/session_spec.rb +8 -8
  62. data/spec/neovim/window_spec.rb +0 -1
  63. metadata +41 -27
  64. data/.gitmodules +0 -3
  65. data/.rspec +0 -1
  66. data/spec/acceptance/runtime/vader.vim/autoload/vader.vim +0 -348
  67. data/spec/acceptance/runtime/vader.vim/autoload/vader/assert.vim +0 -116
  68. data/spec/acceptance/runtime/vader.vim/autoload/vader/helper.vim +0 -43
  69. data/spec/acceptance/runtime/vader.vim/autoload/vader/parser.vim +0 -179
  70. data/spec/acceptance/runtime/vader.vim/autoload/vader/syntax.vim +0 -73
  71. data/spec/acceptance/runtime/vader.vim/autoload/vader/window.vim +0 -205
  72. data/spec/acceptance/runtime/vader.vim/plugin/vader.vim +0 -37
  73. data/spec/acceptance_spec.rb +0 -85
@@ -1,37 +0,0 @@
1
- " Copyright (c) 2015 Junegunn Choi
2
- "
3
- " MIT License
4
- "
5
- " Permission is hereby granted, free of charge, to any person obtaining
6
- " a copy of this software and associated documentation files (the
7
- " "Software"), to deal in the Software without restriction, including
8
- " without limitation the rights to use, copy, modify, merge, publish,
9
- " distribute, sublicense, and/or sell copies of the Software, and to
10
- " permit persons to whom the Software is furnished to do so, subject to
11
- " the following conditions:
12
- "
13
- " The above copyright notice and this permission notice shall be
14
- " included in all copies or substantial portions of the Software.
15
- "
16
- " THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
17
- " EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
18
- " MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND
19
- " NONINFRINGEMENT. IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE
20
- " LIABLE FOR ANY CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION
21
- " OF CONTRACT, TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION
22
- " WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
23
-
24
- if exists('g:loaded_vader') || &compatible
25
- finish
26
- endif
27
- let g:loaded_vader = 1
28
-
29
- function! s:vader(...) range
30
- if a:lastline - a:firstline > 0 && a:0 > 1
31
- echoerr 'Range and file arguments are mutually exclusive'
32
- return
33
- endif
34
- execute printf("%d,%dcall vader#run(%s)", a:firstline, a:lastline, string(a:000)[1:-2])
35
- endfunction
36
-
37
- command! -bang -nargs=* -range -complete=file Vader <line1>,<line2>call s:vader(<bang>0, <f-args>)
@@ -1,85 +0,0 @@
1
- ENV.delete("VIM")
2
- ENV.delete("VIMRUNTIME")
3
-
4
- require "json"
5
- require "net/http"
6
- require "openssl"
7
- require "open-uri"
8
- require "tempfile"
9
-
10
- RSpec.describe "Acceptance", timeout: 10 do
11
- let(:root) { File.expand_path("../acceptance", __FILE__) }
12
- let(:init) { File.join(root, "runtime/init.vim") }
13
- let(:manifest) { File.join(root, "runtime/rplugin.vim") }
14
-
15
- around do |spec|
16
- Dir.chdir(root) { spec.run }
17
- end
18
-
19
- describe "Vim compatibility" do
20
- ["ruby", "rubyfile", "rubydo"].each do |feature|
21
- specify ":#{feature}" do
22
- run_vader("#{feature}_spec.vim") do |status, output|
23
- expect(status).to be_success, -> { output.read }
24
- end
25
- end
26
- end
27
- end
28
-
29
- describe "Remote plugin DSL" do
30
- before do
31
- run_nvim(
32
- {"NVIM_RPLUGIN_MANIFEST" => manifest},
33
- "-c", "silent UpdateRemotePlugins", "-c", "qa!"
34
- )
35
- end
36
-
37
- ["command", "function", "autocmd"].each do |feature|
38
- specify "##{feature}" do
39
- run_vader("rplugin_#{feature}_spec.vim") do |status, output|
40
- expect(status).to be_success, -> { output.read }
41
- end
42
- end
43
- end
44
- end
45
-
46
- describe "Generated documentation" do
47
- it "is up to date" do
48
- url = "https://api.github.com/repos/neovim/neovim/releases/latest"
49
-
50
- begin
51
- response = open(url) { |json| JSON.load(json) }
52
- rescue SocketError, OpenURI::HTTPError, OpenSSL::SSL::SSLError => e
53
- skip "Skipping: #{e}"
54
- end
55
-
56
- release_version = response["name"][/NVIM v?(.+)$/, 1]
57
-
58
- client_file = File.read(
59
- File.expand_path("../../lib/neovim/client.rb", __FILE__)
60
- )
61
- docs_version = client_file[
62
- /The methods documented here were generated using NVIM v?(.+)$/,
63
- 1
64
- ]
65
-
66
- expect(docs_version).to eq(release_version)
67
- end
68
- end
69
-
70
- def run_nvim(env, *opts)
71
- nvim = env.fetch("NVIM_EXECUTABLE", "nvim")
72
- system(env, nvim, "--headless", "-n", "-u", init, *opts)
73
- end
74
-
75
- def run_vader(test_path)
76
- Tempfile.open("vader.out") do |out|
77
- run_nvim(
78
- {"NVIM_RPLUGIN_MANIFEST" => manifest, "VADER_OUTPUT_FILE" => out.path},
79
- "-c", "Vader! #{test_path}"
80
- )
81
-
82
- yield $?, out
83
- end
84
- end
85
- end