danger-reviewer 0.0.2.2 → 0.0.3

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: 6803e8ccb640b1f29e8f7b40ce275f7e6d12a5d05ff54af862c1497c4c6c78c0
4
- data.tar.gz: d44cf89dc7e780b2e0b8d4fb615795e7aaa31d726a558e2e026036a47cea6255
3
+ metadata.gz: 9c086304da503565e7523ba4fd203c7dbffd58d9ca46b04eee2c9fc87e98818c
4
+ data.tar.gz: 2c2c3913f9a401f4de921977e2945bdc7780bea9df79d3bc02aaf9da557c0ae7
5
5
  SHA512:
6
- metadata.gz: fe9519df8413a78f74c9076684de18ff1c2bc74a761b855b376576e44ba271ee3c94c2c9fce4c48a0ddb1449b096f171a0a2d79bed4c2a2876b57d608b1968c1
7
- data.tar.gz: b6e8239e6e519881f82dae55cdc7df111cae83e09b7d4cbab5b47b7e41129d4f0a912955662814cb44e49fd1b94d610d5a70b05a8a799f620da9bf604e1569eb
6
+ metadata.gz: 0f946629afb02b2508f770abb971af05cd1ff4a4fcc4e92b8c103bd4edae8a9ed50bf8cbdc16b5e5deb1735dac3e6e5388287eac93a8861e7bb28b1040e346f5
7
+ data.tar.gz: b4f95a32ac94b35158f4da8de3a6eb94939d78e9e8e80c1d13a05a624f75417d0f02f9fd503dfe4bf9cbb95e8535bb745b94456575e077e5b23e653d2710cd07
@@ -1,3 +1,3 @@
1
1
  module Reviewer
2
- VERSION = "0.0.2.2".freeze
2
+ VERSION = "0.0.3".freeze
3
3
  end
@@ -64,7 +64,7 @@ module GitHub
64
64
  GRAPHQL
65
65
 
66
66
  ReviewerQuery = GitHub::Client.parse <<-'GRAPHQL'
67
- query($owner:String!, $repo:String!, $number:Int!) {
67
+ query ($owner: String!, $repo: String!, $number: Int!) {
68
68
  repository(name: $repo, owner: $owner) {
69
69
  pullRequest(number: $number) {
70
70
  reviewRequests(first: 10) {
@@ -76,6 +76,15 @@ module GitHub
76
76
  }
77
77
  }
78
78
  }
79
+ reviews(first: 10) {
80
+ edges {
81
+ node {
82
+ author {
83
+ login
84
+ }
85
+ }
86
+ }
87
+ }
79
88
  }
80
89
  }
81
90
  }
@@ -73,7 +73,10 @@ module Danger
73
73
  owner, repo = env.ci_source.repo_slug.split('/')
74
74
 
75
75
  result = GitHub::Client.query(GitHub::ReviewerQuery, variables: { repo: repo, owner: owner, number: github.pr_json[:number] })
76
- result.data.repository.pull_request.review_requests.edges.map { |edge| edge.node.reviewer.login }
76
+ [
77
+ result.data.repository.pull_request.review_requests.edges.map { |edge| edge.node.reviewer.login },
78
+ result.data.repository.pull_request.reviews.edges.map { |edge| edge.node.author.login },
79
+ ].flatten.uniq
77
80
  end
78
81
 
79
82
  def team_members(team)
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: danger-reviewer
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.0.2.2
4
+ version: 0.0.3
5
5
  platform: ruby
6
6
  authors:
7
7
  - Mikko Kokkonen
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2018-05-18 00:00:00.000000000 Z
11
+ date: 2018-05-29 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: danger-plugin-api