Class: Pra::PullSource

Inherits:
Object
  • Object
show all
Defined in:
lib/pra/pull_source.rb

Direct Known Subclasses

GithubPullSource, StashPullSource

Defined Under Namespace

Classes: NotImplemented

Instance Method Summary collapse

Constructor Details

#initialize(config = {}) ⇒ PullSource

Returns a new instance of PullSource.



5
6
7
# File 'lib/pra/pull_source.rb', line 5

def initialize(config = {})
  @config = config
end

Instance Method Details

#pull_requestsObject

This method is a pure virtual method and is intended to implemented by all inheriting classes. It is responsible for obtaining and returning the opened pull requests from the pull source. Note: These should be returned as an array of Pra::PullRequest instances.

Raises:



13
14
15
# File 'lib/pra/pull_source.rb', line 13

def pull_requests
  raise NotImplemented, "The 'pull_requests' method needs to be implemented by the inheriting class"
end