Sha256: b6acf53ae89a94c76227782130c036adf9712d0e5c57f28f5929b11cfae8a8b5

Contents?: true

Size: 602 Bytes

Versions: 21

Compression:

Stored size: 602 Bytes

Contents

# frozen_string_literal: true

RSpec.describe YARD::Server do
  describe ".register_static_path" do
    it "registers a static path" do
      YARD::Server.register_static_path 'foo'
      expect(YARD::Server::Commands::StaticFileCommand::STATIC_PATHS.last).to eq "foo"
    end

    it "does not duplicate paths" do
      paths = YARD::Server::Commands::StaticFileCommand::STATIC_PATHS
      count = paths.size
      YARD::Server.register_static_path 'foo2'
      YARD::Server.register_static_path 'foo2'
      expect(paths.size).to eq(count + 1)
      expect(paths.last).to eq 'foo2'
    end
  end
end

Version data entries

21 entries across 20 versions & 4 rubygems

Version Path
yard-0.9.24 spec/server_spec.rb
yard-0.9.23 spec/server_spec.rb
yard-0.9.22 spec/server_spec.rb
yard-0.9.21 spec/server_spec.rb
yard-0.9.20 spec/server_spec.rb
yard-0.9.19 spec/server_spec.rb
yard-0.9.16 spec/server_spec.rb
yard-0.9.15 spec/server_spec.rb
yard-0.9.14 spec/server_spec.rb
yard-0.9.13 spec/server_spec.rb
yard-0.9.12 spec/server_spec.rb
yard-0.9.11 spec/server_spec.rb
yard-0.9.10 spec/server_spec.rb
yard-0.9.9 spec/server_spec.rb
etude_for_ruby-0.1.4 vendor/bundle/ruby/2.4.0/gems/yard-0.9.8/spec/server_spec.rb
etude_for_ruby-0.1.4 vendor/bundle/ruby/2.2.0/gems/yard-0.9.8/spec/server_spec.rb
mdg-1.0.1 vendor/bundle/ruby/2.3.0/gems/yard-0.9.8/spec/server_spec.rb
yard-0.9.8 spec/server_spec.rb
abaci-0.3.0 vendor/bundle/gems/yard-0.9.7/spec/server_spec.rb
yard-0.9.7 spec/server_spec.rb