testrail_helper 0.0.4 → 0.0.5
Sign up to get free protection for your applications and to get access to all the features.
- checksums.yaml +4 -4
- data/README.md +12 -0
- data/lib/testrail_helper/version.rb +1 -1
- data/lib/testrail_helper.rb +29 -0
- data/test.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: 3ddb90fa28658965c154e0f7c5c6c53c944abd5a
|
4
|
+
data.tar.gz: 6173e6822e209628bd89550e617cf7e5d556b058
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: c4d27cbe9d64dc3ee7966328542c37fd72866f8b5b4dbbd724d04bc7b0eeb96dd1d14fd9925b9af54c3d24336eb8a55ae3a007a3ba0ceb01cfd0416c762fbd39
|
7
|
+
data.tar.gz: 2873e757a09a6ec088e32563eb7108fee568ddae36b6fb619e160b81cff03102f2226ff887784ceaa7c5efc86c53d8c25e741aa7d699e5f63c15298cba6b3164
|
data/README.md
CHANGED
@@ -47,6 +47,18 @@ client.get_run_info(2610)
|
|
47
47
|
|
48
48
|
# get all test caes in a run
|
49
49
|
client.get_tests(2610)
|
50
|
+
|
51
|
+
# get all users
|
52
|
+
client get_all_users
|
53
|
+
|
54
|
+
# get all active users
|
55
|
+
client get_all_active_users
|
56
|
+
|
57
|
+
# get user by id
|
58
|
+
client.get_user(4)
|
59
|
+
|
60
|
+
# get user by email
|
61
|
+
client.get_user_by_email("guybrush@SCUMM.com)
|
50
62
|
```
|
51
63
|
|
52
64
|
## Development
|
data/lib/testrail_helper.rb
CHANGED
@@ -77,6 +77,35 @@ module TestrailHelper
|
|
77
77
|
puts @client.send_post(uri,params)
|
78
78
|
end
|
79
79
|
|
80
|
+
def get_all_users
|
81
|
+
puts "getting all users"
|
82
|
+
uri = "get_users"
|
83
|
+
@client.send_get(uri)
|
84
|
+
end
|
85
|
+
|
86
|
+
def get_all_active_users
|
87
|
+
puts "getting all active_users"
|
88
|
+
uri = "get_users"
|
89
|
+
users = @client.send_get(uri)
|
90
|
+
active_users = []
|
91
|
+
users.each do |x|
|
92
|
+
active_users << x if x.fetch('is_active') == true
|
93
|
+
end
|
94
|
+
active_users
|
95
|
+
end
|
96
|
+
|
97
|
+
def get_user(user_id)
|
98
|
+
puts "getting title"
|
99
|
+
uri = "get_user/#{user_id}"
|
100
|
+
@client.send_get(uri)
|
101
|
+
end
|
102
|
+
|
103
|
+
def get_user_by_email(email)
|
104
|
+
puts "getting title"
|
105
|
+
uri = "get_user_by_email&email=#{email}"
|
106
|
+
@client.send_get(uri)
|
107
|
+
end
|
108
|
+
|
80
109
|
def get_title(case_id)
|
81
110
|
puts "getting title"
|
82
111
|
uri = "get_case/#{case_id}"
|
data/test.rb
CHANGED
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: testrail_helper
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.0.
|
4
|
+
version: 0.0.5
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- kinezu
|
8
8
|
autorequire:
|
9
9
|
bindir: exe
|
10
10
|
cert_chain: []
|
11
|
-
date: 2015-07-
|
11
|
+
date: 2015-07-18 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: json
|