Commit a6b814b4 authored by Rene Saarsoo's avatar Rene Saarsoo
Browse files

Move @readonly spec to separate file.

parent bf6876dc
Loading
Loading
Loading
Loading
+0 −10
Original line number Diff line number Diff line
@@ -39,16 +39,6 @@ describe JsDuck::Aggregator do
    end
  end

  describe "Property with @readonly" do
    before do
      @doc = parse_member("/** @readonly */")
    end

    it "gets readonly attribute" do
      @doc[:readonly].should == true
    end
  end

  describe "method with @template" do
    before do
      @doc = parse_member(<<-EOS)
+22 −0
Original line number Diff line number Diff line
require "mini_parser"

describe JsDuck::Aggregator do
  def parse(string)
    Helper::MiniParser.parse(string)
  end

  def parse_member(string)
    parse(string)["global"][:members][0]
  end

  describe "Property with @readonly" do
    let(:doc) do
      parse_member("/** @readonly */")
    end

    it "gets readonly attribute" do
      doc[:readonly].should == true
    end
  end

end