lib/testlab/network.rb in testlab-0.6.5 vs lib/testlab/network.rb in testlab-0.6.6
- old
+ new
@@ -5,11 +5,11 @@
# Network Class
#
# @author Zachary Patten <zachary AT jovelabs DOT com>
class Network < ZTK::DSL::Base
- STATUS_KEYS = %w(node_id id state interface network netmask broadcast).map(&:to_sym)
+ STATUS_KEYS = %w(node_id id state interface network netmask broadcast provisioners).map(&:to_sym)
# Sub-Modules
autoload :Actions, 'testlab/network/actions'
autoload :Bind, 'testlab/network/bind'
autoload :ClassMethods, 'testlab/network/class_methods'
@@ -24,17 +24,17 @@
extend TestLab::Network::ClassMethods
include TestLab::Utility::Misc
# Associations and Attributes
- belongs_to :node, :class_name => 'TestLab::Node'
- has_many :interfaces, :class_name => 'TestLab::Interface'
+ belongs_to :node, :class_name => 'TestLab::Node'
+ has_many :interfaces, :class_name => 'TestLab::Interface'
+ attribute :provisioners, :default => Array.new
+ attribute :config, :default => Hash.new
+
attribute :address
attribute :bridge
- attribute :route, :default => false
-
- attribute :config
def initialize(*args)
super(*args)