rspec-core 2.6.4 → 2.7.0.rc1

Sign up to get free protection for your applications and to get access to all the features.
Files changed (107) hide show
  1. data/README.md +1 -1
  2. data/{bin → exe}/autospec +0 -0
  3. data/{bin → exe}/rspec +0 -0
  4. data/features/Upgrade.md +11 -0
  5. data/features/command_line/exit_status.feature +20 -3
  6. data/features/command_line/format_option.feature +8 -0
  7. data/features/command_line/line_number_appended_to_path.feature +35 -1
  8. data/features/command_line/line_number_option.feature +16 -3
  9. data/features/command_line/pattern_option.feature +31 -0
  10. data/features/command_line/rake_task.feature +1 -1
  11. data/features/command_line/ruby.feature +22 -0
  12. data/features/configuration/default_path.feature +38 -0
  13. data/features/example_groups/{shared_example_group.feature → shared_examples.feature} +49 -26
  14. data/features/expectation_framework_integration/configure_expectation_framework.feature +1 -1
  15. data/features/filtering/inclusion_filters.feature +4 -5
  16. data/features/formatters/text_formatter.feature +16 -13
  17. data/features/helper_methods/let.feature +4 -4
  18. data/features/hooks/around_hooks.feature +1 -1
  19. data/features/hooks/before_and_after_hooks.feature +3 -3
  20. data/features/hooks/filtering.feature +13 -6
  21. data/features/metadata/user_defined.feature +12 -10
  22. data/features/pending/pending_examples.feature +21 -8
  23. data/features/step_definitions/additional_cli_steps.rb +1 -1
  24. data/features/subject/attribute_of_subject.feature +2 -2
  25. data/features/support/env.rb +1 -2
  26. data/lib/rspec/core.rb +1 -23
  27. data/lib/rspec/core/configuration.rb +64 -16
  28. data/lib/rspec/core/configuration_options.rb +11 -4
  29. data/lib/rspec/core/example.rb +10 -7
  30. data/lib/rspec/core/example_group.rb +34 -18
  31. data/lib/rspec/core/formatters/base_text_formatter.rb +10 -2
  32. data/lib/rspec/core/formatters/html_formatter.rb +3 -1
  33. data/lib/rspec/core/formatters/snippet_extractor.rb +9 -3
  34. data/lib/rspec/core/formatters/text_mate_formatter.rb +20 -6
  35. data/lib/rspec/core/hooks.rb +2 -2
  36. data/lib/rspec/core/let.rb +5 -5
  37. data/lib/rspec/core/metadata.rb +136 -94
  38. data/lib/rspec/core/option_parser.rb +10 -5
  39. data/lib/rspec/core/pending.rb +2 -1
  40. data/lib/rspec/core/rake_task.rb +26 -15
  41. data/lib/rspec/core/reporter.rb +2 -3
  42. data/lib/rspec/core/runner.rb +1 -1
  43. data/lib/rspec/core/shared_example_group.rb +4 -4
  44. data/lib/rspec/core/subject.rb +7 -7
  45. data/lib/rspec/core/version.rb +1 -1
  46. data/lib/rspec/core/world.rb +4 -8
  47. data/spec/autotest/discover_spec.rb +2 -2
  48. data/spec/autotest/failed_results_re_spec.rb +29 -21
  49. data/spec/autotest/rspec_spec.rb +3 -3
  50. data/spec/rspec/core/command_line_spec.rb +1 -6
  51. data/spec/rspec/core/configuration_options_spec.rb +65 -13
  52. data/spec/rspec/core/configuration_spec.rb +148 -37
  53. data/spec/rspec/core/deprecations_spec.rb +2 -2
  54. data/spec/rspec/core/drb_command_line_spec.rb +6 -6
  55. data/spec/rspec/core/example_group_spec.rb +197 -61
  56. data/spec/rspec/core/example_spec.rb +33 -16
  57. data/spec/rspec/core/formatters/base_formatter_spec.rb +3 -3
  58. data/spec/rspec/core/formatters/base_text_formatter_spec.rb +149 -1
  59. data/spec/rspec/core/formatters/helpers_spec.rb +8 -8
  60. data/spec/rspec/core/formatters/html_formatted-1.8.7-jruby.html +85 -17
  61. data/spec/rspec/core/formatters/html_formatted-1.8.7.html +12 -11
  62. data/spec/rspec/core/formatters/html_formatted-1.9.2.html +12 -11
  63. data/spec/rspec/core/formatters/{html_formatted-1.9.1.html → html_formatted-1.9.3.html} +12 -11
  64. data/spec/rspec/core/formatters/html_formatter_spec.rb +5 -5
  65. data/spec/rspec/core/formatters/progress_formatter_spec.rb +2 -2
  66. data/spec/rspec/core/formatters/snippet_extractor_spec.rb +2 -2
  67. data/spec/rspec/core/formatters/text_mate_formatted-1.8.7-jruby.html +86 -18
  68. data/spec/rspec/core/formatters/text_mate_formatted-1.8.7.html +13 -12
  69. data/spec/rspec/core/formatters/text_mate_formatted-1.9.2.html +29 -28
  70. data/spec/rspec/core/formatters/{text_mate_formatted-1.9.1.html → text_mate_formatted-1.9.3.html} +29 -28
  71. data/spec/rspec/core/formatters/text_mate_formatter_spec.rb +2 -2
  72. data/spec/rspec/core/hooks_filtering_spec.rb +18 -18
  73. data/spec/rspec/core/let_spec.rb +19 -6
  74. data/spec/rspec/core/metadata_spec.rb +146 -61
  75. data/spec/rspec/core/pending_example_spec.rb +4 -4
  76. data/spec/rspec/core/rake_task_spec.rb +71 -50
  77. data/spec/rspec/core/reporter_spec.rb +2 -2
  78. data/spec/rspec/core/ruby_project_spec.rb +2 -2
  79. data/spec/rspec/core/runner_spec.rb +4 -1
  80. data/spec/rspec/core/shared_example_group_spec.rb +15 -119
  81. data/spec/rspec/core/subject_spec.rb +13 -13
  82. data/spec/rspec/core/world_spec.rb +31 -22
  83. data/spec/rspec/core_spec.rb +1 -29
  84. data/spec/spec_helper.rb +51 -49
  85. data/spec/support/shared_example_groups.rb +3 -3
  86. data/spec/support/spec_files.rb +8 -8
  87. metadata +79 -93
  88. data/.document +0 -5
  89. data/.gitignore +0 -12
  90. data/.rspec +0 -0
  91. data/.travis.yml +0 -9
  92. data/Changelog.md +0 -305
  93. data/Gemfile +0 -49
  94. data/Guardfile +0 -5
  95. data/License.txt +0 -23
  96. data/Rakefile +0 -93
  97. data/cucumber.yml +0 -2
  98. data/features/.nav +0 -57
  99. data/rspec-core.gemspec +0 -24
  100. data/script/FullBuildRakeFile +0 -63
  101. data/script/console +0 -8
  102. data/script/cucumber +0 -1
  103. data/script/full_build +0 -1
  104. data/script/spec +0 -1
  105. data/spec.txt +0 -1126
  106. data/spec/rspec/core/formatters/html_formatted-1.8.6.html +0 -398
  107. data/spec/rspec/core/formatters/text_mate_formatted-1.8.6.html +0 -398
data/.document DELETED
@@ -1,5 +0,0 @@
1
- README.markdown
2
- lib/**/*.rb
3
- bin/*
4
- features/**/*.feature
5
- License.txt
data/.gitignore DELETED
@@ -1,12 +0,0 @@
1
- .rvmrc
2
- *.sw?
3
- .DS_Store
4
- coverage*
5
- doc
6
- rdoc
7
- pkg
8
- tmp
9
- tags
10
- rerun.txt
11
- Gemfile.lock
12
- .bundle
data/.rspec DELETED
File without changes
@@ -1,9 +0,0 @@
1
- script: "bundle exec rake"
2
- rvm:
3
- - 1.8.6
4
- - 1.8.7
5
- - 1.9.1
6
- - 1.9.2
7
- - ree
8
- - rbx
9
- - jruby
@@ -1,305 +0,0 @@
1
- ### 2.6.4 / 2011-06-06
2
-
3
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.6.3...v2.6.4)
4
-
5
- * Bug fixes
6
- * Support exclusion filters in DRb. (Yann Lugrin)
7
- * Fix --example escaping when run over DRb. (Elliot Winkler)
8
- * Use standard ANSI codes for color formatting so colors work in a wider set
9
- of color schemes.
10
-
11
- ### 2.6.3 / 2011-05-24
12
-
13
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.6.2...v2.6.3)
14
-
15
- * Bug fixes
16
- * Explicitly convert exit code to integer, avoiding TypeError when return
17
- value of run is IO object proxied by `DRb::DRbObject` (Julian Scheid)
18
- * Clarify behavior of `--example` command line option
19
- * Build using a rubygems-1.6.2 to avoid downstream yaml parsing error
20
-
21
- ### 2.6.2 / 2011-05-21
22
-
23
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.6.1...v2.6.2)
24
-
25
- * Bug fixes
26
- * Warn rather than raise when HOME env var is not defined
27
- * Properly merge command-line exclusions with default :if and :unless (joshcooper)
28
-
29
- ### 2.6.1 / 2011-05-19
30
-
31
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.6.0...v2.6.1)
32
-
33
- * Bug fixes
34
- * Don't extend nil when filters are nil
35
- * `require 'rspec/autorun'` when running rcov.
36
-
37
- ### 2.6.0 / 2011-05-12
38
-
39
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.5.1...v2.6.0)
40
-
41
- * Enhancements
42
- * `shared_context` (Damian Nurzynski)
43
- * extend groups matching specific metadata with:
44
- * method definitions
45
- * subject declarations
46
- * let/let! declarations
47
- * etc (anything you can do in a group)
48
- * `its([:key])` works for any subject with #[]. (Peter Jaros)
49
- * `treat_symbols_as_metadata_keys_with_true_values` (Myron Marston)
50
- * Print a deprecation warning when you configure RSpec after defining
51
- an example. All configuration should happen before any examples are
52
- defined. (Myron Marston)
53
- * Pass the exit status of a DRb run to the invoking process. This causes
54
- specs run via DRb to not just return true or false. (Ilkka Laukkanen)
55
- * Refactoring of `ConfigurationOptions#parse_options` (Rodrigo Rosenfeld Rosas)
56
- * Report excluded filters in runner output (tip from andyl)
57
- * Clean up messages for filters/tags.
58
- * Restore --pattern/-P command line option from rspec-1
59
- * Support false as well as true in config.full_backtrace= (Andreas Tolf Tolfsen)
60
-
61
- * Bug fixes
62
- * Don't stumble over an exception without a message (Hans Hasselberg)
63
- * Remove non-ascii characters from comments that were choking rcov (Geoffrey
64
- Byers)
65
- * Fixed backtrace so it doesn't include lines from before the autorun at_exit
66
- hook (Myron Marston)
67
- * Include RSpec::Matchers when first example group is defined, rather
68
- than just before running the examples. This works around an obscure
69
- bug in ruby 1.9 that can cause infinite recursion. (Myron Marston)
70
- * Don't send `example_group_[started|finished]` to formatters for empty groups.
71
- * Get specs passing on jruby (Sidu Ponnappa)
72
- * Fix bug where mixing nested groups and outer-level examples gave
73
- unpredictable :line_number behavior (Artur Małecki)
74
- * Regexp.escape the argument to --example (tip from Elliot Winkler)
75
- * Correctly pass/fail pending block with message expectations
76
- * CommandLine returns exit status (0/1) instead of true/false
77
- * Create path to formatter output file if it doesn't exist (marekj).
78
-
79
-
80
- ### 2.5.1 / 2011-02-06
81
-
82
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.5.0...v2.5.1)
83
-
84
- NOTE: this release breaks compatibility with rspec/autotest/bundler
85
- integration, but does so in order to greatly simplify it.
86
-
87
- With this release, if you want the generated autotest command to include
88
- 'bundle exec', require Autotest's bundler plugin in a .autotest file in the
89
- project's root directory or in your home directory:
90
-
91
- require "autotest/bundler"
92
-
93
- Now you can just type 'autotest' on the commmand line and it will work as you expect.
94
-
95
- If you don't want 'bundle exec', there is nothing you have to do.
96
-
97
- ### 2.5.0 / 2011-02-05
98
-
99
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.4.0...v2.5.0)
100
-
101
- * Enhancements
102
- * Autotest::Rspec2 parses command line args passed to autotest after '--'
103
- * --skip-bundler option for autotest command
104
- * Autotest regexp fixes (Jon Rowe)
105
- * Add filters to html and textmate formatters (Daniel Quimper)
106
- * Explicit passing of block (need for JRuby 1.6) (John Firebaugh)
107
-
108
- * Bug fixes
109
- * fix dom IDs in HTML formatter (Brian Faherty)
110
- * fix bug with --drb + formatters when not running in drb
111
- * include --tag options in drb args (monocle)
112
- * fix regression so now SPEC_OPTS take precedence over CLI options again
113
- (Roman Chernyatchik)
114
- * only call its(:attribute) once (failing example from Brian Dunn)
115
- * fix bizarre bug where rspec would hang after String.alias :to_int :to_i
116
- (Damian Nurzynski)
117
-
118
- * Deprecations
119
- * implicit inclusion of 'bundle exec' when Gemfile present (use autotest's
120
- bundler plugin instead)
121
-
122
- ### 2.4.0 / 2011-01-02
123
-
124
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.3.1...v2.4.0)
125
-
126
- * Enhancements
127
- * start the debugger on -d so the stack trace is visible when it stops
128
- (Clifford Heath)
129
- * apply hook filtering to examples as well as groups (Myron Marston)
130
- * support multiple formatters, each with their own output
131
- * show exception classes in failure messages unless they come from RSpec
132
- matchers or message expectations
133
- * before(:all) { pending } sets all examples to pending
134
-
135
- * Bug fixes
136
- * fix bug due to change in behavior of reject in Ruby 1.9.3-dev (Shota Fukumori)
137
- * fix bug when running in jruby: be explicit about passing block to super
138
- (John Firebaugh)
139
- * rake task doesn't choke on paths with quotes (Janmejay Singh)
140
- * restore --options option from rspec-1
141
- * require 'ostruct' to fix bug with its([key]) (Kim Burgestrand)
142
- * --configure option generates .rspec file instead of autotest/discover.rb
143
-
144
- ### 2.3.1 / 2010-12-16
145
-
146
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.3.0...v2.3.1)
147
-
148
- * Bug fixes
149
- * send debugger warning message to $stdout if RSpec.configuration.error_stream
150
- has not been defined yet.
151
- * HTML Formatter _finally_ properly displays nested groups (Jarmo Pertman)
152
- * eliminate some warnings when running RSpec's own suite (Jarmo Pertman)
153
-
154
- ### 2.3.0 / 2010-12-12
155
-
156
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.2.1...v2.3.0)
157
-
158
- * Enhancements
159
- * tell autotest to use "rspec2" if it sees a .rspec file in the project's
160
- root directory
161
- * replaces the need for ./autotest/discover.rb, which will not work with
162
- all versions of ZenTest and/or autotest
163
- * config.expect_with
164
- * :rspec # => rspec/expectations
165
- * :stdlib # => test/unit/assertions
166
- * :rspec, :stdlib # => both
167
-
168
- * Bug fixes
169
- * fix dev Gemfile to work on non-mac-os machines (Lake Denman)
170
- * ensure explicit subject is only eval'd once (Laszlo Bacsi)
171
-
172
- ### 2.2.1 / 2010-11-28
173
-
174
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.2.0...v2.2.1)
175
-
176
- * Bug fixes
177
- * alias_method instead of override Kernel#method_missing (John Wilger)
178
- * changed --autotest to --tty in generated command (MIKAMI Yoshiyuki)
179
- * revert change to debugger (had introduced conflict with Rails)
180
- * also restored --debugger/-debug option
181
-
182
- ### 2.2.0 / 2010-11-28
183
-
184
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.1.0...v2.2.0)
185
-
186
- * Deprecations/changes
187
- * --debug/-d on command line is deprecated and now has no effect
188
- * win32console is now ignored; Windows users must use ANSICON for color support
189
- (Bosko Ivanisevic)
190
-
191
- * Enhancements
192
- * When developing locally rspec-core now works with the rspec-dev setup or your local gems
193
- * Raise exception with helpful message when rspec-1 is loaded alongside
194
- rspec-2 (Justin Ko)
195
- * debugger statements _just work_ as long as ruby-debug is installed
196
- * otherwise you get warned, but not fired
197
- * Expose example.metadata in around hooks
198
- * Performance improvments (much faster now)
199
-
200
- * Bug fixes
201
- * Make sure --fail-fast makes it across drb
202
- * Pass -Ilib:spec to rcov
203
-
204
- ### 2.1.0 / 2010-11-07
205
-
206
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.0.1...v2.1.0)
207
-
208
- * Enhancments
209
- * Add skip_bundler option to rake task to tell rake task to ignore the
210
- presence of a Gemfile (jfelchner)
211
- * Add gemfile option to rake task to tell rake task what Gemfile to look
212
- for (defaults to 'Gemfile')
213
- * Allow passing caller trace into Metadata to support extensions (Glenn
214
- Vanderburg)
215
- * Add deprecation warning for Spec::Runner.configure to aid upgrade from
216
- RSpec-1
217
- * Add deprecated Spec::Rake::SpecTask to aid upgrade from RSpec-1
218
- * Add 'autospec' command with helpful message to aid upgrade from RSpec-1
219
- * Add support for filtering with tags on CLI (Lailson Bandeira)
220
- * Add a helpful message about RUBYOPT when require fails in bin/rspec
221
- (slyphon)
222
- * Add "-Ilib" to the default rcov options (Tianyi Cui)
223
- * Make the expectation framework configurable (default rspec, of course)
224
- (Justin Ko)
225
- * Add 'pending' to be conditional (Myron Marston)
226
- * Add explicit support for :if and :unless as metadata keys for conditional run
227
- of examples (Myron Marston)
228
- * Add --fail-fast command line option (Jeff Kreeftmeijer)
229
-
230
- * Bug fixes
231
- * Eliminate stack overflow with "subject { self }"
232
- * Require 'rspec/core' in the Raketask (ensures it required when running rcov)
233
-
234
- ### 2.0.1 / 2010-10-18
235
-
236
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.0.0...v2.0.1)
237
-
238
- * Bug fixes
239
- * Restore color when using spork + autotest
240
- * Pending examples without docstrings render the correct message (Josep M. Bach)
241
- * Fixed bug where a failure in a spec file ending in anything but _spec.rb would
242
- fail in a confusing way.
243
- * Support backtrace lines from erb templates in html formatter (Alex Crichton)
244
-
245
- ### 2.0.0 / 2010-10-10
246
-
247
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.0.0.rc...v2.0.0)
248
-
249
- * RSpec-1 compatibility
250
- * Rake task uses ENV["SPEC"] as file list if present
251
-
252
- * Bug fixes
253
- * Bug Fix: optparse --out foo.txt (Leonardo Bessa)
254
- * Suppress color codes for non-tty output (except autotest)
255
-
256
- ### 2.0.0.rc / 2010-10-05
257
-
258
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.0.0.beta.22...v2.0.0.rc)
259
-
260
- * Enhancements
261
- * implicitly require unknown formatters so you don't have to require the
262
- file explicitly on the commmand line (Michael Grosser)
263
- * add --out/-o option to assign output target
264
- * added fail_fast configuration option to abort on first failure
265
- * support a Hash subject (its([:key]) { should == value }) (Josep M. Bach)
266
-
267
- * Bug fixes
268
- * Explicitly require rspec version to fix broken rdoc task (Hans de Graaff)
269
- * Ignore backtrace lines that come from other languages, like Java or
270
- Javascript (Charles Lowell)
271
- * Rake task now does what is expected when setting (or not setting)
272
- fail_on_error and verbose
273
- * Fix bug in which before/after(:all) hooks were running on excluded nested
274
- groups (Myron Marston)
275
- * Fix before(:all) error handling so that it fails examples in nested groups,
276
- too (Myron Marston)
277
-
278
- ### 2.0.0.beta.22 / 2010-09-12
279
-
280
- [full changelog](http://github.com/rspec/rspec-core/compare/v2.0.0.beta.20...v2.0.0.beta.22)
281
-
282
- * Enhancements
283
- * removed at_exit hook
284
- * CTRL-C stops the run (almost) immediately
285
- * first it cleans things up by running the appropriate after(:all) and after(:suite) hooks
286
- * then it reports on any examples that have already run
287
- * cleaned up rake task
288
- * generate correct task under variety of conditions
289
- * options are more consistent
290
- * deprecated redundant options
291
- * run 'bundle exec autotest' when Gemfile is present
292
- * support ERB in .rspec options files (Justin Ko)
293
- * depend on bundler for development tasks (Myron Marston)
294
- * add example_group_finished to formatters and reporter (Roman Chernyatchik)
295
-
296
- * Bug fixes
297
- * support paths with spaces when using autotest (Andreas Neuhaus)
298
- * fix module_exec with ruby 1.8.6 (Myron Marston)
299
- * remove context method from top-level
300
- * was conflicting with irb, for example
301
- * errors in before(:all) are now reported correctly (Chad Humphries)
302
-
303
- * Removals
304
- * removed -o --options-file command line option
305
- * use ./.rspec and ~/.rspec
data/Gemfile DELETED
@@ -1,49 +0,0 @@
1
- source "http://rubygems.org"
2
-
3
- ### rspec libs
4
- %w[rspec rspec-core rspec-expectations rspec-mocks].each do |lib|
5
- library_path = File.expand_path("../../#{lib}", __FILE__)
6
- if File.exist?(library_path)
7
- gem lib, :path => library_path
8
- else
9
- gem lib, :git => "git://github.com/rspec/#{lib}.git"
10
- end
11
- end
12
-
13
- ### dev dependencies
14
- gem "rake", "~> 0.9"
15
- gem "cucumber", "~> 0.10.2"
16
- gem "aruba", "~> 0.3.6"
17
- gem "rcov", "0.9.9", :platforms => :mri
18
- gem "relish", "0.2.0"
19
- gem "guard-rspec", "0.1.9"
20
- gem "growl", "1.0.3"
21
- gem "ZenTest", "~> 4.4.2"
22
- gem "nokogiri", "1.4.4"
23
-
24
- platforms :mri_18 do
25
- gem 'ruby-debug'
26
- end
27
-
28
- platforms :mri_19 do
29
- gem 'linecache19', '0.5.11' # 0.5.12 cannot install on 1.9.1, and 0.5.11 appears to work with both 1.9.1 & 1.9.2
30
- gem 'ruby-debug19'
31
- gem 'ruby-debug-base19', RUBY_VERSION == '1.9.1' ? '0.11.23' : '~> 0.11.24'
32
- end
33
-
34
- platforms :mri_18, :mri_19 do
35
- gem "rb-fsevent", "~> 0.3.9"
36
- gem "ruby-prof", "~> 0.9.2"
37
- end
38
-
39
- platforms :jruby do
40
- gem "jruby-openssl"
41
- end
42
-
43
- ### rspec-core only
44
- gem "mocha", "~> 0.9.10"
45
- gem "rr", "~> 1.0.2"
46
- gem "flexmock", "0.8.8"
47
-
48
- ### optional runtime deps
49
- gem "syntax", "1.0.0"
data/Guardfile DELETED
@@ -1,5 +0,0 @@
1
- guard 'rspec', :version => 2 do
2
- watch(/^spec\/(.*)_spec.rb/)
3
- watch(/^lib\/(.*)\.rb/) { |m| "spec/#{m[1]}_spec.rb" }
4
- watch(/^spec\/spec_helper.rb/) { "spec" }
5
- end
@@ -1,23 +0,0 @@
1
- (The MIT License)
2
-
3
- Copyright (c) 2009 Chad Humphries, David Chelimsky
4
- Copyright (c) 2005 The RSpec Development Team
5
-
6
- Permission is hereby granted, free of charge, to any person obtaining
7
- a copy of this software and associated documentation files (the
8
- "Software"), to deal in the Software without restriction, including
9
- without limitation the rights to use, copy, modify, merge, publish,
10
- distribute, sublicense, and/or sell copies of the Software, and to
11
- permit persons to whom the Software is furnished to do so, subject to
12
- the following conditions:
13
-
14
- The above copyright notice and this permission notice shall be
15
- included in all copies or substantial portions of the Software.
16
-
17
- THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND,
18
- EXPRESS OR IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF
19
- MERCHANTABILITY, FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT.
20
- IN NO EVENT SHALL THE AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY
21
- CLAIM, DAMAGES OR OTHER LIABILITY, WHETHER IN AN ACTION OF CONTRACT,
22
- TORT OR OTHERWISE, ARISING FROM, OUT OF OR IN CONNECTION WITH THE
23
- SOFTWARE OR THE USE OR OTHER DEALINGS IN THE SOFTWARE.
data/Rakefile DELETED
@@ -1,93 +0,0 @@
1
- require "bundler"
2
- Bundler.setup
3
- Bundler::GemHelper.install_tasks
4
-
5
- task :build => :raise_if_psych_is_defined
6
-
7
- task :raise_if_psych_is_defined do
8
- if defined?(Psych)
9
- raise <<-MSG
10
- ===============================================================================
11
- Gems compiled in Ruby environments with Psych loaded are incompatible with Ruby
12
- environments that don't have Psych loaded. Try building this gem in Ruby 1.8.7
13
- instead.
14
- ===============================================================================
15
- MSG
16
- end
17
- end
18
-
19
- require "rake"
20
- require "yaml"
21
-
22
- require "rake/rdoctask"
23
- require "rspec/core/rake_task"
24
- require "rspec/core/version"
25
-
26
- begin
27
- require "cucumber/rake/task"
28
- Cucumber::Rake::Task.new(:cucumber)
29
- rescue LoadError => e
30
- puts "unable to load cucumber, some tasks unavailable"
31
- task :cucumber do
32
- # no-op
33
- end
34
- end
35
-
36
- desc "Run all examples"
37
- RSpec::Core::RakeTask.new(:spec) do |t|
38
- t.rspec_path = 'bin/rspec'
39
- t.rspec_opts = %w[--color]
40
- t.verbose = false
41
- end
42
-
43
- namespace :rcov do
44
- task :cleanup do
45
- rm_rf 'coverage.data'
46
- end
47
-
48
- RSpec::Core::RakeTask.new :spec do |t|
49
- t.rcov = true
50
- t.rcov_opts = %[-Ilib -Ispec --exclude "gems/*,features"]
51
- t.rcov_opts << %[--no-html --aggregate coverage.data]
52
- end
53
-
54
- if defined?(Cucumber)
55
- Cucumber::Rake::Task.new :cucumber do |t|
56
- t.cucumber_opts = %w{--format progress}
57
- t.rcov = true
58
- t.rcov_opts = %[-Ilib -Ispec --exclude "gems/*,features"]
59
- t.rcov_opts << %[--text-report --sort coverage --aggregate coverage.data]
60
- end
61
- else
62
- task :cucumber do
63
- # no-op
64
- end
65
- end
66
-
67
- end
68
-
69
- task :rcov => ["rcov:cleanup", "rcov:spec", "rcov:cucumber"]
70
-
71
- task :default => [:spec, :cucumber]
72
-
73
- task :clobber do
74
- rm_rf 'pkg'
75
- rm_rf 'tmp'
76
- rm_rf 'coverage'
77
- end
78
-
79
- desc "Push docs/cukes to relishapp using the relish-client-gem"
80
- task :relish, :version do |t, args|
81
- raise "rake relish[VERSION]" unless args[:version]
82
- sh "cp Changelog.md features/"
83
- sh "relish push rspec/rspec-core:#{args[:version]}"
84
- sh "rm features/Changelog.md"
85
- end
86
-
87
- Rake::RDocTask.new do |rdoc|
88
- rdoc.rdoc_dir = 'rdoc'
89
- rdoc.title = "rspec-core #{RSpec::Core::Version::STRING}"
90
- rdoc.rdoc_files.include('README*')
91
- rdoc.rdoc_files.include('lib/**/*.rb')
92
- end
93
-