spork

Spork: how to refresh validations and other code?

风格不统一 提交于 2019-11-30 01:51:19
I've been using spork all day, and most of the time it is a really great. However, I am often running into a few problems where I need to restart Spork in order for my tests to pass... and now I'm wondering if it's more trouble than it's worth. I am new at ruby, so sometimes I can't predict if the error is due to a refresh problem, or if the error is due to my unfamiliarity with Ruby and Rails. What do I need to put into Spork.each_run block so that my validations and other things are refreshed so that I don't have to restart the spork server? Thanks Use Guard to reload Spork when you update

SimpleCov reports not generating in Rails 3 app after running RSpec tests with Spork

孤街浪徒 提交于 2019-11-29 03:22:38
问题 I just installed the SimpleCov gem to generate code coverage reports on my Rails 3.2.6 app, and it works great with RSpec, just not with Spork. I am able to get the desired correct report by running rspec --no-drb spec/ , but I'd like to also get them with Spork running using just rspec spec/ . Given that there have been people who have had success with this, it seems likely I have errors in my setup. I have read through the setup instructions as well as the GitHub issue that purports to have

spork 0.9.2 and rspec 3.0.0 = uninitialized constant RSpec::Core::CommandLine (NameError)

依然范特西╮ 提交于 2019-11-29 02:40:31
问题 Im using spork 0.9.2 and rspec 3.0.0. When trying to run test rspec --drb I have an exception C:/RailsInstaller/Ruby1.9.3/lib/ruby/gems/1.9.1/gems/spork-0.9.2/lib/spork/test_framework/rspec.rb:11:in run_tests: uninitialized constant RSpec::Core::CommandLine (NameError) But when changing rspec version back to 2.6 - everything is OK. Has anyone faced the same issue? Is it possible to work around? 回答1: The reason is that RSpec::Core::CommandLine was removed in Rspec3 https://github.com/rspec

Spork: how to refresh validations and other code?

感情迁移 提交于 2019-11-28 22:41:22
问题 I've been using spork all day, and most of the time it is a really great. However, I am often running into a few problems where I need to restart Spork in order for my tests to pass... and now I'm wondering if it's more trouble than it's worth. I am new at ruby, so sometimes I can't predict if the error is due to a refresh problem, or if the error is due to my unfamiliarity with Ruby and Rails. What do I need to put into Spork.each_run block so that my validations and other things are