File tree 3 files changed +8
-10
lines changed
3 files changed +8
-10
lines changed Original file line number Diff line number Diff line change @@ -15,11 +15,10 @@ gemfile:
15
15
env : DATABASE_URL=postgres://postgres@localhost/torque_postgresql_test
16
16
17
17
before_script :
18
- - psql -c 'create database torque_postgresql_test;' -U postgres -h localhost
18
+ - psql -c 'DROP DATABASE IF EXISTS torque_postgresql_test;' -U postgres -h localhost
19
+ - psql -c 'CREATE DATABASE torque_postgresql_test;' -U postgres -h localhost
20
+ - bundle exec rake dump
19
21
20
- # notifications:
21
- # email:
22
-
23
22
addons :
24
23
postgresql : ' 9.6'
25
24
code_climate :
Original file line number Diff line number Diff line change @@ -14,13 +14,16 @@ RDoc::Task.new(:rdoc) do |rdoc|
14
14
rdoc . rdoc_files . include ( 'lib/**/*.rb' )
15
15
end
16
16
17
- desc 'Prints a schema dump of the test database '
18
- task :dump do |t |
17
+ desc 'Initialize the local environment '
18
+ task :environment do |t |
19
19
lib = File . expand_path ( '../lib' , __FILE__ )
20
20
spec = File . expand_path ( '../spec' , __FILE__ )
21
21
$LOAD_PATH. unshift ( lib ) unless $LOAD_PATH. include? ( lib )
22
22
$LOAD_PATH. unshift ( spec ) unless $LOAD_PATH. include? ( spec )
23
+ end
23
24
25
+ desc 'Prints a schema dump of the test database'
26
+ task dump : :environment do |t |
24
27
require 'byebug'
25
28
require 'spec_helper'
26
29
ActiveRecord ::SchemaDumper . dump
Original file line number Diff line number Diff line change 15
15
cache . instance_variable_set ( :@inheritance_loaded , false )
16
16
cache . instance_variable_set ( :@inheritance_dependencies , { } )
17
17
cache . instance_variable_set ( :@inheritance_associations , { } )
18
-
19
- ActivityBook . instance_variable_set ( :@physically_inherited , nil )
20
- ActivityPost . instance_variable_set ( :@physically_inherited , nil )
21
- ActivityPost ::Sample . instance_variable_set ( :@physically_inherited , nil )
22
18
end
23
19
24
20
load File . join ( 'schema.rb' )
You can’t perform that action at this time.
0 commit comments