chartbeat 0.2.0 → 0.2.1

Sign up to get free protection for your applications and to get access to all the features.
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.2.0
1
+ 0.2.1
@@ -5,7 +5,7 @@
5
5
 
6
6
  Gem::Specification.new do |s|
7
7
  s.name = %q{chartbeat}
8
- s.version = "0.2.0"
8
+ s.version = "0.2.1"
9
9
 
10
10
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
11
11
  s.authors = ["Al Shaw"]
@@ -8,11 +8,11 @@ class Chartbeat
8
8
  DASHAPI_METHODS = [:alerts, :snapshots, :stats, :data_series, :day_data_series]
9
9
  DEFAULT_ARG_VALS = {:path => '/', :keys => 'n', :types => 'n', :since => YESTERDAY,
10
10
  :timestamp => YESTERDAY, :days => 1, :minutes => 20, :type => 'path',
11
- :breaks => 'n'}
11
+ :breaks => 'n', :limit => 10}
12
12
 
13
13
  # c = Chartbeat.new :apikey => 'yourkey', :host => 'yourdomain.com'
14
14
  def initialize(opts = {})
15
- raise RuntimeError, "You must provide an API key or host" unless opts[:apikey] && opts[:host]
15
+ raise RuntimeError, "You must provide an API key and host" unless opts[:apikey] && opts[:host]
16
16
  @apikey = opts[:apikey]
17
17
  @host = opts[:host]
18
18
  end
@@ -16,7 +16,7 @@ def fixture_file(filename)
16
16
  end
17
17
 
18
18
  def register_uri(uri, method)
19
- query_string = "?breaks=n&type=path&types=n&path=%2F&since=#{Chartbeat::YESTERDAY}&apikey=fake_key&timestamp=#{Chartbeat::YESTERDAY}&days=1&keys=n&minutes=20&host=fakehost.com"
19
+ query_string = "?breaks=n&type=path&types=n&path=%2F&since=#{Chartbeat::YESTERDAY}&limit=10&apikey=fake_key&timestamp=#{Chartbeat::YESTERDAY}&days=1&keys=n&minutes=20&host=fakehost.com"
20
20
  FakeWeb.register_uri(:get, "#{uri}#{query_string}", :body => fixture_file("#{method}.json"))
21
21
  end
22
22
 
metadata CHANGED
@@ -1,13 +1,13 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: chartbeat
3
3
  version: !ruby/object:Gem::Version
4
- hash: 23
4
+ hash: 21
5
5
  prerelease: false
6
6
  segments:
7
7
  - 0
8
8
  - 2
9
- - 0
10
- version: 0.2.0
9
+ - 1
10
+ version: 0.2.1
11
11
  platform: ruby
12
12
  authors:
13
13
  - Al Shaw