Sha256: f7044bfcf81ecaf0e87ce06e0077dfdfb080d23842e09af2743a12d5ae5358dd

Contents?: true

Size: 661 Bytes

Versions: 8

Compression:

Stored size: 661 Bytes

Contents

require 'ixtlan/core/configuration_manager'

class ConfigModel

  def self.instance
    @instance ||= self.new
  end

  def self.after_save(method)
    @method = method.to_sym
  end

  def self.save_method
    @method
  end

  def save
    sent self.class.save_method
  end
end

describe Ixtlan::Core::ConfigurationManager do

#  before :all do
#    ConfigModel.sent :include, Ixtlan::Core::ConfigurationManager
#  end

  it "should" do
  end

  it "should register listeners and fire change events" do
#    count = 0
#    ConfigModel.instance.register("counter") do
#      count += 1
#    end
#    ConfigModel.instance.save
#    count.should == 1
  end
  
end

Version data entries

8 entries across 8 versions & 1 rubygems

Version Path
ixtlan-core-0.8.0 spec/configuration_manager_spec.rb~
ixtlan-core-0.7.5 spec/configuration_manager_spec.rb~
ixtlan-core-0.7.4 spec/configuration_manager_spec.rb~
ixtlan-core-0.7.3 spec/configuration_manager_spec.rb~
ixtlan-core-0.7.2 spec/configuration_manager_spec.rb~
ixtlan-core-0.7.1 spec/configuration_manager_spec.rb~
ixtlan-core-0.7.0 spec/configuration_manager_spec.rb~
ixtlan-core-0.6.1 spec/configuration_manager_spec.rb~