proxy_rb 0.10.2 → 0.10.3
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/History.md +4 -0
- data/lib/proxy_rb/cucumber/steps.rb +19 -4
- data/lib/proxy_rb/version.rb +1 -1
- metadata +2 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: aa1d3d222a7c616d23e6930fbc87b592ddc5ba6a
|
4
|
+
data.tar.gz: 5c99918686897ccb1d5562c0423b37d80d53936d
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 3d3d7dc887e5b52713d46449cd71a3733cdf9b8264ed6802b888e23ec2d6214cdb2b84441e96facaeab43e277739ccee11b029a9762a309aaeb80763347196e0
|
7
|
+
data.tar.gz: b0e1b739ed427900c03ea59e9577d250b065030e83e0730320d48a6c36a37b73523ff97d29b219951ba52403e728133aa3d1b0675a641f2835303674d3c135a5
|
data/History.md
CHANGED
@@ -4,6 +4,10 @@ Empty
|
|
4
4
|
|
5
5
|
# RELEASED
|
6
6
|
|
7
|
+
## [v0.10.3](https://github.com/fedux-org/proxy_rb/compare/v0.10.2...v0.10.3)
|
8
|
+
|
9
|
+
* Setting user information now works with default step in Before Hook
|
10
|
+
|
7
11
|
## [v0.10.2](https://github.com/fedux-org/proxy_rb/compare/v0.10.1...v0.10.2)
|
8
12
|
|
9
13
|
* Make it possible to visit pages and then check all of them
|
@@ -8,18 +8,33 @@ Given(/^I use the user "([^"]*)"(?: with password "([^"]*)")?$/) do |user_name,
|
|
8
8
|
u.password = password || password(user_name)
|
9
9
|
|
10
10
|
users << u
|
11
|
+
|
12
|
+
proxies.each do |p|
|
13
|
+
p.credentials.user_name = users.last.name
|
14
|
+
p.credentials.password = users.last.password
|
15
|
+
end
|
11
16
|
end
|
12
17
|
|
13
18
|
Given(/^I use the following proxies:$/) do |table|
|
14
19
|
@proxies = table.hashes.map do |r|
|
15
20
|
p = ProxyRb::HttpProxy.new(ProxyRb::ProxyUrlParser.new(r[:proxy]))
|
16
|
-
p.credentials.password = password(p.credentials.user_name) if p.credentials.password == '<PASSWORD>'
|
17
21
|
|
18
|
-
|
19
|
-
|
20
|
-
p.credentials.password
|
22
|
+
# Hide password by using <PASSWORD> => retrieve it using fetcher
|
23
|
+
if p.credentials.password == '<PASSWORD>'
|
24
|
+
p.credentials.password = password(p.credentials.user_name)
|
25
|
+
next p
|
21
26
|
end
|
22
27
|
|
28
|
+
# Username and password are already set
|
29
|
+
next p if p.credentials.password && p.credentials.user_name
|
30
|
+
|
31
|
+
# No users have be defined
|
32
|
+
next p if users.nil? || users.empty?
|
33
|
+
|
34
|
+
# Use last user since nothing else makes sense
|
35
|
+
p.credentials.user_name = users.last.name
|
36
|
+
p.credentials.password = users.last.password
|
37
|
+
|
23
38
|
p
|
24
39
|
end
|
25
40
|
end
|
data/lib/proxy_rb/version.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: proxy_rb
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.10.
|
4
|
+
version: 0.10.3
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Max Meyer
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2016-03-
|
11
|
+
date: 2016-03-30 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|