omf_rc 6.2.1 → 6.2.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +5 -13
- data/lib/omf_rc/resource_proxy/application.rb +1 -1
- data/test/omf_rc/util/ip_spec.rb +4 -4
- data/test/omf_rc/util/iw_spec.rb +11 -11
- data/test/omf_rc/util/mod_spec.rb +1 -1
- metadata +20 -20
checksums.yaml
CHANGED
@@ -1,15 +1,7 @@
|
|
1
1
|
---
|
2
|
-
|
3
|
-
metadata.gz:
|
4
|
-
|
5
|
-
data.tar.gz: !binary |-
|
6
|
-
YTZlZDIxMTE0OTVjYmZhNzQ1ZGFlNmU0YmRmOTNjZTI5YjI2ZGNjMw==
|
2
|
+
SHA1:
|
3
|
+
metadata.gz: 81d94fe5f51e938412d6e109c942e666400efdc4
|
4
|
+
data.tar.gz: c523b6a03ea4201f4ea18b76d432e6f3a42bc860
|
7
5
|
SHA512:
|
8
|
-
metadata.gz:
|
9
|
-
|
10
|
-
NGVhNDdiYWExNThlNjVhOWYyMmIxNTYyMjM5YjUzMmNlODU4YjE3Y2RkYzgw
|
11
|
-
NTI2Y2VhYzljNDJmZmU3NzdiNjRiMmQ5YmU1OGY5MWQ3YWUwZmQ=
|
12
|
-
data.tar.gz: !binary |-
|
13
|
-
OWM5MTJhNjJjODlkNGY5MTc4ZmEzNzlmNzc1ZDRkZDdmNjlmMzYxN2QzNGU2
|
14
|
-
YTljM2NiNzRiMzM4YjUwYzFkMDJiOWY4NDVjNThhMDU3ZDFmZDgxZTVmZDFm
|
15
|
-
MWMwNzUwZDgxMTljNzEyNWYxMjhkNDIzNDMyNGUyZjM0M2U5NGE=
|
6
|
+
metadata.gz: fef3adab1294263b6e02dbd0751fb1d5d1e16377682fc045339774628dbca2f6af17d06388b38c968114e13a5c99b3ba88d29a686561ffd2ce914bff8be6f22a
|
7
|
+
data.tar.gz: c43dab53d6ab208ce7cac6d07f2094330f0ed312c29067f14914506b1ae9794347bbd05b1b3e14f5e6b18ee98d90588bd0e2a7cc342bc4c75c4286183e8e0482
|
@@ -359,7 +359,7 @@ module OmfRc::ResourceProxy::Application
|
|
359
359
|
work('switch_to_running') do |res|
|
360
360
|
if res.property.state == :created || res.property.state == :stopped
|
361
361
|
# start a new instance of this app
|
362
|
-
res.property.app_id = res.hrn.nil? ? res.uid : res.hrn
|
362
|
+
res.property.app_id = res.hrn.nil? ? res.uid : "#{res.hrn}-#{res.uid}"
|
363
363
|
# we need at least a defined binary path to run an app...
|
364
364
|
if res.property.binary_path.nil?
|
365
365
|
res.log_inform_warn "Binary path not set! No Application to run!"
|
data/test/omf_rc/util/ip_spec.rb
CHANGED
@@ -37,7 +37,7 @@ describe OmfRc::Util::Ip do
|
|
37
37
|
|
38
38
|
it "could request ip address of the device" do
|
39
39
|
Cocaine::CommandLine.stub(:new, @command) do
|
40
|
-
@command.expect(:run, fixture("ip/addr_show"))
|
40
|
+
@command.expect(:run, fixture("ip/addr_show"), [Hash])
|
41
41
|
@wlan00.request_ip_addr.must_equal "192.168.1.124/24"
|
42
42
|
@command.verify
|
43
43
|
end
|
@@ -45,7 +45,7 @@ describe OmfRc::Util::Ip do
|
|
45
45
|
|
46
46
|
it "could request mac address of the device" do
|
47
47
|
Cocaine::CommandLine.stub(:new, @command) do
|
48
|
-
@command.expect(:run, fixture("ip/addr_show"))
|
48
|
+
@command.expect(:run, fixture("ip/addr_show"), [Hash])
|
49
49
|
@wlan00.request_mac_addr.must_equal "00:00:00:29:00:00"
|
50
50
|
@command.verify
|
51
51
|
end
|
@@ -56,9 +56,9 @@ describe OmfRc::Util::Ip do
|
|
56
56
|
# lambda { @wlan00.configure_ip_addr("192.168.1.124/24") }.must_raise Cocaine::ExitStatusError
|
57
57
|
Cocaine::CommandLine.stub(:new, @command) do
|
58
58
|
3.times do
|
59
|
-
@command.expect(:run, "")
|
59
|
+
@command.expect(:run, "", [Hash])
|
60
60
|
end
|
61
|
-
@command.expect(:run, fixture("ip/addr_show"))
|
61
|
+
@command.expect(:run, fixture("ip/addr_show"), [Hash])
|
62
62
|
@wlan00.configure_ip_addr("192.168.1.124/24")
|
63
63
|
@command.verify
|
64
64
|
end
|
data/test/omf_rc/util/iw_spec.rb
CHANGED
@@ -42,7 +42,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
42
42
|
|
43
43
|
it "could request properties of the wifi interface" do
|
44
44
|
Cocaine::CommandLine.stub(:new, @command) do
|
45
|
-
@command.expect(:run, fixture("iw/link"))
|
45
|
+
@command.expect(:run, fixture("iw/link"), [Hash])
|
46
46
|
@wlan00.request_link.keys.must_include "ssid"
|
47
47
|
@command.verify
|
48
48
|
end
|
@@ -50,7 +50,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
50
50
|
|
51
51
|
it "could request info of the wifi interface" do
|
52
52
|
Cocaine::CommandLine.stub(:new, @command) do
|
53
|
-
@command.expect(:run, fixture("iw/info"))
|
53
|
+
@command.expect(:run, fixture("iw/info"), [Hash])
|
54
54
|
@wlan00.request_info.keys.must_equal ["ifindex", "type", "wiphy"]
|
55
55
|
@command.verify
|
56
56
|
end
|
@@ -59,7 +59,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
59
59
|
it "could configure the device's property" do
|
60
60
|
skip
|
61
61
|
Cocaine::CommandLine.stub(:new, @command) do
|
62
|
-
@command.expect(:run, true)
|
62
|
+
@command.expect(:run, true, [Hash])
|
63
63
|
@wlan00.configure_power_save(true)
|
64
64
|
@command.verify
|
65
65
|
end
|
@@ -79,7 +79,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
79
79
|
|
80
80
|
it "could delete current interface" do
|
81
81
|
Cocaine::CommandLine.stub(:new, @command) do
|
82
|
-
@command.expect(:run, true)
|
82
|
+
@command.expect(:run, true, [Hash])
|
83
83
|
@wlan00.delete_interface
|
84
84
|
@command.verify
|
85
85
|
end
|
@@ -87,7 +87,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
87
87
|
|
88
88
|
it "could add a new interface" do
|
89
89
|
Cocaine::CommandLine.stub(:new, @command) do
|
90
|
-
@command.expect(:run, true)
|
90
|
+
@command.expect(:run, true, [Hash])
|
91
91
|
@wlan00.add_interface(:managed)
|
92
92
|
@command.verify
|
93
93
|
end
|
@@ -102,21 +102,21 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
102
102
|
|
103
103
|
it "must be able to configure as master mode" do
|
104
104
|
Cocaine::CommandLine.stub(:new, @command) do
|
105
|
-
3.times { @command.expect(:run, true) }
|
105
|
+
3.times { @command.expect(:run, true, [Hash]) }
|
106
106
|
|
107
107
|
@wlan00.configure_mode(mode: 'master', channel: 1, essid: 'bob', hw_mode: 'b')
|
108
108
|
File.open(@wlan00.property.ap_conf) do |f|
|
109
109
|
f.read.must_match "driver=nl80211\ninterface=wlan1\nssid=bob\nchannel=1\nhw_mode=b\n"
|
110
110
|
end
|
111
111
|
|
112
|
-
3.times { @command.expect(:run, true) }
|
112
|
+
3.times { @command.expect(:run, true, [Hash]) }
|
113
113
|
|
114
114
|
@wlan00.configure_mode(mode: 'master', channel: 1, essid: 'bob', hw_mode: 'n')
|
115
115
|
File.open(@wlan00.property.ap_conf) do |f|
|
116
116
|
f.read.must_match "driver=nl80211\ninterface=wlan1\nssid=bob\nchannel=1\nhw_mode=g\nwmm_enabled=1\nieee80211n=1\nht_capab=\[HT20\-\]\n"
|
117
117
|
end
|
118
118
|
|
119
|
-
3.times { @command.expect(:run, true) }
|
119
|
+
3.times { @command.expect(:run, true, [Hash]) }
|
120
120
|
|
121
121
|
@wlan00.configure_mode(mode: 'master', channel: 16, essid: 'bob', hw_mode: 'n')
|
122
122
|
File.open(@wlan00.property.ap_conf) do |f|
|
@@ -129,7 +129,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
129
129
|
|
130
130
|
it "must be able to configure as managed mode" do
|
131
131
|
Cocaine::CommandLine.stub(:new, @command) do
|
132
|
-
3.times { @command.expect(:run, true) }
|
132
|
+
3.times { @command.expect(:run, true, [Hash]) }
|
133
133
|
|
134
134
|
@wlan00.configure_mode(mode: 'managed', essid: 'bob')
|
135
135
|
File.open(@wlan00.property.wpa_conf) do |f|
|
@@ -142,7 +142,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
142
142
|
|
143
143
|
it "must be able to configure as adhoc/ibss mode" do
|
144
144
|
Cocaine::CommandLine.stub(:new, @command) do
|
145
|
-
4.times { @command.expect(:run, true) }
|
145
|
+
4.times { @command.expect(:run, true, [Hash]) }
|
146
146
|
|
147
147
|
@wlan00.configure_mode(mode: 'adhoc', essid: 'bob', frequency: 2412)
|
148
148
|
@command.verify
|
@@ -151,7 +151,7 @@ Cocaine::CommandLine.stub(:new, @command) do
|
|
151
151
|
|
152
152
|
it "must be able to configure as monitor mode" do
|
153
153
|
Cocaine::CommandLine.stub(:new, @command) do
|
154
|
-
3.times { @command.expect(:run, true) }
|
154
|
+
3.times { @command.expect(:run, true, [Hash]) }
|
155
155
|
|
156
156
|
@wlan00.configure_mode(mode: 'monitor')
|
157
157
|
@command.verify
|
@@ -38,7 +38,7 @@ describe OmfRc::Util::Mod do
|
|
38
38
|
|
39
39
|
it "could load a module" do
|
40
40
|
Cocaine::CommandLine.stub(:new, @command) do
|
41
|
-
@command.expect(:run, true)
|
41
|
+
@command.expect(:run, true, [Hash])
|
42
42
|
@mod_test.configure_load_module(name: 'magic_module').must_equal "magic_module loaded"
|
43
43
|
@command.verify
|
44
44
|
end
|
metadata
CHANGED
@@ -1,69 +1,69 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: omf_rc
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 6.2.
|
4
|
+
version: 6.2.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- NICTA
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-
|
11
|
+
date: 2015-06-04 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: minitest
|
15
15
|
requirement: !ruby/object:Gem::Requirement
|
16
16
|
requirements:
|
17
|
-
- -
|
17
|
+
- - ">="
|
18
18
|
- !ruby/object:Gem::Version
|
19
19
|
version: '0'
|
20
20
|
type: :development
|
21
21
|
prerelease: false
|
22
22
|
version_requirements: !ruby/object:Gem::Requirement
|
23
23
|
requirements:
|
24
|
-
- -
|
24
|
+
- - ">="
|
25
25
|
- !ruby/object:Gem::Version
|
26
26
|
version: '0'
|
27
27
|
- !ruby/object:Gem::Dependency
|
28
28
|
name: pry
|
29
29
|
requirement: !ruby/object:Gem::Requirement
|
30
30
|
requirements:
|
31
|
-
- -
|
31
|
+
- - ">="
|
32
32
|
- !ruby/object:Gem::Version
|
33
33
|
version: '0'
|
34
34
|
type: :development
|
35
35
|
prerelease: false
|
36
36
|
version_requirements: !ruby/object:Gem::Requirement
|
37
37
|
requirements:
|
38
|
-
- -
|
38
|
+
- - ">="
|
39
39
|
- !ruby/object:Gem::Version
|
40
40
|
version: '0'
|
41
41
|
- !ruby/object:Gem::Dependency
|
42
42
|
name: simplecov
|
43
43
|
requirement: !ruby/object:Gem::Requirement
|
44
44
|
requirements:
|
45
|
-
- -
|
45
|
+
- - ">="
|
46
46
|
- !ruby/object:Gem::Version
|
47
47
|
version: '0'
|
48
48
|
type: :development
|
49
49
|
prerelease: false
|
50
50
|
version_requirements: !ruby/object:Gem::Requirement
|
51
51
|
requirements:
|
52
|
-
- -
|
52
|
+
- - ">="
|
53
53
|
- !ruby/object:Gem::Version
|
54
54
|
version: '0'
|
55
55
|
- !ruby/object:Gem::Dependency
|
56
56
|
name: mocha
|
57
57
|
requirement: !ruby/object:Gem::Requirement
|
58
58
|
requirements:
|
59
|
-
- -
|
59
|
+
- - ">="
|
60
60
|
- !ruby/object:Gem::Version
|
61
61
|
version: '0'
|
62
62
|
type: :development
|
63
63
|
prerelease: false
|
64
64
|
version_requirements: !ruby/object:Gem::Requirement
|
65
65
|
requirements:
|
66
|
-
- -
|
66
|
+
- - ">="
|
67
67
|
- !ruby/object:Gem::Version
|
68
68
|
version: '0'
|
69
69
|
- !ruby/object:Gem::Dependency
|
@@ -72,40 +72,40 @@ dependencies:
|
|
72
72
|
requirements:
|
73
73
|
- - '='
|
74
74
|
- !ruby/object:Gem::Version
|
75
|
-
version: 6.2.
|
75
|
+
version: 6.2.2
|
76
76
|
type: :runtime
|
77
77
|
prerelease: false
|
78
78
|
version_requirements: !ruby/object:Gem::Requirement
|
79
79
|
requirements:
|
80
80
|
- - '='
|
81
81
|
- !ruby/object:Gem::Version
|
82
|
-
version: 6.2.
|
82
|
+
version: 6.2.2
|
83
83
|
- !ruby/object:Gem::Dependency
|
84
84
|
name: cocaine
|
85
85
|
requirement: !ruby/object:Gem::Requirement
|
86
86
|
requirements:
|
87
|
-
- -
|
87
|
+
- - ">="
|
88
88
|
- !ruby/object:Gem::Version
|
89
89
|
version: '0'
|
90
90
|
type: :runtime
|
91
91
|
prerelease: false
|
92
92
|
version_requirements: !ruby/object:Gem::Requirement
|
93
93
|
requirements:
|
94
|
-
- -
|
94
|
+
- - ">="
|
95
95
|
- !ruby/object:Gem::Version
|
96
96
|
version: '0'
|
97
97
|
- !ruby/object:Gem::Dependency
|
98
98
|
name: facter
|
99
99
|
requirement: !ruby/object:Gem::Requirement
|
100
100
|
requirements:
|
101
|
-
- -
|
101
|
+
- - ">="
|
102
102
|
- !ruby/object:Gem::Version
|
103
103
|
version: '0'
|
104
104
|
type: :runtime
|
105
105
|
prerelease: false
|
106
106
|
version_requirements: !ruby/object:Gem::Requirement
|
107
107
|
requirements:
|
108
|
-
- -
|
108
|
+
- - ">="
|
109
109
|
- !ruby/object:Gem::Version
|
110
110
|
version: '0'
|
111
111
|
description: Resource controller of OMF, a generic framework for controlling and managing
|
@@ -119,7 +119,7 @@ executables:
|
|
119
119
|
extensions: []
|
120
120
|
extra_rdoc_files: []
|
121
121
|
files:
|
122
|
-
- .gitignore
|
122
|
+
- ".gitignore"
|
123
123
|
- Gemfile
|
124
124
|
- Rakefile
|
125
125
|
- bin/install_omf_rc
|
@@ -204,17 +204,17 @@ require_paths:
|
|
204
204
|
- lib
|
205
205
|
required_ruby_version: !ruby/object:Gem::Requirement
|
206
206
|
requirements:
|
207
|
-
- -
|
207
|
+
- - ">="
|
208
208
|
- !ruby/object:Gem::Version
|
209
209
|
version: 1.9.3
|
210
210
|
required_rubygems_version: !ruby/object:Gem::Requirement
|
211
211
|
requirements:
|
212
|
-
- -
|
212
|
+
- - ">="
|
213
213
|
- !ruby/object:Gem::Version
|
214
214
|
version: '0'
|
215
215
|
requirements: []
|
216
216
|
rubyforge_project: omf_rc
|
217
|
-
rubygems_version: 2.
|
217
|
+
rubygems_version: 2.2.2
|
218
218
|
signing_key:
|
219
219
|
specification_version: 4
|
220
220
|
summary: OMF resource controller
|