Sha256: ce38508de6b919600746090ed1bcc84db292d6c4440e14c2bfd117c4e47ecfb4

Contents?: true

Size: 626 Bytes

Versions: 1

Compression:

Stored size: 626 Bytes

Contents

require File.expand_path(File.join(File.dirname(__FILE__), '..', '..', 'spec_helper'))
require 'meac_control/device'

describe MEACControl::Device do
  describe "#id" do
    it "returns the device id" do
      MEACControl::Device.new(34).id.should == 34
    end
  end

  describe "#name" do
    it "returns the device name" do
      device = MEACControl::Device.new(23)
      device.name = "fooac"
      device.name.should == "fooac"
    end
  end

  it "will set the name value with the initializer option :name" do
    device = MEACControl::Device.new(22, :name => "foobarac")
    device.name.should == "foobarac"
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
meac_control-1.0.0 spec/lib/meac_control/device_spec.rb