jp_prefecture 0.8.0 → 1.0.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
data/spec/spec_helper.rb DELETED
@@ -1,30 +0,0 @@
1
- # coding: utf-8
2
- require 'jp_prefecture'
3
- require "active_record"
4
-
5
- RSpec.configure do |config|
6
- config.before(:suite) do
7
- setup_db
8
- end
9
-
10
- config.after(:suite) do
11
- teardown_db
12
- end
13
- end
14
-
15
- def setup_db
16
- ActiveRecord::Base.establish_connection adapter: "sqlite3", database: ":memory:"
17
-
18
- ActiveRecord::Schema.define(version: 1) do
19
- create_table :places do |t|
20
- t.integer :prefecture_code
21
- t.integer :prefecture_id
22
- end
23
- end
24
- end
25
-
26
- def teardown_db
27
- ActiveRecord::Base.connection.tables.each do |table|
28
- ActiveRecord::Base.connection.drop_table(table)
29
- end
30
- end
@@ -1,10 +0,0 @@
1
- # coding: utf-8
2
- require 'spec_helper'
3
-
4
- describe JpPrefecture::ZipMapping do
5
- describe '.data' do
6
- it '都道府県の数が47であること' do
7
- expect(described_class.data.count).to eq 47
8
- end
9
- end
10
- end