beaker 1.17.1 → 1.17.2
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +8 -8
- data/HISTORY.md +92 -3
- data/lib/beaker.rb +6 -0
- data/lib/beaker/dsl/helpers.rb +3 -3
- data/lib/beaker/host/unix.rb +0 -2
- data/lib/beaker/hypervisor/aws_sdk.rb +10 -6
- data/lib/beaker/options/presets.rb +1 -1
- data/lib/beaker/test_suite.rb +23 -2
- data/lib/beaker/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,15 +1,15 @@
|
|
1
1
|
---
|
2
2
|
!binary "U0hBMQ==":
|
3
3
|
metadata.gz: !binary |-
|
4
|
-
|
4
|
+
ZTBjNDZkNTNjYTM2YTcxMDYxNGVkODBlYzk4ZGY3ZjhiZWE0NGI4Yw==
|
5
5
|
data.tar.gz: !binary |-
|
6
|
-
|
6
|
+
YmU5OTVmYmI5MmU5ODZhZDE3Njg3MWVlOGYyNTM2NTg0ZGMxYzdlNg==
|
7
7
|
SHA512:
|
8
8
|
metadata.gz: !binary |-
|
9
|
-
|
10
|
-
|
11
|
-
|
9
|
+
YjFhMDMxMTFmYjFjMDg1ZjIyOTc2NjQ1MDllNGZiYjVkMDM3YTQxZThkMjgw
|
10
|
+
ODk2ODc0MTE4OGE4ZTBlOWUwMTdlZjIyOTNmOTQ2N2FjOTliNTVlNDZlMTU5
|
11
|
+
NzVlZWY3MjBjODhhMzdiNWRmNmM3ZGRiNzIwZTg4ZjU2NWQxZDY=
|
12
12
|
data.tar.gz: !binary |-
|
13
|
-
|
14
|
-
|
15
|
-
|
13
|
+
NzEzMTg0NzdmZDA3NTI0MjM0OTVhZWRhYWQ0MTgxMGRjMDcyOGRlNDMwODQ0
|
14
|
+
ZjE5MjY2Mjg2OGZjY2VmZmExMTEzNTRmNjkwZDNmYjY0NDUwNTI1NjA1MDBl
|
15
|
+
NGM3MjM4N2ZmMDE3YTY3ZGMyN2I5MWUwMjczZWJiZWU3NGY5MWI=
|
data/HISTORY.md
CHANGED
@@ -1,6 +1,7 @@
|
|
1
1
|
# beaker - History
|
2
2
|
## Tags
|
3
|
-
* [LATEST -
|
3
|
+
* [LATEST - 15 Aug, 2014 (f6227484)](#LATEST)
|
4
|
+
* [beaker1.17.1 - 12 Aug, 2014 (72e60299)](#beaker1.17.1)
|
4
5
|
* [beaker1.17.0 - 12 Aug, 2014 (fb482b56)](#beaker1.17.0)
|
5
6
|
* [beaker1.16.0 - 17 Jul, 2014 (c1267696)](#beaker1.16.0)
|
6
7
|
* [beaker1.15.0 - 8 Jul, 2014 (82bb4ef9)](#beaker1.15.0)
|
@@ -53,9 +54,97 @@
|
|
53
54
|
* [pe1.2 - 6 Sep, 2011 (ba3dadd2)](#pe1.2)
|
54
55
|
|
55
56
|
## Details
|
56
|
-
### <a name = "LATEST">LATEST -
|
57
|
+
### <a name = "LATEST">LATEST - 15 Aug, 2014 (f6227484)
|
57
58
|
|
58
|
-
* (
|
59
|
+
* (GEM) update version number for 1.17.2 (f6227484)
|
60
|
+
|
61
|
+
* Merge pull request #406 from anodelman/ec2 (5799458b)
|
62
|
+
|
63
|
+
|
64
|
+
```
|
65
|
+
Merge pull request #406 from anodelman/ec2
|
66
|
+
|
67
|
+
(QENG-1090) beaker: exception when waiting for instance running in ec2
|
68
|
+
```
|
69
|
+
* Merge pull request #403 from anodelman/win-fix (956aa18c)
|
70
|
+
|
71
|
+
|
72
|
+
```
|
73
|
+
Merge pull request #403 from anodelman/win-fix
|
74
|
+
|
75
|
+
(QENG-1081) Beaker Fails During Pre-suite in the "install_pe"...
|
76
|
+
```
|
77
|
+
* Merge pull request #405 from anodelman/utf-8-encoding (410490e4)
|
78
|
+
|
79
|
+
|
80
|
+
```
|
81
|
+
Merge pull request #405 from anodelman/utf-8-encoding
|
82
|
+
|
83
|
+
(QENG-1087) beaker - failure in XML output
|
84
|
+
```
|
85
|
+
* Merge pull request #404 from anodelman/fix-default (cc38a7f4)
|
86
|
+
|
87
|
+
|
88
|
+
```
|
89
|
+
Merge pull request #404 from anodelman/fix-default
|
90
|
+
|
91
|
+
(QENG-1086) The master-start-curl-retries is preset to...
|
92
|
+
```
|
93
|
+
* (QENG-1090) beaker: exception when waiting for instance running in ec2 (ae64c8e9)
|
94
|
+
|
95
|
+
|
96
|
+
```
|
97
|
+
(QENG-1090) beaker: exception when waiting for instance running in ec2
|
98
|
+
|
99
|
+
- correctly capture AWS::EC2::Errors::InvalidInstanceID::NotFound when
|
100
|
+
checking status of newly created instance, deal with it as another
|
101
|
+
case that requires a retry
|
102
|
+
```
|
103
|
+
* (QENG-1087) beaker - failure in XML output (5a392c1a)
|
104
|
+
|
105
|
+
|
106
|
+
```
|
107
|
+
(QENG-1087) beaker - failure in XML output
|
108
|
+
|
109
|
+
- caused by improperly stripping unsupported unicode characters from xml
|
110
|
+
output
|
111
|
+
- add inclusion of 'jcode' for ruby 1.8 (included with Ruby and adds
|
112
|
+
lots of useful Unicode-oriented features to String and Regexp)
|
113
|
+
- tested on 1.9 and 1.8 and correctly replaced invalid unicode with
|
114
|
+
escaped hex value
|
115
|
+
```
|
116
|
+
* (QENG-1086) The master-start-curl-retries is preset to... (77610212)
|
117
|
+
|
118
|
+
|
119
|
+
```
|
120
|
+
(QENG-1086) The master-start-curl-retries is preset to...
|
121
|
+
|
122
|
+
...0, which causes default hosts not to retry verifying a bounced master.
|
123
|
+
|
124
|
+
- host value being overwritten by default presets
|
125
|
+
```
|
126
|
+
* (QENG-1081) Beaker Fails During Pre-suite in the "install_pe"... (f08d67b1)
|
127
|
+
|
128
|
+
|
129
|
+
```
|
130
|
+
(QENG-1081) Beaker Fails During Pre-suite in the "install_pe"...
|
131
|
+
|
132
|
+
... Function on Windows
|
133
|
+
|
134
|
+
- when using an array of hosts the command object was overwritten and
|
135
|
+
thus the platform specific information was lost
|
136
|
+
```
|
137
|
+
### <a name = "beaker1.17.1">beaker1.17.1 - 12 Aug, 2014 (72e60299)
|
138
|
+
|
139
|
+
* Merge pull request #399 from anodelman/make-gem (72e60299)
|
140
|
+
|
141
|
+
|
142
|
+
```
|
143
|
+
Merge pull request #399 from anodelman/make-gem
|
144
|
+
|
145
|
+
create beaker 1.17.1 gem
|
146
|
+
```
|
147
|
+
* (HISTORY) update HISTORY.md for 1.17.1 gem (21480832)
|
59
148
|
|
60
149
|
* (GEM) create beaker 1.17.1 gem (07b67f32)
|
61
150
|
|
data/lib/beaker.rb
CHANGED
data/lib/beaker/dsl/helpers.rb
CHANGED
@@ -78,16 +78,16 @@ module Beaker
|
|
78
78
|
# @raise [FailTest] Raises an exception if *command* obviously fails.
|
79
79
|
def on(host, command, opts = {}, &block)
|
80
80
|
block_on host do | host |
|
81
|
+
cur_command = command
|
81
82
|
if command.is_a? Command
|
82
|
-
|
83
|
+
cur_command = command.cmd_line(host)
|
83
84
|
end
|
84
85
|
cmd_opts = {}
|
85
86
|
#add any additional environment variables to the command
|
86
87
|
if opts[:environment]
|
87
88
|
cmd_opts['ENV'] = opts[:environment]
|
88
89
|
end
|
89
|
-
|
90
|
-
@result = host.exec(command, opts)
|
90
|
+
@result = host.exec(Command.new(cur_command.to_s, [], cmd_opts), opts)
|
91
91
|
|
92
92
|
# Also, let additional checking be performed by the caller.
|
93
93
|
if block_given?
|
data/lib/beaker/host/unix.rb
CHANGED
@@ -19,7 +19,6 @@ module Unix
|
|
19
19
|
h.merge({
|
20
20
|
'user' => 'root',
|
21
21
|
'group' => 'pe-puppet',
|
22
|
-
'master-start-curl-retries' => 120,
|
23
22
|
'jvm-puppet-confdir' => '/etc/puppetlabs/jvm-puppet/conf.d',
|
24
23
|
'puppetservice' => 'pe-httpd',
|
25
24
|
'puppetpath' => '/etc/puppetlabs/puppet',
|
@@ -40,7 +39,6 @@ module Unix
|
|
40
39
|
h.merge({
|
41
40
|
'user' => 'root',
|
42
41
|
'group' => 'puppet',
|
43
|
-
'master-start-curl-retries' => 120,
|
44
42
|
'jvm-puppet-confdir' => '/etc/jvm-puppet/conf.d',
|
45
43
|
'puppetservice' => 'puppetmaster',
|
46
44
|
'puppetpath' => '/etc/puppet',
|
@@ -223,12 +223,16 @@ module Beaker
|
|
223
223
|
# exponential backoff for each poll.
|
224
224
|
# TODO: should probably be a in a shared method somewhere
|
225
225
|
for tries in 1..10
|
226
|
-
|
227
|
-
|
228
|
-
|
229
|
-
|
230
|
-
|
231
|
-
|
226
|
+
begin
|
227
|
+
if instance.status == status
|
228
|
+
# Always sleep, so the next command won't cause a throttle
|
229
|
+
backoff_sleep(tries)
|
230
|
+
break
|
231
|
+
elsif tries == 10
|
232
|
+
raise "Instance never reached state #{status}"
|
233
|
+
end
|
234
|
+
rescue AWS::EC2::Errors::InvalidInstanceID::NotFound => e
|
235
|
+
@logger.debug("Instance #{name} not yet available (#{e})")
|
232
236
|
end
|
233
237
|
backoff_sleep(tries)
|
234
238
|
end
|
@@ -97,7 +97,7 @@ module Beaker
|
|
97
97
|
:forge_host => 'vulcan-acceptance.delivery.puppetlabs.net',
|
98
98
|
:log_level => 'verbose',
|
99
99
|
:trace_limit => 10,
|
100
|
-
:"master-start-curl-retries" =>
|
100
|
+
:"master-start-curl-retries" => 120,
|
101
101
|
:options_file => nil,
|
102
102
|
:type => 'pe',
|
103
103
|
:provision => true,
|
data/lib/beaker/test_suite.rb
CHANGED
@@ -155,12 +155,33 @@ module Beaker
|
|
155
155
|
text.gsub(/(\e|\^\[)\[(\d*;)*\d*m/, '')
|
156
156
|
end
|
157
157
|
|
158
|
+
# Determine if the provided number falls in the range of accepted xml unicode values
|
159
|
+
# See http://www.w3.org/TR/xml/#charsets for valid for valid character specifications.
|
160
|
+
# @param [Integer] int The number to check against
|
161
|
+
# @return [Boolean] True, if the number corresponds to a valid xml unicode character, otherwise false
|
162
|
+
def is_valid_xml(int)
|
163
|
+
return ( int == 0x9 or
|
164
|
+
int == 0xA or
|
165
|
+
( int >= 0x0020 and int <= 0xD7FF ) or
|
166
|
+
( int >= 0xE000 and int <= 0xFFFD ) or
|
167
|
+
( int >= 0x100000 and int <= 0x10FFFF )
|
168
|
+
)
|
169
|
+
end
|
170
|
+
|
158
171
|
# Escape invalid XML UTF-8 codes from provided string, see http://www.w3.org/TR/xml/#charsets for valid
|
159
172
|
# character specification
|
160
173
|
# @param [String] string The string to remove invalid codes from
|
161
174
|
def escape_invalid_xml_chars string
|
162
|
-
|
163
|
-
|
175
|
+
escaped_string = ""
|
176
|
+
string.chars.each do |i|
|
177
|
+
char_as_codestring = i.unpack("U*").join
|
178
|
+
if is_valid_xml(char_as_codestring.to_i)
|
179
|
+
escaped_string << i
|
180
|
+
else
|
181
|
+
escaped_string << "\\#{char_as_codestring}"
|
182
|
+
end
|
183
|
+
end
|
184
|
+
escaped_string
|
164
185
|
end
|
165
186
|
|
166
187
|
# Remove color codes and invalid XML characters from provided string
|
data/lib/beaker/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: beaker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.17.
|
4
|
+
version: 1.17.2
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Puppetlabs
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-08-
|
11
|
+
date: 2014-08-15 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: minitest
|