Sha256: 5aa5500eacc93d68f6b4e28e11f2be81a7bee0c55f2e506ddb5c88a85ab15762

Contents?: true

Size: 491 Bytes

Versions: 9

Compression:

Stored size: 491 Bytes

Contents

require "spec_helper"

Snuffle::Node.class_variable_set(:@@objects, [])

describe Snuffle::Node do

  let(:source)  { Snuffle::SourceFile.new }
  let(:parent)  { Snuffle::Node.new(id: 1, parent_id: :root, type: :hash) }
  let(:child_1) { Snuffle::Node.new(id: 2, parent_id: 1, type: :hash) }
  let(:child_2) { Snuffle::Node.new(id: 3, parent_id: 1, type: :hash) }

  describe ".nil" do
    it "returns a default object" do
      expect(Snuffle::Node.nil.type).to eq(:nil)
    end
  end

end

Version data entries

9 entries across 9 versions & 1 rubygems

Version Path
snuffle-0.14.2 spec/snuffle/node_spec.rb
snuffle-0.14.1 spec/snuffle/node_spec.rb
snuffle-0.14.0 spec/snuffle/node_spec.rb
snuffle-0.13.0 spec/snuffle/node_spec.rb
snuffle-0.12.2 spec/snuffle/node_spec.rb
snuffle-0.12.1 spec/snuffle/node_spec.rb
snuffle-0.12.0 spec/snuffle/node_spec.rb
snuffle-0.11.1 spec/snuffle/node_spec.rb
snuffle-0.10.1 spec/snuffle/node_spec.rb