Permalink
Browse files

fix test failures

  • Loading branch information...
1 parent b5cf28d commit c07927cf238423a01a065d27d4662501a6f9b35a @technoweenie technoweenie committed Sep 27, 2012
Showing with 4 additions and 3 deletions.
  1. +3 −3 services/ontime.rb
  2. +1 −0 test/ontime_test.rb
View
@@ -20,10 +20,10 @@ def receive_push
resp = http_get "api/version"
version = JSON.parse(resp.body)['data']
- if (version['major'] == 11 and version['minor'] >= 1) or (version['major'] == 12 and version['major'] < 2)
+ if (version['major'] == 11 and version['minor'] >= 1) or (version['major'] == 12 and version['minor'] < 2)
result = http_post "api/github", :payload => payload.to_json, :hash_data => hash_data, :source => :github
- elsif (version['major'] == 12 and version['minor'] >= 2) or version['major'] > 12
- result = http_post "api/v1/github", :payload => payload.to_json, :hash_data => hash_data, :source => :github
+ elsif (version['major'] == 12 and version['minor'] >= 2) or version['major'] > 12
+ result = http_post "api/v1/github", :payload => payload.to_json, :hash_data => hash_data, :source => :github
else
raise_config_error "Unexpected API version. Please update to the latest version of OnTime to use this service."
end
View
@@ -1,3 +1,4 @@
+require File.expand_path('../helper', __FILE__)
require 'cgi'
class OnTimeTest < Service::TestCase

0 comments on commit c07927c

Please sign in to comment.