geonames_local 0.3.1 → 0.5.0

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -1,7 +0,0 @@
1
- module Geonames
2
- module Mongo
3
- class City < Geonames::Spot
4
- set_coll "cities"
5
- end
6
- end
7
- end
@@ -1,18 +0,0 @@
1
- module Geonames
2
- class Province
3
- attr_accessor :code, :name, :gid
4
-
5
- def self.all
6
- Tokyo.new.all({ :kind => "province" }).map do |c|
7
- new(c)
8
- end
9
- end
10
-
11
- def initialize(params)
12
- @code = params["code"]
13
- @name = params["name"]
14
- @gid = params["gid"]
15
- end
16
-
17
- end
18
- end
@@ -1,19 +0,0 @@
1
- # -*- coding: utf-8 -*-
2
- require File.expand_path(File.dirname(__FILE__) + '/../../spec_ar_helper')
3
-
4
- class User < ActiveRecord::Base
5
- belongs_to :city
6
- end
7
-
8
-
9
- describe "Active Record Stuff" do
10
-
11
-
12
- it "should create" do
13
- user = User.new(:name => "Defendor")
14
- user.city = City.first
15
- p City.first
16
- user.save
17
- User.first.city.name.should eql("Sao Tome")
18
- end
19
- end
data/spec/spec.opts DELETED
@@ -1 +0,0 @@
1
- --color