leankitkanban 0.0.4 → 0.0.5

Sign up to get free protection for your applications and to get access to all the features.
data/Rakefile CHANGED
@@ -2,7 +2,7 @@ require 'rubygems'
2
2
  require 'rake'
3
3
  require 'echoe'
4
4
 
5
- Echoe.new('leankitkanban', '0.0.4') do |p|
5
+ Echoe.new('leankitkanban', '0.0.5') do |p|
6
6
  p.description = "Ruby Wrapper around LeanKitKanban Api"
7
7
  p.url = "http://github.com/mlainez/leankitkanban"
8
8
  p.author = "Marc Lainez"
@@ -2,7 +2,7 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{leankitkanban}
5
- s.version = "0.0.4"
5
+ s.version = "0.0.5"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 1.2") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = [%q{Marc Lainez}]
@@ -6,6 +6,7 @@ module LeanKitKanban
6
6
  ONE_BOARD = "/Boards/{boardID}"
7
7
  IDENTIFIERS = "/Board/{boardID}/GetBoardIdentifiers"
8
8
  NEWER_IF_EXISTS = "/Board/{boardID}/BoardVersion/{versionID}/GetNewerIfExists"
9
+ HISTORY_SINCE = "/Board/{boardID}/BoardVersion/{versionID}/GetBoardHistorySince"
9
10
  REPLY_DATA_KEY = "ReplyData"
10
11
 
11
12
  def self.all
@@ -27,6 +28,11 @@ module LeanKitKanban
27
28
  get(api_call)
28
29
  end
29
30
 
31
+ def self.get_board_history_since(board_id, version_id)
32
+ api_call = HISTORY_SINCE.gsub("{boardID}", board_id.to_s).gsub("{versionID}", version_id.to_s)
33
+ get(api_call)
34
+ end
35
+
30
36
  private
31
37
  def self.get(api_call)
32
38
  url = "#{LeanKitKanban::Config.uri}#{api_call}"
@@ -49,4 +49,17 @@ describe LeanKitKanban::Board do
49
49
  LeanKitKanban::Board.get_newer_if_exists(@board_id, @version_id)
50
50
  end
51
51
  end
52
+
53
+ describe :get_board_history_since do
54
+ before :each do
55
+ @board_id = mock("boardID")
56
+ @version_id = mock("versionID")
57
+ end
58
+
59
+ it "gets a greater version of the board than the one passed" do
60
+ api_call = "/Board/#{@board_id}/BoardVersion/#{@version_id}/GetBoardHistorySince"
61
+ LeanKitKanban::Board.should_receive(:get).with(api_call)
62
+ LeanKitKanban::Board.get_board_history_since(@board_id, @version_id)
63
+ end
64
+ end
52
65
  end
metadata CHANGED
@@ -2,7 +2,7 @@
2
2
  name: leankitkanban
3
3
  version: !ruby/object:Gem::Version
4
4
  prerelease:
5
- version: 0.0.4
5
+ version: 0.0.5
6
6
  platform: ruby
7
7
  authors:
8
8
  - Marc Lainez