webkit-rspec-formatter 2.0.1 → 2.0.2

Sign up to get free protection for your applications and to get access to all the features.
Files changed (62) hide show
  1. data.tar.gz.sig +0 -0
  2. data/History.md +7 -0
  3. data/README.md +10 -20
  4. data/Rakefile +16 -362
  5. metadata +68 -126
  6. metadata.gz.sig +0 -0
  7. data/ChangeLog +0 -81
  8. data/LICENSE +0 -27
  9. data/data/webkit-rspec-formatter/css/textmate-rspec.css +0 -332
  10. data/data/webkit-rspec-formatter/images/clock.png +0 -0
  11. data/data/webkit-rspec-formatter/images/cross_circle.png +0 -0
  12. data/data/webkit-rspec-formatter/images/cross_circle_frame.png +0 -0
  13. data/data/webkit-rspec-formatter/images/cross_octagon.png +0 -0
  14. data/data/webkit-rspec-formatter/images/cross_octagon_frame.png +0 -0
  15. data/data/webkit-rspec-formatter/images/cross_shield.png +0 -0
  16. data/data/webkit-rspec-formatter/images/exclamation.png +0 -0
  17. data/data/webkit-rspec-formatter/images/exclamation_frame.png +0 -0
  18. data/data/webkit-rspec-formatter/images/exclamation_shield.png +0 -0
  19. data/data/webkit-rspec-formatter/images/exclamation_small.png +0 -0
  20. data/data/webkit-rspec-formatter/images/plus_circle.png +0 -0
  21. data/data/webkit-rspec-formatter/images/plus_circle_frame.png +0 -0
  22. data/data/webkit-rspec-formatter/images/question.png +0 -0
  23. data/data/webkit-rspec-formatter/images/question_frame.png +0 -0
  24. data/data/webkit-rspec-formatter/images/question_shield.png +0 -0
  25. data/data/webkit-rspec-formatter/images/question_small.png +0 -0
  26. data/data/webkit-rspec-formatter/images/tick.png +0 -0
  27. data/data/webkit-rspec-formatter/images/tick_circle.png +0 -0
  28. data/data/webkit-rspec-formatter/images/tick_circle_frame.png +0 -0
  29. data/data/webkit-rspec-formatter/images/tick_shield.png +0 -0
  30. data/data/webkit-rspec-formatter/images/tick_small.png +0 -0
  31. data/data/webkit-rspec-formatter/images/tick_small_circle.png +0 -0
  32. data/data/webkit-rspec-formatter/images/ticket.png +0 -0
  33. data/data/webkit-rspec-formatter/images/ticket_arrow.png +0 -0
  34. data/data/webkit-rspec-formatter/images/ticket_exclamation.png +0 -0
  35. data/data/webkit-rspec-formatter/images/ticket_minus.png +0 -0
  36. data/data/webkit-rspec-formatter/images/ticket_pencil.png +0 -0
  37. data/data/webkit-rspec-formatter/images/ticket_plus.png +0 -0
  38. data/data/webkit-rspec-formatter/images/ticket_small.png +0 -0
  39. data/data/webkit-rspec-formatter/js/jquery-1.4.2.min.js +0 -154
  40. data/data/webkit-rspec-formatter/js/textmate-rspec.js +0 -402
  41. data/data/webkit-rspec-formatter/templates/failed.rhtml +0 -35
  42. data/data/webkit-rspec-formatter/templates/footer.rhtml +0 -9
  43. data/data/webkit-rspec-formatter/templates/header.rhtml +0 -35
  44. data/data/webkit-rspec-formatter/templates/page.rhtml +0 -131
  45. data/data/webkit-rspec-formatter/templates/passed.rhtml +0 -10
  46. data/data/webkit-rspec-formatter/templates/pending-fixed.rhtml +0 -25
  47. data/data/webkit-rspec-formatter/templates/pending.rhtml +0 -14
  48. data/lib/rspec/core/formatters/web_kit.rb +0 -4
  49. data/lib/rspec/core/formatters/webkit.rb +0 -222
  50. data/lib/rspec/mate/runner.rb +0 -65
  51. data/rake/191_compat.rb +0 -26
  52. data/rake/dependencies.rb +0 -76
  53. data/rake/documentation.rb +0 -123
  54. data/rake/helpers.rb +0 -502
  55. data/rake/hg.rb +0 -287
  56. data/rake/manual.rb +0 -787
  57. data/rake/packaging.rb +0 -129
  58. data/rake/publishing.rb +0 -341
  59. data/rake/style.rb +0 -62
  60. data/rake/svn.rb +0 -668
  61. data/rake/testing.rb +0 -151
  62. data/rake/verifytask.rb +0 -64
@@ -1,151 +0,0 @@
1
- #
2
- # Rake tasklib for testing tasks
3
-
4
- #
5
- # Authors:
6
- # * Michael Granger <ged@FaerieMUD.org>
7
- #
8
-
9
- unless defined?( COVERAGE_MINIMUM )
10
- if ENV['COVVERAGE_MINIMUM']
11
- COVERAGE_MINIMUM = Float( ENV['COVERAGE_MINIMUM'] )
12
- else
13
- COVERAGE_MINIMUM = 85.0
14
- end
15
- end
16
- SPEC_FILES = [] unless defined?( SPEC_FILES )
17
- TEST_FILES = [] unless defined?( TEST_FILES )
18
-
19
- COMMON_RSPEC_OPTS = [] unless defined?( COMMON_RSPEC_OPTS )
20
-
21
- COVERAGE_TARGETDIR = BASEDIR + 'coverage' unless defined?( COVERAGE_TARGETDIR )
22
- RCOV_EXCLUDES = 'spec,tests,/Library/Ruby,/var/lib,/usr/local/lib' unless
23
- defined?( RCOV_EXCLUDES )
24
-
25
-
26
- desc "Run all defined tests"
27
- task :test do
28
- unless SPEC_FILES.empty?
29
- log "Running specs"
30
- Rake::Task['spec:quiet'].invoke
31
- end
32
-
33
- unless TEST_FILES.empty?
34
- log "Running unit tests"
35
- Rake::Task[:unittests].invoke
36
- end
37
- end
38
-
39
-
40
- ### RSpec specifications
41
- begin
42
- gem 'rspec', '>= 2.0.0'
43
-
44
- require 'rspec'
45
- require 'rspec/core/rake_task'
46
-
47
- ### Task: spec
48
- desc "Run specs"
49
- task :spec => 'spec:doc'
50
-
51
- namespace :spec do
52
- desc "Run rspec every time there's a change to one of the files"
53
- task :autotest do
54
- require 'autotest'
55
- Autotest.add_discovery { "rspec2" }
56
- Autotest.run
57
- end
58
-
59
- desc "Generate regular color 'doc' spec output"
60
- RSpec::Core::RakeTask.new( :doc ) do |task|
61
- task.rspec_opts = COMMON_RSPEC_OPTS + ['-f', 'd', '-c']
62
- end
63
-
64
- desc "Generate spec output with profiling"
65
- RSpec::Core::RakeTask.new( :profile ) do |task|
66
- task.rspec_opts = COMMON_RSPEC_OPTS + ['-f', 'p', '-p']
67
- end
68
-
69
- desc "Generate quiet non-colored plain-text output"
70
- RSpec::Core::RakeTask.new( :quiet ) do |task|
71
- task.rspec_opts = COMMON_RSPEC_OPTS + ['-f', 'p']
72
- end
73
-
74
- desc "Generate HTML output"
75
- RSpec::Core::RakeTask.new( :html ) do |task|
76
- task.rspec_opts = COMMON_RSPEC_OPTS + ['-f', 'h']
77
- end
78
-
79
-
80
- end
81
-
82
- ### Task: coverage (via RCov)
83
- desc "Build test coverage reports"
84
- RSpec::Core::RakeTask.new( :coverage ) do |task|
85
- task.ruby_opts = [ "-I#{LIBDIR}" ]
86
- task.rspec_opts = ['-f', 'p', '-b']
87
- task.rcov_opts = RCOV_OPTS
88
- task.rcov = true
89
- end
90
-
91
- ### Task: rcov
92
- task :rcov => :coverage
93
-
94
- ### Other coverage tasks
95
- namespace :coverage do
96
- desc "Generate a detailed text coverage report"
97
- RSpec::Core::RakeTask.new( :text ) do |task|
98
- task.rcov_opts = RCOV_OPTS + ['--text-report']
99
- task.rcov = true
100
- end
101
-
102
- desc "Show differences in coverage from last run"
103
- RSpec::Core::RakeTask.new( :diff ) do |task|
104
- task.rspec_opts = ['-f', 'p', '-b']
105
- task.rcov_opts = RCOV_OPTS - ['--save'] + ['--text-coverage-diff']
106
- task.rcov = true
107
- end
108
-
109
- desc "Run RCov in 'spec-only' mode to check coverage from specs"
110
- RSpec::Core::RakeTask.new( :speconly ) do |task|
111
- task.rcov_opts = ['--exclude', RCOV_EXCLUDES, '--text-report', '--save']
112
- task.rcov = true
113
- end
114
- end
115
-
116
- CLOBBER.include( COVERAGE_TARGETDIR )
117
- rescue LoadError => err
118
- task :no_rspec do
119
- $stderr.puts "Specification tasks not defined: %s" % [ err.message ]
120
- end
121
-
122
- task :spec => :no_rspec
123
- namespace :spec do
124
- task :autotest => :no_rspec
125
- task :doc => :no_rspec
126
- task :profile => :no_rspec
127
- task :quiet => :no_rspec
128
- task :html => :no_rspec
129
- end
130
- end
131
-
132
-
133
- ### Test::Unit tests
134
- begin
135
- require 'rake/testtask'
136
-
137
- Rake::TestTask.new( :unittests ) do |task|
138
- task.libs += [LIBDIR]
139
- task.test_files = TEST_FILES
140
- task.verbose = true
141
- end
142
-
143
- rescue LoadError => err
144
- task :no_test do
145
- $stderr.puts "Test tasks not defined: %s" % [ err.message ]
146
- end
147
-
148
- task :unittests => :no_rspec
149
- end
150
-
151
-
@@ -1,64 +0,0 @@
1
- #####################################################################
2
- ### S U B V E R S I O N T A S K S A N D H E L P E R S
3
- #####################################################################
4
-
5
- require 'rake/tasklib'
6
-
7
- #
8
- # Work around the inexplicable behaviour of the original RDoc::VerifyTask, which
9
- # errors if your coverage isn't *exactly* the threshold.
10
- #
11
-
12
- # A task that can verify that the RCov coverage doesn't
13
- # drop below a certain threshold. It should be run after
14
- # running Spec::Rake::SpecTask.
15
- class VerifyTask < Rake::TaskLib
16
-
17
- COVERAGE_PERCENTAGE_PATTERN =
18
- %r{<tt class='coverage_code'>(\d+\.\d+)%</tt>}
19
-
20
- # Name of the task. Defaults to :verify_rcov
21
- attr_accessor :name
22
-
23
- # Path to the index.html file generated by RCov, which
24
- # is the file containing the total coverage.
25
- # Defaults to 'coverage/index.html'
26
- attr_accessor :index_html
27
-
28
- # Whether or not to output details. Defaults to true.
29
- attr_accessor :verbose
30
-
31
- # The threshold value (in percent) for coverage. If the
32
- # actual coverage is not equal to this value, the task will raise an
33
- # exception.
34
- attr_accessor :threshold
35
-
36
- def initialize( name=:verify )
37
- @name = name
38
- @index_html = 'coverage/index.html'
39
- @verbose = true
40
- yield self if block_given?
41
- raise "Threshold must be set" if @threshold.nil?
42
- define
43
- end
44
-
45
- def define
46
- desc "Verify that rcov coverage is at least #{threshold}%"
47
-
48
- task @name do
49
- total_coverage = nil
50
- if match = File.read( index_html ).match( COVERAGE_PERCENTAGE_PATTERN )
51
- total_coverage = Float( match[1] )
52
- else
53
- raise "Couldn't find the coverage percentage in #{index_html}"
54
- end
55
-
56
- puts "Coverage: #{total_coverage}% (threshold: #{threshold}%)" if verbose
57
- if total_coverage < threshold
58
- raise "Coverage must be at least #{threshold}% but was #{total_coverage}%"
59
- end
60
- end
61
- end
62
- end
63
-
64
- # vim: set nosta noet ts=4 sw=4: