Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with
or
.
Download ZIP
Browse files

Merge branch 'spec-activerecord' of github.com:winton/gem_template

Conflicts:
	require.rb
	spec/spec_helper.rb
  • Loading branch information...
commit 57b636c371c64ac48dc75c3cbc37674234b3814b 2 parents 4b41800 + a3be535
@winton authored
View
2  .gitignore
@@ -3,4 +3,6 @@
*.gemspec
coverage
pkg
+spec/config/database.yml
+spec/log
tmp
View
6 log/development.log
@@ -0,0 +1,6 @@
+ SQL (0.2ms) SET SQL_AUTO_IS_NULL=0
+ User Load (59.6ms) SELECT * FROM `users` ORDER BY users.id DESC LIMIT 1
+ User Columns (21.6ms) SHOW FIELDS FROM `users`
+ SQL (0.3ms) SET SQL_AUTO_IS_NULL=0
+ SQL (0.3ms) SHOW TABLES
+ User Columns (13.0ms) SHOW FIELDS FROM `users`
View
9 require.rb
@@ -29,14 +29,21 @@
end
rakefile do
+ gem(:active_wrapper)
gem(:rake) { require 'rake/gempackagetask' }
gem(:rspec) { require 'spec/rake/spectask' }
require 'require/tasks'
end
spec_helper do
+ gem(:active_wrapper)
require 'require/spec_helper'
require 'lib/periodic_counter'
require 'pp'
end
-end
+
+ spec_rakefile do
+ gem(:rake)
+ gem(:active_wrapper) { require 'active_wrapper/tasks' }
+ end
+end
View
10 spec/Rakefile
@@ -0,0 +1,10 @@
+require File.expand_path("#{File.dirname(__FILE__)}/../require")
+Require.spec_rakefile!
+
+begin
+ ActiveWrapper::Tasks.new(
+ :base => File.dirname(__FILE__),
+ :env => ENV['ENV']
+ )
+rescue Exception
+end
View
6 spec/config/database.yml.example
@@ -0,0 +1,6 @@
+test:
+ adapter: mysql
+ database: gem_template
+ username: root
+ password:
+ host: localhost
View
6 spec/spec_helper.rb
@@ -3,3 +3,9 @@
Spec::Runner.configure do |config|
end
+
+$db, $log, $mail = ActiveWrapper.new(
+ :base => File.dirname(__FILE__),
+ :env => 'test'
+)
+$db.establish_connection
Please sign in to comment.
Something went wrong with that request. Please try again.