Skip to content

Commit

Permalink
initial clean
Browse files Browse the repository at this point in the history
  • Loading branch information
grosser committed Mar 28, 2009
1 parent d1d628e commit 7dcb182
Show file tree
Hide file tree
Showing 28 changed files with 133 additions and 4,128 deletions.
54 changes: 0 additions & 54 deletions Manifest.txt

This file was deleted.

63 changes: 63 additions & 0 deletions README.markdown
Original file line number Diff line number Diff line change
@@ -0,0 +1,63 @@
Autotest is a continous testing facility meant to be used during
development.
As soon as you save a file, autotest will run the corresponding dependent tests.

REQUIREMENTS
============
* Ruby 1.6+, JRuby 1.1.2+, or rubinius
* Test::Unit or miniunit
* rubygems
* diff.exe on windoze. Try http://gnuwin32.sourceforge.net/packages.html

INSTALL
=======
It is recommended to uninstall ZenTest first, otherwise I do not know what happens...
sudo gem uninstall ZenTest
You can install it from github, but then many solutions that build on autotest will fail unless you use `require 'grosser-autotest'`:
sudo gem install grosser-autotest -s http://gems.github.com
It may be better to install it from source:
git clone git://github.com/grosser/autotest.git
cd autotest
rake install

TODO
====
- cleanup bin/unit_diff
- add gnome notification library


LICENSE
=======

###This is only ripped from ZenTest
Ripper: [Michael Grosser](http://pragmatig.wordpress.com)

### ZenTest Authors
- http://www.zenspider.com/ZSS/Products/ZenTest/
- http://rubyforge.org/projects/zentest/
- ryand-ruby@zenspider.com


(The MIT License)

Copyright (c) 2001-2006 Ryan Davis, Eric Hodel, Zen Spider Software

Permission is hereby granted, free of charge, to any person obtaining
a copy of this software and associated documentation files (the
"Software"), to deal in the Software without restriction, including
without limitation the rights to use, copy, modify, merge, publish,
distribute, sublicense, and/or sell copies of the Software, and to
permit persons to whom the Software is furnished to do so, subject to
the following conditions:

The above copyright notice and this permission notice shall be
included in all copies or substantial portions of the Software.

THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.

109 changes: 0 additions & 109 deletions README.txt

This file was deleted.

61 changes: 25 additions & 36 deletions Rakefile
Original file line number Diff line number Diff line change
@@ -1,25 +1,26 @@
# -*- ruby -*-

$: << 'lib'

require 'rubygems'
require 'hoe'

Hoe.add_include_dirs("../../minitest/dev/lib")

require './lib/zentest.rb'

Hoe.new("ZenTest", ZenTest::VERSION) do |zentest|
zentest.developer('Ryan Davis', 'ryand-ruby@zenspider.com')
zentest.developer('Eric Hodel', 'drbrain@segment7.net')
$LOAD_PATH << 'lib'

zentest.testlib = :minitest
#TODO generic... test_*
desc "run tests"
task :default do
puts `ruby test/test_autotest.rb`
puts `ruby test/test_unit_diff.rb`
end

desc "run autotest on itself"
task :autotest do
ruby "-Ilib -w ./bin/autotest"
end

#TODO exclude /usr/ folder
#TODO improve coverage ? only 20% atm...
desc "show rcov report"
task :rcov_info do
ruby "-Ilib -S rcov --text-report --save coverage.info test/test_*.rb"
end

desc "update example_dot_autotest.rb with all possible constants"
task :update do
system "p4 edit example_dot_autotest.rb"
File.open "example_dot_autotest.rb", "w" do |f|
Expand Down Expand Up @@ -48,26 +49,14 @@ task :update do
system "p4 diff -du example_dot_autotest.rb"
end

task :sort do
begin
sh 'for f in lib/*.rb; do echo $f; grep "^ *def " $f | grep -v sort=skip > x; sort x > y; echo $f; echo; diff x y; done'
sh 'for f in test/test_*.rb; do echo $f; grep "^ *def.test_" $f > x; sort x > y; echo $f; echo; diff x y; done'
ensure
sh 'rm x y'
begin
require 'jeweler'
Jeweler::Tasks.new do |gem|
gem.name = "autotest"
gem.summary = "Autotest, without ZenTest"
gem.homepage = "http://github.com/grosser/autotest"
gem.authors = ["Ryan Davis"]
end
end

task :rcov_info do
ruby "-Ilib -S rcov --text-report --save coverage.info test/test_*.rb"
end

task :rcov_overlay do
rcov, eol = Marshal.load(File.read("coverage.info")).last[ENV["FILE"]], 1
puts rcov[:lines].zip(rcov[:coverage]).map { |line, coverage|
bol, eol = eol, eol + line.length
[bol, eol, "#ffcccc"] unless coverage
}.compact.inspect
end

# vim:syntax=ruby

rescue LoadError
puts "Jeweler, or one of its dependencies, is not available. Install it with: sudo gem install technicalpickles-jeweler -s http://gems.github.com"
end
4 changes: 4 additions & 0 deletions VERSION.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,4 @@
---
:major: 4
:minor: 0
:patch: 1
Loading

0 comments on commit 7dcb182

Please sign in to comment.