Class: Dependabot::PullRequestUpdater::Azure
- Inherits:
-
Object
- Object
- Dependabot::PullRequestUpdater::Azure
- Defined in:
- lib/dependabot/pull_request_updater/azure.rb
Defined Under Namespace
Classes: PullRequestUpdateFailed
Constant Summary collapse
- OBJECT_ID_FOR_BRANCH_DELETE =
"0000000000000000000000000000000000000000"
Instance Attribute Summary collapse
-
#base_commit ⇒ Object
readonly
Returns the value of attribute base_commit.
-
#credentials ⇒ Object
readonly
Returns the value of attribute credentials.
-
#files ⇒ Object
readonly
Returns the value of attribute files.
-
#old_commit ⇒ Object
readonly
Returns the value of attribute old_commit.
-
#pull_request_number ⇒ Object
readonly
Returns the value of attribute pull_request_number.
-
#source ⇒ Object
readonly
Returns the value of attribute source.
Instance Method Summary collapse
-
#initialize(source:, files:, base_commit:, old_commit:, credentials:, pull_request_number:) ⇒ Azure
constructor
A new instance of Azure.
- #update ⇒ Object
Constructor Details
#initialize(source:, files:, base_commit:, old_commit:, credentials:, pull_request_number:) ⇒ Azure
Returns a new instance of Azure.
16 17 18 19 20 21 22 23 24 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 16 def initialize(source:, files:, base_commit:, old_commit:, credentials:, pull_request_number:) @source = source @files = files @base_commit = base_commit @old_commit = old_commit @credentials = credentials @pull_request_number = pull_request_number end |
Instance Attribute Details
#base_commit ⇒ Object (readonly)
Returns the value of attribute base_commit.
13 14 15 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 13 def base_commit @base_commit end |
#credentials ⇒ Object (readonly)
Returns the value of attribute credentials.
13 14 15 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 13 def credentials @credentials end |
#files ⇒ Object (readonly)
Returns the value of attribute files.
13 14 15 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 13 def files @files end |
#old_commit ⇒ Object (readonly)
Returns the value of attribute old_commit.
13 14 15 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 13 def old_commit @old_commit end |
#pull_request_number ⇒ Object (readonly)
Returns the value of attribute pull_request_number.
13 14 15 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 13 def pull_request_number @pull_request_number end |
#source ⇒ Object (readonly)
Returns the value of attribute source.
13 14 15 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 13 def source @source end |
Instance Method Details
#update ⇒ Object
26 27 28 29 30 |
# File 'lib/dependabot/pull_request_updater/azure.rb', line 26 def update return unless pull_request_exists? && source_branch_exists? update_source_branch end |