contribution-checker 0.1.2 → 1.0.0
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.
- checksums.yaml +4 -4
- data/README.md +2 -1
- data/lib/contribution-checker/checker.rb +3 -1
- data/lib/contribution-checker/version.rb +1 -1
- data/spec/contribution-checker/checker_spec.rb +9 -0
- 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: 0a24d5ff8cc0ea269b69ea05e9eb6f1cbd2e61b3
|
4
|
+
data.tar.gz: 4adee37427cea31f5a7d4b724a5dead3a3dd1327
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 6256fb06674af1b3761baa6cd37063604497ed5f3033fba361f4210b352469948c50d9ef37f42d107681f09f00fafac0274fda2bc4e11ef9633b02ef944e7a63
|
7
|
+
data.tar.gz: 8cb2678f1fe52dea1c75c49057493e992688c43e141e561498cff1b0a01959bced069c3eece0023ffd75bcfd58adc4088db4f1c50a9994032ec25b8910e6bb07
|
data/README.md
CHANGED
@@ -18,7 +18,8 @@ checker.check
|
|
18
18
|
:commit_in_valid_branch => true,
|
19
19
|
:commit_in_last_year => true,
|
20
20
|
:repo_not_a_fork => true,
|
21
|
-
:commit_email_linked_to_user => true
|
21
|
+
:commit_email_linked_to_user => true,
|
22
|
+
:commit_email => "example@example.com"
|
22
23
|
},
|
23
24
|
:or_criteria => {
|
24
25
|
:user_has_starred_repo => false,
|
@@ -36,7 +36,8 @@ module ContributionChecker
|
|
36
36
|
# :commit_in_valid_branch => true,
|
37
37
|
# :commit_in_last_year => true,
|
38
38
|
# :repo_not_a_fork => true,
|
39
|
-
# :commit_email_linked_to_user => true
|
39
|
+
# :commit_email_linked_to_user => true,
|
40
|
+
# :commit_email => "example@example.com",
|
40
41
|
# },
|
41
42
|
# :or_criteria => {
|
42
43
|
# :user_has_starred_repo => false,
|
@@ -73,6 +74,7 @@ module ContributionChecker
|
|
73
74
|
:commit_in_last_year => @commit_in_last_year,
|
74
75
|
:repo_not_a_fork => @repo_not_a_fork,
|
75
76
|
:commit_email_linked_to_user => @commit_email_linked_to_user,
|
77
|
+
:commit_email => @commit[:commit][:author][:email],
|
76
78
|
},
|
77
79
|
:or_criteria => {
|
78
80
|
:user_has_starred_repo => @user_has_starred_repo,
|
@@ -78,6 +78,7 @@ describe ContributionChecker::Checker do
|
|
78
78
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
79
79
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
80
80
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
81
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
81
82
|
|
82
83
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
83
84
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -119,6 +120,7 @@ describe ContributionChecker::Checker do
|
|
119
120
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
120
121
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
121
122
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
123
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
122
124
|
|
123
125
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
124
126
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -160,6 +162,7 @@ describe ContributionChecker::Checker do
|
|
160
162
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
161
163
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
162
164
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
165
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
163
166
|
|
164
167
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
165
168
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -201,6 +204,7 @@ describe ContributionChecker::Checker do
|
|
201
204
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
202
205
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
203
206
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
207
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
204
208
|
|
205
209
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
206
210
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -243,6 +247,7 @@ describe ContributionChecker::Checker do
|
|
243
247
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
244
248
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
245
249
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
250
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
246
251
|
|
247
252
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
248
253
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -284,6 +289,7 @@ describe ContributionChecker::Checker do
|
|
284
289
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
285
290
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
286
291
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
292
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
287
293
|
|
288
294
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
289
295
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -325,6 +331,7 @@ describe ContributionChecker::Checker do
|
|
325
331
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
326
332
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
327
333
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
334
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
328
335
|
|
329
336
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
330
337
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -370,6 +377,7 @@ describe ContributionChecker::Checker do
|
|
370
377
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
371
378
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
372
379
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
380
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
373
381
|
|
374
382
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
375
383
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
@@ -415,6 +423,7 @@ describe ContributionChecker::Checker do
|
|
415
423
|
expect(result[:and_criteria][:commit_in_last_year]).to eq(true)
|
416
424
|
expect(result[:and_criteria][:repo_not_a_fork]).to eq(true)
|
417
425
|
expect(result[:and_criteria][:commit_email_linked_to_user]).to eq(true)
|
426
|
+
expect(result[:and_criteria][:commit_email]).to eq("example@example.com")
|
418
427
|
|
419
428
|
expect(result[:or_criteria][:user_has_starred_repo]).to eq(false)
|
420
429
|
expect(result[:or_criteria][:user_can_push_to_repo]).to eq(true)
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: contribution-checker
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 0.
|
4
|
+
version: 1.0.0
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- James Dennes
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2014-06-
|
11
|
+
date: 2014-06-22 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: octokit
|