heythisisnate-max_mind 0.1.0 → 0.1.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.1.0
1
+ 0.1.1
@@ -1,8 +1,8 @@
1
1
  module MaxMind
2
2
  class Service
3
- class_inheritable_accessor :license_key
3
+ cattr_accessor :license_key
4
4
 
5
- class_inheritable_accessor :base_url
5
+ cattr_accessor :base_url
6
6
  self.base_url = 'http://geoip1.maxmind.com'
7
7
 
8
8
  class_inheritable_accessor :base_path
@@ -2,11 +2,11 @@
2
2
 
3
3
  Gem::Specification.new do |s|
4
4
  s.name = %q{max_mind}
5
- s.version = "0.1.0"
5
+ s.version = "0.1.1"
6
6
 
7
7
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
8
8
  s.authors = ["P J Kelly", "Nate Clark"]
9
- s.date = %q{2009-05-11}
9
+ s.date = %q{2009-05-13}
10
10
  s.description = %q{Ruby library for interacting with the MaxMind GeoIP Web Services}
11
11
  s.email = %q{nate@nateclark.com}
12
12
  s.extra_rdoc_files = [
@@ -2,6 +2,10 @@ require File.dirname(__FILE__) + '/spec_helper.rb'
2
2
 
3
3
  describe MaxMind::Service do
4
4
 
5
+ before(:each) do
6
+ MaxMind::Service.license_key = nil
7
+ end
8
+
5
9
  describe "class attributes" do
6
10
 
7
11
  it "should have a @@base_url defined" do
@@ -50,6 +54,24 @@ describe MaxMind::Service do
50
54
  end
51
55
 
52
56
  end
57
+
58
+ describe ".license_key=" do
59
+
60
+ it "allows the service subclass to inherit the license key" do
61
+ MaxMind::Service.license_key = 'abcdefg'
62
+ MaxMind::CityService.license_key.should == 'abcdefg'
63
+ end
64
+
65
+ end
66
+
67
+ describe ".base_url=" do
68
+ it "allows the service subclass to inherit the license key" do
69
+ MaxMind::Service.base_url = 'http://geoip3.maxmind.com'
70
+ MaxMind::CityService.base_url.should == 'http://geoip3.maxmind.com'
71
+ end
72
+ end
73
+
74
+
53
75
 
54
76
  describe "instance methods" do
55
77
 
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: heythisisnate-max_mind
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.0
4
+ version: 0.1.1
5
5
  platform: ruby
6
6
  authors:
7
7
  - P J Kelly
@@ -10,7 +10,7 @@ autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
12
 
13
- date: 2009-05-11 00:00:00 -07:00
13
+ date: 2009-05-13 00:00:00 -07:00
14
14
  default_executable:
15
15
  dependencies: []
16
16