Skip to content

HTTPS clone URL

Subversion checkout URL

You can clone with HTTPS or Subversion.

Download ZIP
Newer
Older
100644 37 lines (28 sloc) 0.785 kb
a038b3d @jeremy Make Rakefile usable outside of base dir
jeremy authored
1 dir = File.dirname(__FILE__)
66d713f @josh License, version, and gemspec for ActiveModel. Ship it!
josh authored
2
b7c6cef @technoweenie tweak activemodel load order a bit
technoweenie authored
3 require 'rake/testtask'
3baf810 @jakehow Add rdoc task to activemodel. [#156 state:resolved]
jakehow authored
4
b7c6cef @technoweenie tweak activemodel load order a bit
technoweenie authored
5 task :default => :test
6
6094e65 @josh We won't be publishing tars and zips anymore
josh authored
7 Rake::TestTask.new do |t|
1a2fba1 @josh don't expand test path
josh authored
8 t.libs << "test"
e462021 @matthewd Revert "For now, we will keep sorting the tests."
matthewd authored
9 t.test_files = Dir.glob("#{dir}/test/cases/**/*_test.rb")
6dc9ad8 @josh Fix warnings in AMo
josh authored
10 t.warning = true
bfb84cf @arunagw Verbose output for tests.
arunagw authored
11 t.verbose = true
1fac7b7 @robin850 Follow up to #16613
robin850 authored
12 t.ruby_opts = ["--dev"] if defined?(JRUBY_VERSION)
b7c6cef @technoweenie tweak activemodel load order a bit
technoweenie authored
13 end
66d713f @josh License, version, and gemspec for ActiveModel. Ship it!
josh authored
14
bbb3e5a @jeremy Unify test:isolated across components and run by default at toplevel
jeremy authored
15 namespace :test do
16 task :isolated do
17 Dir.glob("#{dir}/test/**/*_test.rb").all? do |file|
f52832d @arunagw grab executable from rubygems
arunagw authored
18 sh(Gem.ruby, '-w', "-I#{dir}/lib", "-I#{dir}/test", file)
bbb3e5a @jeremy Unify test:isolated across components and run by default at toplevel
jeremy authored
19 end or raise "Failures"
20 end
e8550ee @jeremy Cherry-pick core extensions
jeremy authored
21 end
b7c6cef @technoweenie tweak activemodel load order a bit
technoweenie authored
22
79e9a29 @vijaydev fixes Rake::GemPackageTask deprecation warnings from rake 0.9.0
vijaydev authored
23 require 'rubygems/package_task'
66d713f @josh License, version, and gemspec for ActiveModel. Ship it!
josh authored
24
a038b3d @jeremy Make Rakefile usable outside of base dir
jeremy authored
25 spec = eval(File.read("#{dir}/activemodel.gemspec"))
66d713f @josh License, version, and gemspec for ActiveModel. Ship it!
josh authored
26
79e9a29 @vijaydev fixes Rake::GemPackageTask deprecation warnings from rake 0.9.0
vijaydev authored
27 Gem::PackageTask.new(spec) do |p|
66d713f @josh License, version, and gemspec for ActiveModel. Ship it!
josh authored
28 p.gem_spec = spec
29 end
c1785f3 @jeremy Release using gemcutter gem:push tasks
jeremy authored
30
67f6688 @arunagw Saying gemcutter => rubygems [ci skip]
arunagw authored
31 desc "Release to rubygems"
459ecaf @jeremy Submarine the rake-gemcutter dep in Rakefiles
jeremy authored
32 task :release => :package do
33 require 'rake/gemcutter'
34 Rake::Gemcutter::Tasks.new(spec).define
35 Rake::Task['gem:push'].invoke
36 end
Something went wrong with that request. Please try again.