testlab 1.2.0 → 1.2.1

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -53,7 +53,7 @@ class TestLab
53
53
 
54
54
  {
55
55
  :id => self.id,
56
- :clone => self.lxc_clone.exists?,
56
+ :mode => self.mode,
57
57
  :fqdn => self.fqdn,
58
58
  :state => self.state,
59
59
  :distro => self.distro,
@@ -73,6 +73,18 @@ class TestLab
73
73
  self.lxc.state
74
74
  end
75
75
 
76
+ # Container Mode
77
+ #
78
+ # What mode the container is in.
79
+ # @return [Symbol] A symbol indicating the mode of the container.
80
+ def mode
81
+ if self.lxc_clone.exists?
82
+ :ephemeral
83
+ else
84
+ :persistent
85
+ end
86
+ end
87
+
76
88
  end
77
89
 
78
90
  end
@@ -72,7 +72,7 @@ class TestLab
72
72
  # An array of symbols of the various keys in our status hash.
73
73
  #
74
74
  # @see TestLab::Container::Status
75
- STATUS_KEYS = %w(id node_id clone fqdn state distro release interfaces provisioners).map(&:to_sym)
75
+ STATUS_KEYS = %w(id node_id mode fqdn state distro release interfaces provisioners).map(&:to_sym)
76
76
 
77
77
  # Sub-Modules
78
78
  autoload :Actions, 'testlab/container/actions'
@@ -1,6 +1,6 @@
1
1
  class TestLab
2
2
  unless const_defined?(:VERSION)
3
3
  # TestLab Gem Version
4
- VERSION = "1.2.0"
4
+ VERSION = "1.2.1"
5
5
  end
6
6
  end
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: testlab
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.2.0
4
+ version: 1.2.1
5
5
  prerelease:
6
6
  platform: ruby
7
7
  authors:
@@ -339,7 +339,7 @@ required_ruby_version: !ruby/object:Gem::Requirement
339
339
  version: '0'
340
340
  segments:
341
341
  - 0
342
- hash: -4166259606909951281
342
+ hash: 4032847501508074403
343
343
  required_rubygems_version: !ruby/object:Gem::Requirement
344
344
  none: false
345
345
  requirements:
@@ -348,7 +348,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
348
348
  version: '0'
349
349
  segments:
350
350
  - 0
351
- hash: -4166259606909951281
351
+ hash: 4032847501508074403
352
352
  requirements: []
353
353
  rubyforge_project:
354
354
  rubygems_version: 1.8.25