Skip to content

Commit

Permalink
#86: Jira.raw - ability to send request to the ticketing system using…
Browse files Browse the repository at this point in the history
… raw client
  • Loading branch information
dgroup committed May 7, 2020
1 parent 282fa76 commit 4275136
Showing 1 changed file with 11 additions and 2 deletions.
13 changes: 11 additions & 2 deletions lib/lazylead/system/jira.rb
Original file line number Diff line number Diff line change
Expand Up @@ -32,7 +32,7 @@ module Lazylead
# Copyright:: Copyright (c) 2019-2020 Yurii Dubinka
# License:: MIT
class Jira
# @todo #57/DEV The debug method should be moved outsited of ctor.
# @todo #57/DEV The debug method should be moved outside of ctor.
# This was moved here from 'client' method because Rubocop failed the build
# due to 'Metrics/AbcSize' violation.
def initialize(opts, salt = NoSalt.new, log = Log::NOTHING)
Expand All @@ -45,7 +45,16 @@ def initialize(opts, salt = NoSalt.new, log = Log::NOTHING)
end

def issues(jql, opts = {})
client.Issue.jql(jql, opts).map { |i| Lazylead::Issue.new(i) }
raw do |jira|
jira.Issue.jql(jql, opts).map { |i| Lazylead::Issue.new(i) }
end
end

# Execute request to the ticketing system using raw client.
# For Jira the raw client is 'jira-ruby' gem.
def raw
raise "ll-06: No block given to method" unless block_given?
yield client
end

private
Expand Down

2 comments on commit 4275136

@0pdd
Copy link
Collaborator

@0pdd 0pdd commented on 4275136 May 7, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Puzzle 57-e2f91111 disappeared from lib/lazylead/system/jira.rb, that's why I closed #81. Please, remember that the puzzle was not necessarily removed in this particular commit. Maybe it happened earlier, but we discovered this fact only now.

@0pdd
Copy link
Collaborator

@0pdd 0pdd commented on 4275136 May 7, 2020

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Puzzle 57-65436478 discovered in lib/lazylead/system/jira.rb and submitted as #87. Please, remember that the puzzle was not necessarily added in this particular commit. Maybe it was added earlier, but we discovered it only now.

Please sign in to comment.