ip2location_ruby 0.3.1 → 0.3.2

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 7a77cea3d4db0d13507309bae631c934471fc900
4
- data.tar.gz: 7ba6b5dd0453a8970b6bfcbe455c4a48813abbaf
3
+ metadata.gz: d572eaea90429a8a3eff55e48f0986a58ef371db
4
+ data.tar.gz: 4e4de29d32aa884a910948d5844a2bf05fcd0ed5
5
5
  SHA512:
6
- metadata.gz: 35f296bb61cbc31454e1d7e50d5ab4eef7e8ba8f1766604c0045b1949e72b62dcac62b29139b73b10b067015b2d3b1c5e5812a7574f4c20face79684392ffcbc
7
- data.tar.gz: fdb0cc4c16bf718290e2a4e73cd5519ab3e5298668ae481b7411472b558a4ed3cd6703d5f485c975736364b814810a8274dbd54d78d2037fe305e3d0427332b1
6
+ metadata.gz: e4b287394f962b7a620fbb770408b0d50af2dafaaff80d946395f29a073dae97b2dbbf6e2981e48de93ec8d9eb156ec933900c76c509e4596f66141ef46c0071
7
+ data.tar.gz: 06ecd794eba9697f7f3035de7579e8021e76a7415cacea7be9c78307d64d9ba9e8943d8b5a4a698e6f003150e69533485983da0a53b23bc6d9f7bd6dee082f0e
data/VERSION CHANGED
@@ -1 +1 @@
1
- 0.3.1
1
+ 0.3.2
@@ -2,16 +2,16 @@
2
2
  # DO NOT EDIT THIS FILE DIRECTLY
3
3
  # Instead, edit Jeweler::Tasks in Rakefile, and run 'rake gemspec'
4
4
  # -*- encoding: utf-8 -*-
5
- # stub: ip2location_ruby 0.3.1 ruby lib
5
+ # stub: ip2location_ruby 0.3.2 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "ip2location_ruby"
9
- s.version = "0.3.1"
9
+ s.version = "0.3.2"
10
10
 
11
11
  s.required_rubygems_version = Gem::Requirement.new(">= 0") if s.respond_to? :required_rubygems_version=
12
12
  s.require_paths = ["lib"]
13
13
  s.authors = ["Vincent.Z"]
14
- s.date = "2014-01-09"
14
+ s.date = "2014-07-04"
15
15
  s.description = "the ip2location ruby library"
16
16
  s.email = "zhu1230@gmail.com"
17
17
  s.extra_rdoc_files = [
@@ -41,7 +41,7 @@ Gem::Specification.new do |s|
41
41
  ]
42
42
  s.homepage = "http://github.com/zhu1230/ip2location"
43
43
  s.licenses = ["MIT"]
44
- s.rubygems_version = "2.2.0"
44
+ s.rubygems_version = "2.2.2"
45
45
  s.summary = "the ip2location ruby library"
46
46
 
47
47
  if s.respond_to? :specification_version then
@@ -1,7 +1,7 @@
1
1
  class I2lFloatData < BinData::BasePrimitive
2
2
 
3
3
  def read_and_return_value(io)
4
- addr = BinData::Uint32le.read(io)
4
+ addr = BinData::FloatLe.read(io)
5
5
  end
6
6
 
7
7
  end
@@ -7,4 +7,12 @@ describe "Ip2location" do
7
7
  record.should_not be_nil
8
8
  record.country_short.should == 'US'
9
9
  end
10
+
11
+ # this need spec/assets/IP2LOCATION-LITE-DB5.bin file which too big to include in this test.
12
+
13
+ # it "should get float value of attitude" do
14
+ # i2l = Ip2location.new.open(File.dirname(__FILE__) + "/assets/IP2LOCATION-LITE-DB5.bin")
15
+ # record = i2l.get_all('192.110.164.88')
16
+ # record['latitude'].should eq(33.44837951660156)
17
+ # end
10
18
  end
data/spec/spec_helper.rb CHANGED
@@ -10,3 +10,4 @@ Dir["#{File.dirname(__FILE__)}/support/**/*.rb"].each {|f| require f}
10
10
  RSpec.configure do |config|
11
11
 
12
12
  end
13
+ require 'awesome_print'
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: ip2location_ruby
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.3.1
4
+ version: 0.3.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Vincent.Z
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2014-01-09 00:00:00.000000000 Z
11
+ date: 2014-07-04 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: bindata
@@ -155,7 +155,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
155
155
  version: '0'
156
156
  requirements: []
157
157
  rubyforge_project:
158
- rubygems_version: 2.2.0
158
+ rubygems_version: 2.2.2
159
159
  signing_key:
160
160
  specification_version: 4
161
161
  summary: the ip2location ruby library