picolena 0.1.5 → 0.1.6

Sign up to get free protection for your applications and to get access to all the features.
Files changed (390) hide show
  1. data/History.txt +11 -4
  2. data/Manifest.txt +1 -0
  3. data/README.txt +2 -2
  4. data/bin/picolena +1 -1
  5. data/config/hoe.rb +10 -10
  6. data/lib/picolena/USAGE +1 -1
  7. data/lib/picolena/config/basic.rb +11 -11
  8. data/lib/picolena/picolena_generator.rb +15 -14
  9. data/lib/picolena/templates/app/controllers/application.rb +5 -5
  10. data/lib/picolena/templates/app/controllers/documents_controller.rb +17 -9
  11. data/lib/picolena/templates/app/helpers/documents_helper.rb +15 -14
  12. data/lib/picolena/templates/app/models/document.rb +28 -37
  13. data/lib/picolena/templates/app/models/finder.rb +12 -37
  14. data/lib/picolena/templates/app/models/indexer.rb +58 -37
  15. data/lib/picolena/templates/app/models/plain_text_extractor.rb +16 -16
  16. data/lib/picolena/templates/app/models/query.rb +5 -5
  17. data/lib/picolena/templates/app/views/documents/show.html.haml +3 -3
  18. data/lib/picolena/templates/app/views/layouts/application.html.haml +2 -2
  19. data/lib/picolena/templates/config/environment.rb +1 -1
  20. data/lib/picolena/templates/config/initializers/002_load_indexed_dirs.rb +8 -8
  21. data/lib/picolena/templates/config/initializers/003_load_white_list_IPs.rb +8 -8
  22. data/lib/picolena/templates/config/initializers/005_load_custom_title_and_names_and_links.rb +5 -5
  23. data/lib/picolena/templates/config/initializers/006_load_icons.rb +9 -7
  24. data/lib/picolena/templates/lang/ui/es.yml +1 -1
  25. data/lib/picolena/templates/lib/core_exts.rb +7 -7
  26. data/lib/picolena/templates/lib/plain_text_extractor_DSL.rb +10 -10
  27. data/lib/picolena/templates/lib/plain_text_extractors/ms.excel.rb +1 -1
  28. data/lib/picolena/templates/lib/plain_text_extractors/plain_text.rb +2 -2
  29. data/lib/picolena/templates/lib/tasks/index.rake +8 -3
  30. data/lib/picolena/templates/lib/tasks/install_dependencies.rake +2 -2
  31. data/lib/picolena/templates/lib/tasks/log.rake +1 -1
  32. data/lib/picolena/templates/public/.htaccess +3 -3
  33. data/lib/picolena/templates/public/images/flags/sv.png +0 -0
  34. data/lib/picolena/templates/public/stylesheets/style.css +2 -2
  35. data/lib/picolena/templates/script/spec_server +1 -1
  36. data/lib/picolena/templates/spec/controllers/application_controller_spec.rb +2 -2
  37. data/lib/picolena/templates/spec/controllers/documents_controller_spec.rb +17 -17
  38. data/lib/picolena/templates/spec/helpers/application_helper_spec.rb +2 -2
  39. data/lib/picolena/templates/spec/helpers/documents_helper_spec.rb +3 -3
  40. data/lib/picolena/templates/spec/models/basic_finder_spec.rb +14 -14
  41. data/lib/picolena/templates/spec/models/document_spec.rb +7 -15
  42. data/lib/picolena/templates/spec/models/finder_spec.rb +45 -38
  43. data/lib/picolena/templates/spec/models/host_indexing_system_spec.rb +5 -5
  44. data/lib/picolena/templates/spec/models/index_directories_spec.rb +2 -2
  45. data/lib/picolena/templates/spec/models/plain_text_extractor_spec.rb +6 -6
  46. data/lib/picolena/templates/spec/models/query_spec.rb +7 -7
  47. data/lib/picolena/templates/spec/rcov.opts +1 -1
  48. data/lib/picolena/templates/spec/test_dirs/indexed/basic/myfirstjavaprog.java +1 -1
  49. data/lib/picolena/templates/spec/test_dirs/indexed/basic/queens.for +1 -1
  50. data/lib/picolena/templates/spec/test_dirs/indexed/lang/hugo +74 -74
  51. data/lib/picolena/templates/spec/test_dirs/indexed/lang/lorca +56 -56
  52. data/lib/picolena/templates/spec/test_dirs/indexed/others/7.html +4 -4
  53. data/lib/picolena/templates/spec/test_dirs/indexed/others/ccmatrix1.cpp +6 -6
  54. data/lib/picolena/templates/spec/test_dirs/indexed/others/lemonde.htm +326 -326
  55. data/lib/picolena/templates/spec/test_dirs/indexed/others/nested/ReadMe.rtf +62 -62
  56. data/lib/picolena/templates/spec/test_dirs/indexed/others/xor.vee +0 -1
  57. data/lib/picolena/templates/spec/test_dirs/indexed/others/zafh.net.html +1 -1
  58. data/lib/picolena/version.rb +1 -1
  59. data/lib/rubigen_ext.rb +1 -1
  60. data/rails_plugins/globalite/CHANGELOG +1 -1
  61. data/rails_plugins/globalite/README +19 -19
  62. data/rails_plugins/globalite/lang/rails/de-DE.yml +6 -6
  63. data/rails_plugins/globalite/lang/rails/en-UK.yml +10 -10
  64. data/rails_plugins/globalite/lang/rails/en-US.yml +10 -10
  65. data/rails_plugins/globalite/lang/rails/es-ES.yml +11 -11
  66. data/rails_plugins/globalite/lang/rails/fr-FR.yml +10 -10
  67. data/rails_plugins/globalite/lang/rails/it.yml +10 -10
  68. data/rails_plugins/globalite/lang/rails/pt-BR.yml +6 -6
  69. data/rails_plugins/globalite/lang/rails/pt-PT.yml +6 -6
  70. data/rails_plugins/globalite/lib/globalite/l10n.rb +25 -25
  71. data/rails_plugins/globalite/lib/globalite/locale.rb +9 -9
  72. data/rails_plugins/globalite/lib/rails/core_ext.rb +4 -4
  73. data/rails_plugins/globalite/lib/rails/localization.rb +3 -3
  74. data/rails_plugins/globalite/lib/rails/localized_action_view.rb +17 -17
  75. data/rails_plugins/globalite/lib/rails/localized_active_record.rb +4 -4
  76. data/rails_plugins/globalite/rdoc/classes/ActionView/Helpers/DateHelper.html +19 -19
  77. data/rails_plugins/globalite/rdoc/classes/ActionView/Helpers/FormOptionsHelper.html +9 -9
  78. data/rails_plugins/globalite/rdoc/classes/ActionView/Helpers/NumberHelper.html +8 -8
  79. data/rails_plugins/globalite/rdoc/classes/ActionView/Helpers.html +5 -5
  80. data/rails_plugins/globalite/rdoc/classes/ActionView.html +5 -5
  81. data/rails_plugins/globalite/rdoc/classes/ActiveRecord/Errors.html +6 -6
  82. data/rails_plugins/globalite/rdoc/classes/ActiveRecord.html +5 -5
  83. data/rails_plugins/globalite/rdoc/classes/Array.html +6 -6
  84. data/rails_plugins/globalite/rdoc/classes/Date.html +8 -8
  85. data/rails_plugins/globalite/rdoc/classes/Globalite/L10n.html +49 -49
  86. data/rails_plugins/globalite/rdoc/classes/Globalite.html +6 -6
  87. data/rails_plugins/globalite/rdoc/classes/Kernel.html +6 -6
  88. data/rails_plugins/globalite/rdoc/classes/Locale.html +11 -11
  89. data/rails_plugins/globalite/rdoc/classes/Time.html +8 -8
  90. data/rails_plugins/globalite/rdoc/files/README.html +5 -5
  91. data/rails_plugins/globalite/rdoc/files/lib/globalite/l10n_rb.html +5 -5
  92. data/rails_plugins/globalite/rdoc/files/lib/globalite/locale_rb.html +5 -5
  93. data/rails_plugins/globalite/rdoc/files/lib/globalite_rb.html +5 -5
  94. data/rails_plugins/globalite/rdoc/files/lib/rails/core_ext_rb.html +5 -5
  95. data/rails_plugins/globalite/rdoc/files/lib/rails/localization_rb.html +5 -5
  96. data/rails_plugins/globalite/rdoc/files/lib/rails/localized_action_view_rb.html +5 -5
  97. data/rails_plugins/globalite/rdoc/files/lib/rails/localized_active_record_rb.html +5 -5
  98. data/rails_plugins/globalite/rdoc/fr_class_index.html +1 -1
  99. data/rails_plugins/globalite/rdoc/fr_file_index.html +1 -1
  100. data/rails_plugins/globalite/rdoc/fr_method_index.html +1 -1
  101. data/rails_plugins/globalite/rdoc/index.html +1 -1
  102. data/rails_plugins/globalite/spec/core_localization_spec.rb +18 -18
  103. data/rails_plugins/globalite/spec/l10n_spec.rb +25 -25
  104. data/rails_plugins/globalite/tasks/globalite_tasks.rake +6 -6
  105. data/rails_plugins/rspec/CHANGES +16 -16
  106. data/rails_plugins/rspec/README +2 -2
  107. data/rails_plugins/rspec/Rakefile +1 -1
  108. data/rails_plugins/rspec/UPGRADE +1 -1
  109. data/rails_plugins/rspec/autotest/discover.rb +1 -1
  110. data/rails_plugins/rspec/examples/pure/autogenerated_docstrings_example.rb +5 -5
  111. data/rails_plugins/rspec/examples/pure/before_and_after_example.rb +2 -2
  112. data/rails_plugins/rspec/examples/pure/behave_as_example.rb +5 -5
  113. data/rails_plugins/rspec/examples/pure/custom_expectation_matchers.rb +7 -7
  114. data/rails_plugins/rspec/examples/pure/file_accessor.rb +1 -1
  115. data/rails_plugins/rspec/examples/pure/file_accessor_spec.rb +2 -2
  116. data/rails_plugins/rspec/examples/pure/helper_method_example.rb +1 -1
  117. data/rails_plugins/rspec/examples/pure/legacy_spec.rb +2 -2
  118. data/rails_plugins/rspec/examples/pure/predicate_example.rb +2 -2
  119. data/rails_plugins/rspec/examples/pure/shared_example_group_example.rb +11 -11
  120. data/rails_plugins/rspec/examples/pure/shared_stack_examples.rb +4 -4
  121. data/rails_plugins/rspec/examples/pure/stack.rb +6 -6
  122. data/rails_plugins/rspec/examples/pure/stack_spec.rb +7 -7
  123. data/rails_plugins/rspec/examples/pure/stack_spec_with_nested_example_groups.rb +10 -10
  124. data/rails_plugins/rspec/examples/pure/stubbing_example.rb +4 -4
  125. data/rails_plugins/rspec/examples/stories/adder.rb +2 -2
  126. data/rails_plugins/rspec/examples/stories/addition +8 -8
  127. data/rails_plugins/rspec/examples/stories/calculator.rb +5 -5
  128. data/rails_plugins/rspec/examples/stories/game-of-life/behaviour/examples/game_behaviour.rb +7 -7
  129. data/rails_plugins/rspec/examples/stories/game-of-life/behaviour/examples/grid_behaviour.rb +13 -13
  130. data/rails_plugins/rspec/examples/stories/game-of-life/behaviour/stories/create_a_cell.rb +5 -5
  131. data/rails_plugins/rspec/examples/stories/game-of-life/behaviour/stories/kill_a_cell.rb +2 -2
  132. data/rails_plugins/rspec/examples/stories/game-of-life/life/game.rb +3 -3
  133. data/rails_plugins/rspec/examples/stories/game-of-life/life/grid.rb +10 -10
  134. data/rails_plugins/rspec/failing_examples/failing_autogenerated_docstrings_example.rb +5 -5
  135. data/rails_plugins/rspec/failing_examples/failure_in_setup.rb +3 -3
  136. data/rails_plugins/rspec/failing_examples/failure_in_teardown.rb +3 -3
  137. data/rails_plugins/rspec/failing_examples/mocking_example.rb +1 -1
  138. data/rails_plugins/rspec/failing_examples/raising_example.rb +11 -11
  139. data/rails_plugins/rspec/failing_examples/team_spec.rb +5 -5
  140. data/rails_plugins/rspec/lib/autotest/rspec.rb +5 -5
  141. data/rails_plugins/rspec/lib/spec/example/configuration.rb +4 -4
  142. data/rails_plugins/rspec/lib/spec/example/example_group_factory.rb +3 -3
  143. data/rails_plugins/rspec/lib/spec/example/example_group_methods.rb +1 -1
  144. data/rails_plugins/rspec/lib/spec/example/example_matcher.rb +2 -2
  145. data/rails_plugins/rspec/lib/spec/example/example_methods.rb +4 -4
  146. data/rails_plugins/rspec/lib/spec/example/pending.rb +1 -1
  147. data/rails_plugins/rspec/lib/spec/expectations/differs/default.rb +5 -5
  148. data/rails_plugins/rspec/lib/spec/expectations/errors.rb +1 -1
  149. data/rails_plugins/rspec/lib/spec/expectations/handler.rb +5 -5
  150. data/rails_plugins/rspec/lib/spec/expectations.rb +1 -1
  151. data/rails_plugins/rspec/lib/spec/extensions/main.rb +8 -8
  152. data/rails_plugins/rspec/lib/spec/interop/test/unit/ui/console/testrunner.rb +2 -2
  153. data/rails_plugins/rspec/lib/spec/matchers/be.rb +18 -18
  154. data/rails_plugins/rspec/lib/spec/matchers/be_close.rb +4 -4
  155. data/rails_plugins/rspec/lib/spec/matchers/change.rb +20 -20
  156. data/rails_plugins/rspec/lib/spec/matchers/eql.rb +4 -4
  157. data/rails_plugins/rspec/lib/spec/matchers/equal.rb +4 -4
  158. data/rails_plugins/rspec/lib/spec/matchers/has.rb +8 -8
  159. data/rails_plugins/rspec/lib/spec/matchers/have.rb +9 -9
  160. data/rails_plugins/rspec/lib/spec/matchers/include.rb +7 -7
  161. data/rails_plugins/rspec/lib/spec/matchers/match.rb +6 -6
  162. data/rails_plugins/rspec/lib/spec/matchers/operator_matcher.rb +1 -1
  163. data/rails_plugins/rspec/lib/spec/matchers/raise_error.rb +6 -6
  164. data/rails_plugins/rspec/lib/spec/matchers/respond_to.rb +7 -7
  165. data/rails_plugins/rspec/lib/spec/matchers/satisfy.rb +4 -4
  166. data/rails_plugins/rspec/lib/spec/matchers/simple_matcher.rb +3 -3
  167. data/rails_plugins/rspec/lib/spec/matchers/throw_symbol.rb +8 -8
  168. data/rails_plugins/rspec/lib/spec/matchers.rb +2 -2
  169. data/rails_plugins/rspec/lib/spec/mocks/argument_constraint_matchers.rb +3 -3
  170. data/rails_plugins/rspec/lib/spec/mocks/argument_expectation.rb +32 -32
  171. data/rails_plugins/rspec/lib/spec/mocks/error_generator.rb +13 -13
  172. data/rails_plugins/rspec/lib/spec/mocks/errors.rb +1 -1
  173. data/rails_plugins/rspec/lib/spec/mocks/message_expectation.rb +38 -38
  174. data/rails_plugins/rspec/lib/spec/mocks/methods.rb +3 -3
  175. data/rails_plugins/rspec/lib/spec/mocks/mock.rb +5 -5
  176. data/rails_plugins/rspec/lib/spec/mocks/order_group.rb +5 -5
  177. data/rails_plugins/rspec/lib/spec/mocks/proxy.rb +4 -4
  178. data/rails_plugins/rspec/lib/spec/mocks/space.rb +3 -3
  179. data/rails_plugins/rspec/lib/spec/mocks/spec_methods.rb +1 -1
  180. data/rails_plugins/rspec/lib/spec/mocks.rb +13 -13
  181. data/rails_plugins/rspec/lib/spec/rake/spectask.rb +4 -4
  182. data/rails_plugins/rspec/lib/spec/rake/verify_rcov.rb +9 -9
  183. data/rails_plugins/rspec/lib/spec/runner/backtrace_tweaker.rb +2 -2
  184. data/rails_plugins/rspec/lib/spec/runner/formatter/base_formatter.rb +7 -7
  185. data/rails_plugins/rspec/lib/spec/runner/formatter/base_text_formatter.rb +13 -13
  186. data/rails_plugins/rspec/lib/spec/runner/formatter/failing_examples_formatter.rb +1 -1
  187. data/rails_plugins/rspec/lib/spec/runner/formatter/html_formatter.rb +8 -8
  188. data/rails_plugins/rspec/lib/spec/runner/formatter/profile_formatter.rb +7 -7
  189. data/rails_plugins/rspec/lib/spec/runner/formatter/progress_bar_formatter.rb +2 -2
  190. data/rails_plugins/rspec/lib/spec/runner/formatter/snippet_extractor.rb +5 -5
  191. data/rails_plugins/rspec/lib/spec/runner/formatter/specdoc_formatter.rb +4 -4
  192. data/rails_plugins/rspec/lib/spec/runner/formatter/story/html_formatter.rb +6 -6
  193. data/rails_plugins/rspec/lib/spec/runner/formatter/story/plain_text_formatter.rb +12 -12
  194. data/rails_plugins/rspec/lib/spec/runner/heckle_runner.rb +6 -6
  195. data/rails_plugins/rspec/lib/spec/runner/option_parser.rb +5 -5
  196. data/rails_plugins/rspec/lib/spec/runner/options.rb +8 -8
  197. data/rails_plugins/rspec/lib/spec/runner/reporter.rb +14 -14
  198. data/rails_plugins/rspec/lib/spec/runner.rb +41 -41
  199. data/rails_plugins/rspec/lib/spec/story/extensions/main.rb +6 -6
  200. data/rails_plugins/rspec/lib/spec/story/extensions/regexp.rb +1 -1
  201. data/rails_plugins/rspec/lib/spec/story/extensions/string.rb +1 -1
  202. data/rails_plugins/rspec/lib/spec/story/given_scenario.rb +1 -1
  203. data/rails_plugins/rspec/lib/spec/story/runner/plain_text_story_runner.rb +6 -6
  204. data/rails_plugins/rspec/lib/spec/story/runner/scenario_collector.rb +2 -2
  205. data/rails_plugins/rspec/lib/spec/story/runner/scenario_runner.rb +5 -5
  206. data/rails_plugins/rspec/lib/spec/story/runner/story_mediator.rb +20 -20
  207. data/rails_plugins/rspec/lib/spec/story/runner/story_parser.rb +29 -29
  208. data/rails_plugins/rspec/lib/spec/story/runner/story_runner.rb +8 -8
  209. data/rails_plugins/rspec/lib/spec/story/runner.rb +7 -7
  210. data/rails_plugins/rspec/lib/spec/story/scenario.rb +1 -1
  211. data/rails_plugins/rspec/lib/spec/story/step.rb +5 -5
  212. data/rails_plugins/rspec/lib/spec/story/step_group.rb +12 -12
  213. data/rails_plugins/rspec/lib/spec/story/step_mother.rb +6 -6
  214. data/rails_plugins/rspec/lib/spec/story/story.rb +5 -5
  215. data/rails_plugins/rspec/lib/spec/story/world.rb +16 -16
  216. data/rails_plugins/rspec/lib/spec/translator.rb +21 -21
  217. data/rails_plugins/rspec/lib/spec/version.rb +2 -2
  218. data/rails_plugins/rspec/lib/spec.rb +1 -1
  219. data/rails_plugins/rspec/pre_commit/lib/pre_commit/pre_commit.rb +1 -1
  220. data/rails_plugins/rspec/pre_commit/lib/pre_commit/rspec.rb +6 -6
  221. data/rails_plugins/rspec/pre_commit/lib/pre_commit/rspec_on_rails.rb +6 -6
  222. data/rails_plugins/rspec/pre_commit/spec/pre_commit/pre_commit_spec.rb +1 -1
  223. data/rails_plugins/rspec/pre_commit/spec/pre_commit/rspec_on_rails_spec.rb +1 -1
  224. data/rails_plugins/rspec/report.html +3 -3
  225. data/rails_plugins/rspec/spec/autotest/discover_spec.rb +2 -2
  226. data/rails_plugins/rspec/spec/autotest/rspec_spec.rb +30 -30
  227. data/rails_plugins/rspec/spec/autotest_matchers.rb +7 -7
  228. data/rails_plugins/rspec/spec/spec/example/configuration_spec.rb +5 -5
  229. data/rails_plugins/rspec/spec/spec/example/example_group_factory_spec.rb +5 -5
  230. data/rails_plugins/rspec/spec/spec/example/example_group_methods_spec.rb +3 -3
  231. data/rails_plugins/rspec/spec/spec/example/example_group_spec.rb +2 -2
  232. data/rails_plugins/rspec/spec/spec/example/example_matcher_spec.rb +10 -10
  233. data/rails_plugins/rspec/spec/spec/example/example_runner_spec.rb +29 -29
  234. data/rails_plugins/rspec/spec/spec/example/example_spec.rb +6 -6
  235. data/rails_plugins/rspec/spec/spec/example/nested_example_group_spec.rb +2 -2
  236. data/rails_plugins/rspec/spec/spec/example/pending_module_spec.rb +3 -3
  237. data/rails_plugins/rspec/spec/spec/example/predicate_matcher_spec.rb +1 -1
  238. data/rails_plugins/rspec/spec/spec/example/shared_example_group_spec.rb +4 -4
  239. data/rails_plugins/rspec/spec/spec/expectations/extensions/object_spec.rb +12 -12
  240. data/rails_plugins/rspec/spec/spec/expectations/fail_with_spec.rb +8 -8
  241. data/rails_plugins/rspec/spec/spec/extensions/main_spec.rb +6 -6
  242. data/rails_plugins/rspec/spec/spec/interop/test/unit/spec_spec.rb +2 -2
  243. data/rails_plugins/rspec/spec/spec/interop/test/unit/test_unit_spec_helper.rb +2 -2
  244. data/rails_plugins/rspec/spec/spec/interop/test/unit/testcase_spec.rb +2 -2
  245. data/rails_plugins/rspec/spec/spec/matchers/be_spec.rb +5 -5
  246. data/rails_plugins/rspec/spec/spec/matchers/change_spec.rb +14 -14
  247. data/rails_plugins/rspec/spec/spec/matchers/description_generation_spec.rb +25 -25
  248. data/rails_plugins/rspec/spec/spec/matchers/exist_spec.rb +5 -5
  249. data/rails_plugins/rspec/spec/spec/matchers/handler_spec.rb +16 -16
  250. data/rails_plugins/rspec/spec/spec/matchers/have_spec.rb +13 -13
  251. data/rails_plugins/rspec/spec/spec/matchers/match_spec.rb +1 -1
  252. data/rails_plugins/rspec/spec/spec/matchers/matcher_methods_spec.rb +1 -1
  253. data/rails_plugins/rspec/spec/spec/matchers/operator_matcher_spec.rb +17 -17
  254. data/rails_plugins/rspec/spec/spec/matchers/raise_error_spec.rb +20 -20
  255. data/rails_plugins/rspec/spec/spec/matchers/respond_to_spec.rb +10 -10
  256. data/rails_plugins/rspec/spec/spec/matchers/simple_matcher_spec.rb +3 -3
  257. data/rails_plugins/rspec/spec/spec/matchers/throw_symbol_spec.rb +2 -2
  258. data/rails_plugins/rspec/spec/spec/mocks/any_number_of_times_spec.rb +2 -2
  259. data/rails_plugins/rspec/spec/spec/mocks/bug_report_10263.rb +3 -3
  260. data/rails_plugins/rspec/spec/spec/mocks/bug_report_11545_spec.rb +4 -4
  261. data/rails_plugins/rspec/spec/spec/mocks/bug_report_15719_spec.rb +1 -1
  262. data/rails_plugins/rspec/spec/spec/mocks/bug_report_7611_spec.rb +1 -1
  263. data/rails_plugins/rspec/spec/spec/mocks/bug_report_8302_spec.rb +1 -1
  264. data/rails_plugins/rspec/spec/spec/mocks/failing_mock_argument_constraints_spec.rb +12 -12
  265. data/rails_plugins/rspec/spec/spec/mocks/mock_ordering_spec.rb +3 -3
  266. data/rails_plugins/rspec/spec/spec/mocks/mock_space_spec.rb +1 -1
  267. data/rails_plugins/rspec/spec/spec/mocks/mock_spec.rb +56 -56
  268. data/rails_plugins/rspec/spec/spec/mocks/multiple_return_value_spec.rb +3 -3
  269. data/rails_plugins/rspec/spec/spec/mocks/once_counts_spec.rb +1 -1
  270. data/rails_plugins/rspec/spec/spec/mocks/options_hash_spec.rb +1 -1
  271. data/rails_plugins/rspec/spec/spec/mocks/partial_mock_spec.rb +16 -16
  272. data/rails_plugins/rspec/spec/spec/mocks/partial_mock_using_mocks_directly_spec.rb +10 -10
  273. data/rails_plugins/rspec/spec/spec/mocks/passing_mock_argument_constraints_spec.rb +13 -13
  274. data/rails_plugins/rspec/spec/spec/mocks/stub_spec.rb +7 -7
  275. data/rails_plugins/rspec/spec/spec/mocks/twice_counts_spec.rb +6 -6
  276. data/rails_plugins/rspec/spec/spec/package/bin_spec_spec.rb +1 -1
  277. data/rails_plugins/rspec/spec/spec/runner/class_and_argument_parser_spec.rb +2 -2
  278. data/rails_plugins/rspec/spec/spec/runner/command_line_spec.rb +1 -1
  279. data/rails_plugins/rspec/spec/spec/runner/drb_command_line_spec.rb +2 -2
  280. data/rails_plugins/rspec/spec/spec/runner/execution_context_spec.rb +2 -2
  281. data/rails_plugins/rspec/spec/spec/runner/formatter/failing_example_groups_formatter_spec.rb +2 -2
  282. data/rails_plugins/rspec/spec/spec/runner/formatter/html_formatted-1.8.4.html +1 -1
  283. data/rails_plugins/rspec/spec/spec/runner/formatter/html_formatted-1.8.5-jruby.html +2 -2
  284. data/rails_plugins/rspec/spec/spec/runner/formatter/html_formatted-1.8.5.html +1 -1
  285. data/rails_plugins/rspec/spec/spec/runner/formatter/html_formatted-1.8.6-jruby.html +1 -1
  286. data/rails_plugins/rspec/spec/spec/runner/formatter/html_formatted-1.8.6.html +3 -3
  287. data/rails_plugins/rspec/spec/spec/runner/formatter/html_formatter_spec.rb +1 -1
  288. data/rails_plugins/rspec/spec/spec/runner/formatter/profile_formatter_spec.rb +9 -9
  289. data/rails_plugins/rspec/spec/spec/runner/formatter/progress_bar_formatter_spec.rb +4 -4
  290. data/rails_plugins/rspec/spec/spec/runner/formatter/spec_mate_formatter_spec.rb +1 -1
  291. data/rails_plugins/rspec/spec/spec/runner/formatter/story/html_formatter_spec.rb +5 -5
  292. data/rails_plugins/rspec/spec/spec/runner/formatter/text_mate_formatted-1.8.4.html +13 -13
  293. data/rails_plugins/rspec/spec/spec/runner/formatter/text_mate_formatted-1.8.6.html +2 -2
  294. data/rails_plugins/rspec/spec/spec/runner/heckle_runner_spec.rb +1 -1
  295. data/rails_plugins/rspec/spec/spec/runner/noisy_backtrace_tweaker_spec.rb +3 -3
  296. data/rails_plugins/rspec/spec/spec/runner/option_parser_spec.rb +9 -9
  297. data/rails_plugins/rspec/spec/spec/runner/options_spec.rb +13 -13
  298. data/rails_plugins/rspec/spec/spec/runner/quiet_backtrace_tweaker_spec.rb +1 -1
  299. data/rails_plugins/rspec/spec/spec/spec_classes.rb +8 -8
  300. data/rails_plugins/rspec/spec/spec/story/builders.rb +7 -7
  301. data/rails_plugins/rspec/spec/spec/story/extensions/main_spec.rb +6 -6
  302. data/rails_plugins/rspec/spec/spec/story/given_scenario_spec.rb +3 -3
  303. data/rails_plugins/rspec/spec/spec/story/runner/plain_text_story_runner_spec.rb +12 -12
  304. data/rails_plugins/rspec/spec/spec/story/runner/scenario_collector_spec.rb +2 -2
  305. data/rails_plugins/rspec/spec/spec/story/runner/scenario_runner_spec.rb +21 -21
  306. data/rails_plugins/rspec/spec/spec/story/runner/story_mediator_spec.rb +22 -22
  307. data/rails_plugins/rspec/spec/spec/story/runner/story_parser_spec.rb +55 -55
  308. data/rails_plugins/rspec/spec/spec/story/runner/story_runner_spec.rb +44 -44
  309. data/rails_plugins/rspec/spec/spec/story/runner_spec.rb +18 -18
  310. data/rails_plugins/rspec/spec/spec/story/scenario_spec.rb +2 -2
  311. data/rails_plugins/rspec/spec/spec/story/step_group_spec.rb +20 -20
  312. data/rails_plugins/rspec/spec/spec/story/step_mother_spec.rb +14 -14
  313. data/rails_plugins/rspec/spec/spec/story/step_spec.rb +33 -33
  314. data/rails_plugins/rspec/spec/spec/story/story_spec.rb +12 -12
  315. data/rails_plugins/rspec/spec/spec/translator_spec.rb +12 -12
  316. data/rails_plugins/rspec/spec/spec_helper.rb +5 -5
  317. data/rails_plugins/rspec/stories/resources/helpers/story_helper.rb +1 -1
  318. data/rails_plugins/rspec/stories/resources/steps/running_rspec.rb +4 -4
  319. data/rails_plugins/rspec/stories/resources/test/spec_and_test_together.rb +2 -2
  320. data/rails_plugins/rspec/stories/resources/test/test_case_with_should_methods.rb +1 -1
  321. data/rails_plugins/rspec/story_server/prototype/javascripts/builder.js +14 -14
  322. data/rails_plugins/rspec/story_server/prototype/javascripts/controls.js +61 -61
  323. data/rails_plugins/rspec/story_server/prototype/javascripts/dragdrop.js +144 -144
  324. data/rails_plugins/rspec/story_server/prototype/javascripts/effects.js +127 -127
  325. data/rails_plugins/rspec/story_server/prototype/javascripts/rspec.js +15 -15
  326. data/rails_plugins/rspec/story_server/prototype/javascripts/scriptaculous.js +7 -7
  327. data/rails_plugins/rspec/story_server/prototype/javascripts/slider.js +37 -37
  328. data/rails_plugins/rspec/story_server/prototype/javascripts/sound.js +4 -4
  329. data/rails_plugins/rspec/story_server/prototype/javascripts/unittest.js +66 -66
  330. data/rails_plugins/rspec/story_server/prototype/stories.html +9 -9
  331. data/rails_plugins/rspec_on_rails/MIT-LICENSE +11 -11
  332. data/rails_plugins/rspec_on_rails/generators/rspec/templates/rcov.opts +1 -1
  333. data/rails_plugins/rspec_on_rails/generators/rspec/templates/script/spec_server +1 -1
  334. data/rails_plugins/rspec_on_rails/generators/rspec_controller/USAGE +1 -1
  335. data/rails_plugins/rspec_on_rails/generators/rspec_controller/templates/helper_spec.rb +2 -2
  336. data/rails_plugins/rspec_on_rails/generators/rspec_controller/templates/view_spec.rb +1 -1
  337. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/rspec_scaffold_generator.rb +12 -12
  338. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/templates/controller_spec.rb +35 -35
  339. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/templates/edit_erb_spec.rb +2 -2
  340. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/templates/helper_spec.rb +2 -2
  341. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/templates/index_erb_spec.rb +1 -1
  342. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/templates/new_erb_spec.rb +2 -2
  343. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/templates/routing_spec.rb +11 -11
  344. data/rails_plugins/rspec_on_rails/generators/rspec_scaffold/templates/show_erb_spec.rb +1 -1
  345. data/rails_plugins/rspec_on_rails/lib/autotest/rails_rspec.rb +3 -3
  346. data/rails_plugins/rspec_on_rails/lib/spec/rails/example/controller_example_group.rb +4 -4
  347. data/rails_plugins/rspec_on_rails/lib/spec/rails/example/rails_example_group.rb +1 -1
  348. data/rails_plugins/rspec_on_rails/lib/spec/rails/example/render_observer.rb +4 -4
  349. data/rails_plugins/rspec_on_rails/lib/spec/rails/example/view_example_group.rb +1 -1
  350. data/rails_plugins/rspec_on_rails/lib/spec/rails/extensions/action_controller/base.rb +1 -1
  351. data/rails_plugins/rspec_on_rails/lib/spec/rails/extensions/spec/matchers/have.rb +1 -1
  352. data/rails_plugins/rspec_on_rails/lib/spec/rails/matchers/assert_select.rb +10 -10
  353. data/rails_plugins/rspec_on_rails/lib/spec/rails/matchers/have_text.rb +6 -6
  354. data/rails_plugins/rspec_on_rails/lib/spec/rails/matchers/render_template.rb +7 -7
  355. data/rails_plugins/rspec_on_rails/lib/spec/rails/story_adapter.rb +1 -1
  356. data/rails_plugins/rspec_on_rails/lib/spec/rails.rb +8 -8
  357. data/rails_plugins/rspec_on_rails/spec/rails/autotest/mappings_spec.rb +6 -6
  358. data/rails_plugins/rspec_on_rails/spec/rails/example/controller_isolation_spec.rb +1 -1
  359. data/rails_plugins/rspec_on_rails/spec/rails/example/controller_spec_spec.rb +22 -22
  360. data/rails_plugins/rspec_on_rails/spec/rails/example/helper_spec_spec.rb +1 -1
  361. data/rails_plugins/rspec_on_rails/spec/rails/example/ivar_proxy_spec.rb +3 -3
  362. data/rails_plugins/rspec_on_rails/spec/rails/example/shared_behaviour_spec.rb +2 -2
  363. data/rails_plugins/rspec_on_rails/spec/rails/example/view_spec_spec.rb +8 -8
  364. data/rails_plugins/rspec_on_rails/spec/rails/extensions/action_view_base_spec.rb +7 -7
  365. data/rails_plugins/rspec_on_rails/spec/rails/extensions/active_record_spec.rb +1 -1
  366. data/rails_plugins/rspec_on_rails/spec/rails/matchers/assert_select_spec.rb +37 -37
  367. data/rails_plugins/rspec_on_rails/spec/rails/matchers/description_generation_spec.rb +1 -1
  368. data/rails_plugins/rspec_on_rails/spec/rails/matchers/have_text_spec.rb +4 -4
  369. data/rails_plugins/rspec_on_rails/spec/rails/matchers/redirect_to_spec.rb +26 -26
  370. data/rails_plugins/rspec_on_rails/spec/rails/matchers/render_spec.rb +18 -18
  371. data/rails_plugins/rspec_on_rails/spec/rails/mocks/mock_model_spec.rb +2 -2
  372. data/rails_plugins/rspec_on_rails/spec/spec_helper.rb +1 -1
  373. data/rails_plugins/rspec_on_rails/spec_resources/controllers/controller_spec_controller.rb +9 -9
  374. data/rails_plugins/rspec_on_rails/spec_resources/controllers/redirect_spec_controller.rb +7 -7
  375. data/rails_plugins/rspec_on_rails/spec_resources/controllers/render_spec_controller.rb +5 -5
  376. data/rails_plugins/rspec_on_rails/spec_resources/controllers/rjs_spec_controller.rb +10 -10
  377. data/rails_plugins/rspec_on_rails/spec_resources/helpers/explicit_helper.rb +1 -1
  378. data/rails_plugins/rspec_on_rails/stories/transactions_should_rollback.rb +1 -1
  379. data/rails_plugins/rspec_on_rails/tasks/rspec.rake +4 -4
  380. data/script/txt2html +1 -1
  381. data/setup.rb +4 -4
  382. data/tasks/hack.rake +3 -3
  383. data/website/index.html +2 -2
  384. data/website/index.txt +1 -1
  385. data/website/index_devjavu +3 -3
  386. data/website/javascripts/rounded_corners_lite.inc.js +1 -1
  387. data/website/stylesheets/screen.css +2 -2
  388. data.tar.gz.sig +0 -0
  389. metadata +2 -1
  390. metadata.gz.sig +2 -1
@@ -7,15 +7,15 @@ module Spec
7
7
  def initialize(description)
8
8
  @description = description
9
9
  end
10
-
10
+
11
11
  def matches?(matcher)
12
12
  matcher.matches?(@description)
13
13
  end
14
-
14
+
15
15
  def failure_message
16
16
  "expected matcher.matches?(#{@description.inspect}) to return true, got false"
17
17
  end
18
-
18
+
19
19
  def negative_failure_message
20
20
  "expected matcher.matches?(#{@description.inspect}) to return false, got true"
21
21
  end
@@ -27,22 +27,22 @@ module Spec
27
27
 
28
28
  describe ExampleMatcher, "#matches?" do
29
29
  include ExampleMatcherSpecHelper
30
-
30
+
31
31
  it "should match correct example_group and example" do
32
32
  matcher = ExampleMatcher.new("example_group", "example")
33
33
  matcher.should match_description("example_group example")
34
34
  end
35
-
35
+
36
36
  it "should not match wrong example" do
37
37
  matcher = ExampleMatcher.new("example_group", "other example")
38
38
  matcher.should_not match_description("example_group example")
39
39
  end
40
-
40
+
41
41
  it "should not match wrong example_group" do
42
42
  matcher = ExampleMatcher.new("other example_group", "example")
43
43
  matcher.should_not match_description("example_group example")
44
44
  end
45
-
45
+
46
46
  it "should match example only" do
47
47
  matcher = ExampleMatcher.new("example_group", "example")
48
48
  matcher.should match_description("example")
@@ -57,16 +57,16 @@ module Spec
57
57
  matcher = ExampleMatcher.new("example_group", "example")
58
58
  matcher.should match_description("example_group before(:all)")
59
59
  end
60
-
60
+
61
61
  it "should escape regexp chars" do
62
62
  matcher = ExampleMatcher.new("(con|text)", "[example]")
63
63
  matcher.should_not match_description("con p")
64
64
  end
65
-
65
+
66
66
  it "should match when example_group is modularized" do
67
67
  matcher = ExampleMatcher.new("MyModule::MyClass", "example")
68
68
  matcher.should match_description("MyClass example")
69
- end
69
+ end
70
70
  end
71
71
 
72
72
  describe ExampleMatcher, "#matches? normal case" do
@@ -12,7 +12,7 @@ module Spec
12
12
  # describe("Some Examples")
13
13
  # end
14
14
  # end
15
- #
15
+ #
16
16
  # def create_runner(example_definition)
17
17
  # example = @example_group_class.new(example_definition)
18
18
  # runner = ExampleGroup.new(@options, example)
@@ -21,43 +21,43 @@ module Spec
21
21
  # runner
22
22
  # end
23
23
  # end
24
- #
24
+ #
25
25
  # describe ExampleRunner, "#run with blank passing example" do
26
26
  # it_should_behave_like "Spec::Example::ExampleRunner#run"
27
- #
27
+ #
28
28
  # before do
29
29
  # @e = @example_group_class.it("example") {}
30
30
  # @runner = create_runner(@e)
31
31
  # end
32
- #
32
+ #
33
33
  # it "should send reporter example_started" do
34
34
  # @reporter.should_receive(:example_started).with(equal(@e))
35
35
  # @runner.run
36
36
  # end
37
- #
37
+ #
38
38
  # it "should report its name for dry run" do
39
39
  # @options.dry_run = true
40
40
  # @reporter.should_receive(:example_finished).with(equal(@e), nil)
41
41
  # @runner.run
42
42
  # end
43
- #
43
+ #
44
44
  # it "should report success" do
45
45
  # @reporter.should_receive(:example_finished).with(equal(@e), nil)
46
46
  # @runner.run
47
47
  # end
48
48
  # end
49
- #
49
+ #
50
50
  # describe ExampleRunner, "#run with a failing example" do
51
51
  # predicate_matchers[:is_a] = [:is_a?]
52
52
  # it_should_behave_like "Spec::Example::ExampleRunner#run"
53
- #
53
+ #
54
54
  # before do
55
55
  # @e = @example_group_class.it("example") do
56
56
  # (2+2).should == 5
57
57
  # end
58
58
  # @runner = create_runner(@e)
59
59
  # end
60
- #
60
+ #
61
61
  # it "should report failure due to failure" do
62
62
  # @reporter.should_receive(:example_finished).with(
63
63
  # equal(@e),
@@ -66,10 +66,10 @@ module Spec
66
66
  # @runner.run
67
67
  # end
68
68
  # end
69
- #
69
+ #
70
70
  # describe ExampleRunner, "#run with a erroring example" do
71
71
  # it_should_behave_like "Spec::Example::ExampleRunner#run"
72
- #
72
+ #
73
73
  # before do
74
74
  # @error = error = NonStandardError.new("in body")
75
75
  # @example_definition = @example_group_class.it("example") do
@@ -77,7 +77,7 @@ module Spec
77
77
  # end
78
78
  # @runner = create_runner(@example_definition)
79
79
  # end
80
- #
80
+ #
81
81
  # it "should report failure due to error" do
82
82
  # @reporter.should_receive(:example_finished).with(
83
83
  # equal(@example_definition),
@@ -85,7 +85,7 @@ module Spec
85
85
  # )
86
86
  # @runner.run
87
87
  # end
88
- #
88
+ #
89
89
  # it "should run after_each block" do
90
90
  # @example_group_class.after(:each) do
91
91
  # raise("in after_each")
@@ -95,12 +95,12 @@ module Spec
95
95
  # error.message.should eql("in body")
96
96
  # end
97
97
  # @runner.run
98
- # end
98
+ # end
99
99
  # end
100
- #
100
+ #
101
101
  # describe ExampleRunner, "#run where after_each fails" do
102
102
  # it_should_behave_like "Spec::Example::ExampleRunner#run"
103
- #
103
+ #
104
104
  # before do
105
105
  # @example_ran = example_ran = false
106
106
  # @example_definition = @example_group_class.it("should not run") do
@@ -109,7 +109,7 @@ module Spec
109
109
  # @runner = create_runner(@example_definition)
110
110
  # @example_group_class.after(:each) { raise(NonStandardError.new("in after_each")) }
111
111
  # end
112
- #
112
+ #
113
113
  # it "should report failure location when in after_each" do
114
114
  # @reporter.should_receive(:example_finished) do |example_definition, error|
115
115
  # example_definition.should equal(@example_definition)
@@ -118,37 +118,37 @@ module Spec
118
118
  # @runner.run
119
119
  # end
120
120
  # end
121
- #
121
+ #
122
122
  # describe ExampleRunner, "#run with use cases" do
123
123
  # predicate_matchers[:is_a] = [:is_a?]
124
124
  # it_should_behave_like "Spec::Example::ExampleRunner#run"
125
- #
125
+ #
126
126
  # it "should report NO NAME when told to use generated description with --dry-run" do
127
127
  # @options.dry_run = true
128
128
  # example_definition = @example_group_class.it() do
129
129
  # 5.should == 5
130
130
  # end
131
131
  # runner = create_runner(example_definition)
132
- #
132
+ #
133
133
  # @reporter.should_receive(:example_finished) do |example_definition, error|
134
134
  # example_definition.description.should == "NO NAME (Because of --dry-run)"
135
135
  # end
136
136
  # runner.run
137
137
  # end
138
- #
138
+ #
139
139
  # it "should report given name if present with --dry-run" do
140
140
  # @options.dry_run = true
141
141
  # example_definition = @example_group_class.it("example name") do
142
142
  # 5.should == 5
143
143
  # end
144
144
  # runner = create_runner(example_definition)
145
- #
145
+ #
146
146
  # @reporter.should_receive(:example_finished) do |example_definition, error|
147
147
  # example_definition.description.should == "example name"
148
148
  # end
149
149
  # runner.run
150
150
  # end
151
- #
151
+ #
152
152
  # it "should report NO NAME when told to use generated description with no expectations" do
153
153
  # example_definition = @example_group_class.it() {}
154
154
  # runner = create_runner(example_definition)
@@ -157,35 +157,35 @@ module Spec
157
157
  # end
158
158
  # runner.run
159
159
  # end
160
- #
160
+ #
161
161
  # it "should report NO NAME when told to use generated description and matcher fails" do
162
162
  # example_definition = @example_group_class.it() do
163
163
  # 5.should "" # Has no matches? method..
164
164
  # end
165
165
  # runner = create_runner(example_definition)
166
- #
166
+ #
167
167
  # @reporter.should_receive(:example_finished) do |example, error|
168
168
  # example_definition.description.should == "NO NAME (Because of Error raised in matcher)"
169
169
  # end
170
170
  # runner.run
171
171
  # end
172
- #
172
+ #
173
173
  # it "should report generated description when told to and it is available" do
174
174
  # example_definition = @example_group_class.it() {
175
175
  # 5.should == 5
176
176
  # }
177
177
  # runner = create_runner(example_definition)
178
- #
178
+ #
179
179
  # @reporter.should_receive(:example_finished) do |example_definition, error|
180
180
  # example_definition.description.should == "should == 5"
181
181
  # end
182
182
  # runner.run
183
183
  # end
184
- #
184
+ #
185
185
  # it "should unregister description_generated callback (lest a memory leak should build up)" do
186
186
  # example_definition = @example_group_class.it("something")
187
187
  # runner = create_runner(example_definition)
188
- #
188
+ #
189
189
  # Spec::Matchers.should_receive(:example_finished)
190
190
  # runner.run
191
191
  # end
@@ -8,11 +8,11 @@ module Spec
8
8
  # foo
9
9
  # end
10
10
  # end
11
- #
11
+ #
12
12
  # it "should tell you its docstring" do
13
13
  # @example.description.should == "example"
14
14
  # end
15
- #
15
+ #
16
16
  # it "should execute its block in the context provided" do
17
17
  # context = Class.new do
18
18
  # def foo
@@ -22,25 +22,25 @@ module Spec
22
22
  # @example.run_in(context).should == "foo"
23
23
  # end
24
24
  # end
25
- #
25
+ #
26
26
  # describe Example, "#description" do
27
27
  # it "should default to NO NAME when not passed anything when there are no matchers" do
28
28
  # example = Example.new {}
29
29
  # example.run_in(Object.new)
30
30
  # example.description.should == "NO NAME"
31
31
  # end
32
- #
32
+ #
33
33
  # it "should default to NO NAME description (Because of --dry-run) when passed nil and there are no matchers" do
34
34
  # example = Example.new(nil) {}
35
35
  # example.run_in(Object.new)
36
36
  # example.description.should == "NO NAME"
37
37
  # end
38
- #
38
+ #
39
39
  # it "should allow description to be overridden" do
40
40
  # example = Example.new("Test description")
41
41
  # example.description.should == "Test description"
42
42
  # end
43
- #
43
+ #
44
44
  # it "should use description generated from matcher when there is no passed in description" do
45
45
  # example = Example.new(nil) do
46
46
  # 1.should == 1
@@ -4,7 +4,7 @@ module Spec
4
4
  module Example
5
5
  describe 'Nested Example Groups' do
6
6
  parent = self
7
-
7
+
8
8
  def count
9
9
  @count ||= 0
10
10
  @count = @count + 1
@@ -49,7 +49,7 @@ module Spec
49
49
 
50
50
  describe 'nested example group' do
51
51
  self.superclass.should == parent
52
-
52
+
53
53
  it "should run all before and after callbacks" do
54
54
  count.should == 5
55
55
  end
@@ -1,14 +1,14 @@
1
1
  module Spec
2
2
  module Example
3
3
  describe Pending do
4
-
4
+
5
5
  it 'should raise an ExamplePendingError if no block is supplied' do
6
6
  lambda {
7
7
  include Pending
8
8
  pending "TODO"
9
9
  }.should raise_error(ExamplePendingError, /TODO/)
10
10
  end
11
-
11
+
12
12
  it 'should raise an ExamplePendingError if a supplied block fails as expected' do
13
13
  lambda {
14
14
  include Pending
@@ -17,7 +17,7 @@ module Spec
17
17
  end
18
18
  }.should raise_error(ExamplePendingError, /TODO/)
19
19
  end
20
-
20
+
21
21
  it 'should raise a PendingExampleFixedError if a supplied block starts working' do
22
22
  lambda {
23
23
  include Pending
@@ -7,7 +7,7 @@ module Spec
7
7
  distance_in_yards < 1000
8
8
  end
9
9
  end
10
-
10
+
11
11
  describe "predicate_matcher[method_on_object] = matcher_method" do
12
12
  predicate_matchers[:swim] = :can_swim?
13
13
  it "should match matcher_method if method_on_object returns true" do
@@ -130,11 +130,11 @@ module Spec
130
130
  shared_example_group = describe "all things", :shared => true do
131
131
  it "should do stuff" do end
132
132
  end
133
-
133
+
134
134
  example_group = describe "one thing" do
135
135
  include shared_example_group
136
136
  end
137
-
137
+
138
138
  example_group.number_of_examples.should == 1
139
139
  end
140
140
 
@@ -142,11 +142,11 @@ module Spec
142
142
  AllThings = describe "all things", :shared => true do
143
143
  it "should do stuff" do end
144
144
  end
145
-
145
+
146
146
  example_group = describe "one thing" do
147
147
  it_should_behave_like AllThings
148
148
  end
149
-
149
+
150
150
  example_group.number_of_examples.should == 1
151
151
  end
152
152
 
@@ -7,12 +7,12 @@ describe Object, "#should" do
7
7
  @matcher.stub!(:matches?).and_return(true)
8
8
  @matcher.stub!(:failure_message)
9
9
  end
10
-
10
+
11
11
  it "should accept and interact with a matcher" do
12
- @matcher.should_receive(:matches?).with(@target).and_return(true)
12
+ @matcher.should_receive(:matches?).with(@target).and_return(true)
13
13
  @target.should @matcher
14
14
  end
15
-
15
+
16
16
  it "should ask for a failure_message when matches? returns false" do
17
17
  @matcher.should_receive(:matches?).with(@target).and_return(false)
18
18
  @matcher.should_receive(:failure_message).and_return("the failure message")
@@ -20,25 +20,25 @@ describe Object, "#should" do
20
20
  @target.should @matcher
21
21
  }.should fail_with("the failure message")
22
22
  end
23
-
23
+
24
24
  it "should raise error if it receives false directly" do
25
25
  lambda {
26
26
  @target.should false
27
27
  }.should raise_error(Spec::Expectations::InvalidMatcherError)
28
28
  end
29
-
29
+
30
30
  it "should raise error if it receives false (evaluated)" do
31
31
  lambda {
32
32
  @target.should eql?("foo")
33
33
  }.should raise_error(Spec::Expectations::InvalidMatcherError)
34
34
  end
35
-
35
+
36
36
  it "should raise error if it receives true" do
37
37
  lambda {
38
38
  @target.should true
39
39
  }.should raise_error(Spec::Expectations::InvalidMatcherError)
40
40
  end
41
-
41
+
42
42
  it "should raise error if it receives nil" do
43
43
  lambda {
44
44
  @target.should nil
@@ -58,14 +58,14 @@ describe Object, "#should_not" do
58
58
  @target = "target"
59
59
  @matcher = mock("matcher")
60
60
  end
61
-
61
+
62
62
  it "should accept and interact with a matcher" do
63
63
  @matcher.should_receive(:matches?).with(@target).and_return(false)
64
64
  @matcher.stub!(:negative_failure_message)
65
-
65
+
66
66
  @target.should_not @matcher
67
67
  end
68
-
68
+
69
69
  it "should ask for a negative_failure_message when matches? returns true" do
70
70
  @matcher.should_receive(:matches?).with(@target).and_return(true)
71
71
  @matcher.should_receive(:negative_failure_message).and_return("the negative failure message")
@@ -79,13 +79,13 @@ describe Object, "#should_not" do
79
79
  @target.should_not false
80
80
  }.should raise_error(Spec::Expectations::InvalidMatcherError)
81
81
  end
82
-
82
+
83
83
  it "should raise error if it receives false (evaluated)" do
84
84
  lambda {
85
85
  @target.should_not eql?("foo")
86
86
  }.should raise_error(Spec::Expectations::InvalidMatcherError)
87
87
  end
88
-
88
+
89
89
  it "should raise error if it receives true" do
90
90
  lambda {
91
91
  @target.should_not true
@@ -5,13 +5,13 @@ describe Spec::Expectations, "#fail_with with no diff" do
5
5
  @old_differ = Spec::Expectations.differ
6
6
  Spec::Expectations.differ = nil
7
7
  end
8
-
8
+
9
9
  it "should handle just a message" do
10
10
  lambda {
11
11
  Spec::Expectations.fail_with "the message"
12
12
  }.should fail_with("the message")
13
13
  end
14
-
14
+
15
15
  it "should handle an Array" do
16
16
  lambda {
17
17
  Spec::Expectations.fail_with ["the message","expected","actual"]
@@ -29,27 +29,27 @@ describe Spec::Expectations, "#fail_with with diff" do
29
29
  @differ = mock("differ")
30
30
  Spec::Expectations.differ = @differ
31
31
  end
32
-
32
+
33
33
  it "should not call differ if no expected/actual" do
34
34
  lambda {
35
35
  Spec::Expectations.fail_with "the message"
36
36
  }.should fail_with("the message")
37
37
  end
38
-
38
+
39
39
  it "should call differ if expected/actual are presented separately" do
40
40
  @differ.should_receive(:diff_as_string).and_return("diff")
41
41
  lambda {
42
42
  Spec::Expectations.fail_with "the message", "expected", "actual"
43
43
  }.should fail_with("the message\nDiff:diff")
44
44
  end
45
-
45
+
46
46
  it "should call differ if expected/actual are not strings" do
47
47
  @differ.should_receive(:diff_as_object).and_return("diff")
48
48
  lambda {
49
49
  Spec::Expectations.fail_with "the message", :expected, :actual
50
50
  }.should fail_with("the message\nDiff:diff")
51
51
  end
52
-
52
+
53
53
  it "should not call differ if expected or actual are procs" do
54
54
  @differ.should_not_receive(:diff_as_string)
55
55
  @differ.should_not_receive(:diff_as_object)
@@ -57,14 +57,14 @@ describe Spec::Expectations, "#fail_with with diff" do
57
57
  Spec::Expectations.fail_with "the message", lambda {}, lambda {}
58
58
  }.should fail_with("the message")
59
59
  end
60
-
60
+
61
61
  it "should call differ if expected/actual are presented in an Array with message" do
62
62
  @differ.should_receive(:diff_as_string).with("actual","expected").and_return("diff")
63
63
  lambda {
64
64
  Spec::Expectations.fail_with(["the message", "expected", "actual"])
65
65
  }.should fail_with(/the message\nDiff:diff/)
66
66
  end
67
-
67
+
68
68
  after(:each) do
69
69
  Spec::Expectations.differ = @old_differ
70
70
  end
@@ -16,7 +16,7 @@ module Spec
16
16
  @main.send(:rspec_options).should be_instance_of(Spec::Runner::Options)
17
17
  @main.send(:rspec_options).should === $rspec_options
18
18
  end
19
-
19
+
20
20
  specify {@main.should respond_to(:describe)}
21
21
  specify {@main.should respond_to(:context)}
22
22
 
@@ -40,12 +40,12 @@ module Spec
40
40
 
41
41
  rspec_options.example_groups.should_not include(example_group)
42
42
  end
43
-
43
+
44
44
  it "should create a shared ExampleGroup with share_examples_for" do
45
45
  group = @main.share_examples_for "all things" do end
46
46
  group.should be_an_instance_of(Spec::Example::SharedExampleGroup)
47
47
  end
48
-
48
+
49
49
  describe "#share_as" do
50
50
  before(:each) do
51
51
  $share_as_examples_example_module_number ||= 1
@@ -58,18 +58,18 @@ module Spec
58
58
  group = @main.share_as @group_name do end
59
59
  group.should be_an_instance_of(Spec::Example::SharedExampleGroup)
60
60
  end
61
-
61
+
62
62
  it "should create a constant that points to a Module" do
63
63
  group = @main.share_as @group_name do end
64
64
  Object.const_get(@group_name).should equal(group)
65
65
  end
66
-
66
+
67
67
  it "should bark if you pass it something not-constantizable" do
68
68
  lambda do
69
69
  @group = @main.share_as "Non Constant" do end
70
70
  end.should raise_error(NameError, /The first argument to share_as must be a legal name for a constant/)
71
71
  end
72
-
72
+
73
73
  end
74
74
  end
75
75
  end
@@ -2,11 +2,11 @@ require File.dirname(__FILE__) + '/test_unit_spec_helper'
2
2
 
3
3
  describe "ExampleGroup with test/unit/interop" do
4
4
  include TestUnitSpecHelper
5
-
5
+
6
6
  before(:each) do
7
7
  @dir = File.dirname(__FILE__) + "/resources"
8
8
  end
9
-
9
+
10
10
  describe "with passing examples" do
11
11
  it "should output 0 failures" do
12
12
  output = ruby("#{@dir}/spec_that_passes.rb")
@@ -3,12 +3,12 @@ require File.dirname(__FILE__) + '/../../../../ruby_forker'
3
3
 
4
4
  module TestUnitSpecHelper
5
5
  include RubyForker
6
-
6
+
7
7
  def run_script(file_name)
8
8
  output = ruby(file_name)
9
9
  if !$?.success? || output.include?("FAILED") || output.include?("Error")
10
10
  raise output
11
11
  end
12
12
  output
13
- end
13
+ end
14
14
  end
@@ -2,11 +2,11 @@ require File.dirname(__FILE__) + '/test_unit_spec_helper'
2
2
 
3
3
  describe "Test::Unit::TestCase" do
4
4
  include TestUnitSpecHelper
5
-
5
+
6
6
  before(:each) do
7
7
  @dir = File.dirname(__FILE__) + "/resources"
8
8
  end
9
-
9
+
10
10
  describe "with passing test case" do
11
11
  it "should output 0 failures" do
12
12
  output = ruby("#{@dir}/test_case_that_passes.rb")
@@ -1,6 +1,6 @@
1
1
  require File.dirname(__FILE__) + '/../../spec_helper.rb'
2
2
 
3
- describe "should be_predicate" do
3
+ describe "should be_predicate" do
4
4
  it "should pass when actual returns true for :predicate?" do
5
5
  actual = stub("actual", :happy? => true)
6
6
  actual.should be_happy
@@ -17,7 +17,7 @@ describe "should be_predicate" do
17
17
  actual.should be_happy
18
18
  }.should fail_with("expected happy? to return true, got false")
19
19
  end
20
-
20
+
21
21
  it "should fail when actual does not respond to :predicate?" do
22
22
  lambda {
23
23
  Object.new.should be_happy
@@ -30,7 +30,7 @@ describe "should_not be_predicate" do
30
30
  actual = stub("actual", :happy? => false)
31
31
  actual.should_not be_happy
32
32
  end
33
-
33
+
34
34
  it "should fail when actual returns true for :sym?" do
35
35
  actual = stub("actual", :happy? => true)
36
36
  lambda {
@@ -59,7 +59,7 @@ describe "should be_predicate(*args)" do
59
59
  actual.should be_older_than(3)
60
60
  }.should fail_with("expected older_than?(3) to return true, got false")
61
61
  end
62
-
62
+
63
63
  it "should fail when actual does not respond to :predicate?" do
64
64
  lambda {
65
65
  Object.new.should be_older_than(3)
@@ -73,7 +73,7 @@ describe "should_not be_predicate(*args)" do
73
73
  actual.should_receive(:older_than?).with(3).and_return(false)
74
74
  actual.should_not be_older_than(3)
75
75
  end
76
-
76
+
77
77
  it "should fail when actual returns true for :predicate?(*args)" do
78
78
  actual = mock("actual")
79
79
  actual.should_receive(:older_than?).with(3).and_return(true)