Sha256: 428d3eaf1969cbd5effb50176ee7a220c921ba4c66fbcbf0f89dadef52c088b0

Contents?: true

Size: 1.06 KB

Versions: 3

Compression:

Stored size: 1.06 KB

Contents

require "bundler/gem_tasks"
require "rspec/core/rake_task"

Bundler.setup

namespace :spec do
  desc "Run functional specs"
  RSpec::Core::RakeTask.new(:functional)

  desc "Run acceptance specs"
  task acceptance: "acceptance:deps" do
    run_script("run_acceptance.rb", "--reporter", "dot", "spec/acceptance")
  end

  namespace :acceptance do
    desc "Install acceptance spec dependencies"
    task :deps do
      sh "vim-flavor update --vimfiles-path=spec/acceptance/runtime"
    end
  end
end

namespace :docs do
  desc "Generate Neovim remote API docs"
  task :generate do
    run_script("generate_docs.rb")
  end
end

namespace :ci do
  task :download_nvim do
    run_script("ci/download_nvim.sh")
  end
end

desc "Run specs"
task spec: [:"spec:functional", :"spec:acceptance"]

task default: :spec

def run_script(relpath, *args)
  path = File.expand_path("script/#{relpath}", __dir__)
  cmd_handler = ->(ok, status) { ok || exit(status.exitstatus) }

  if File.extname(path) == ".rb"
    ruby(path, *args, &cmd_handler)
  else
    sh(path, *args, &cmd_handler)
  end
end

Version data entries

3 entries across 3 versions & 1 rubygems

Version Path
neovim-0.10.0 Rakefile
neovim-0.9.1 Rakefile
neovim-0.9.0 Rakefile