standalone_migrations 4.0.4 → 4.0.5

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: b534d9945d6fcdb1f23962f722a928498c9972a7
4
- data.tar.gz: cc85231eb00daaf6cbe2f5429110e8ab8ba3dbb0
3
+ metadata.gz: 6d3258d9b559502848532e889935b9718f7f1c5f
4
+ data.tar.gz: f266df133af123b561fdec6fda819d9ec75029ac
5
5
  SHA512:
6
- metadata.gz: b78b446ff03a70bb8cbdc8b0b8359c89844a599e1f45fc6578c93761d1102111a44f450072a4bd4d365631a441599fe4a4e7f832df7a8ff73c752588e5a12739
7
- data.tar.gz: 93431df82ebf90193ecfd3ffc7376d7bdd409cca1933336bbd7065ae06b525589af62d2cbff85b9c4a06a7ff1259f2e8469f1b8d48777d1452ac82befc4112c3
6
+ metadata.gz: 2770df6a06b86997bb9ad3a540d769cdf33463ce59be857a20ea12163791452b64efca27185fb9adf1df7d33c1c3c042796f1f5a6a8701be24fef06bf44c35df
7
+ data.tar.gz: 139c1b29f128c627c54b2f82f1721bc3a8d1fd1c150f018951a433845362403021dc241fb47f5bb3ee3eec0c1b67cf4dc75ab3efef5f90f0854840e12e954ac2
data/VERSION CHANGED
@@ -1 +1 @@
1
- 4.0.4
1
+ 4.0.5
@@ -21,7 +21,7 @@ module StandaloneMigrations
21
21
 
22
22
  class Configurator
23
23
  def self.load_configurations
24
- @standalone_configs ||= Configurator.new.config
24
+ self.new
25
25
  @env_config ||= Rails.application.config.database_configuration
26
26
  ActiveRecord::Base.configurations = @env_config
27
27
  @env_config
@@ -7,7 +7,7 @@ module StandaloneMigrations
7
7
  paths = Rails.application.config.paths
8
8
  paths.add "config/database", :with => configurator.config
9
9
  paths.add "db/migrate", :with => configurator.migrate_dir
10
- paths.add "db/seeds", :with => configurator.seeds
10
+ paths.add "db/seeds.rb", :with => configurator.seeds
11
11
  end
12
12
 
13
13
  def load_tasks
@@ -303,6 +303,27 @@ test:
303
303
  run("rake db:seed").should =~ /LOADEDDD/
304
304
  end
305
305
 
306
+ describe 'with non-default seed file' do
307
+ let(:yaml_hash) do
308
+ {
309
+ "db" => {
310
+ "seeds" => "db/seeds2.rb",
311
+ }
312
+ }
313
+ end
314
+
315
+ before do
316
+ write(".standalone_migrations", yaml_hash.to_yaml)
317
+ end
318
+
319
+
320
+ it "loads" do
321
+ write("db/seeds2.rb", "puts 'LOADEDDD'")
322
+ run("rake db:seed").should =~ /LOADEDDD/
323
+ end
324
+ end
325
+
326
+
306
327
  it "does nothing without seeds" do
307
328
  run("rake db:seed").length.should == 0
308
329
  end
@@ -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: standalone_migrations 4.0.4 ruby lib
5
+ # stub: standalone_migrations 4.0.5 ruby lib
6
6
 
7
7
  Gem::Specification.new do |s|
8
8
  s.name = "standalone_migrations"
9
- s.version = "4.0.4"
9
+ s.version = "4.0.5"
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 = ["Todd Huss", "Michael Grosser"]
14
- s.date = "2016-07-17"
14
+ s.date = "2016-08-05"
15
15
  s.email = "thuss@gabrito.com"
16
16
  s.extra_rdoc_files = [
17
17
  "LICENSE",
metadata CHANGED
@@ -1,7 +1,7 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: standalone_migrations
3
3
  version: !ruby/object:Gem::Version
4
- version: 4.0.4
4
+ version: 4.0.5
5
5
  platform: ruby
6
6
  authors:
7
7
  - Todd Huss
@@ -9,7 +9,7 @@ authors:
9
9
  autorequire:
10
10
  bindir: bin
11
11
  cert_chain: []
12
- date: 2016-07-17 00:00:00.000000000 Z
12
+ date: 2016-08-05 00:00:00.000000000 Z
13
13
  dependencies:
14
14
  - !ruby/object:Gem::Dependency
15
15
  name: rake