Class: Danger::PullRequestFinder

Inherits:
Object
  • Object
show all
Defined in:
lib/danger/ci_source/support/pull_request_finder.rb

Instance Method Summary collapse

Constructor Details

#initialize(specific_pull_request_id, repo_slug = nil, remote: false, git_logs: "", remote_url: "", env: nil) ⇒ PullRequestFinder

Returns a new instance of PullRequestFinder.



7
8
9
10
11
12
13
14
# File 'lib/danger/ci_source/support/pull_request_finder.rb', line 7

def initialize(specific_pull_request_id, repo_slug = nil, remote: false, git_logs: "", remote_url: "", env: nil)
  @specific_pull_request_id = specific_pull_request_id
  @git_logs = git_logs
  @repo_slug = repo_slug
  @remote = to_boolean(remote)
  @remote_url = remote_url
  @env = env
end

Instance Method Details

#callObject



16
17
18
19
20
# File 'lib/danger/ci_source/support/pull_request_finder.rb', line 16

def call
  check_if_any_pull_request!

  pull_request
end