# RSpec

**URL:** https://www.ruby-forum.com/c/testing/rspec/25.md?page=79

[Latest](https://www.ruby-forum.com/latest.md) · [Categories](https://www.ruby-forum.com/categories.md) · [Tags](https://www.ruby-forum.com/tags.md)

**Page:** 80

---

## [How to spec a Rails helper method](https://www.ruby-forum.com/t/how-to-spec-a-rails-helper-method/153968)

<div class="topic-metadata">

**Author:** [@nickh](https://www.ruby-forum.com/u/nickh)\
**Replies:** 7\
**Last updated:** [November 24, 2008, 5:11pm UTC](https://www.ruby-forum.com/t/how-to-spec-a-rails-helper-method/153968 "2008-11-24T17:11:05Z")

</div>

I’m trying to write specs for a helper method that I’m creating, but my specs are failing to find the helper method app/helpers/properties\_helper.rb module PropertiesHelper def format\_utilities(utilities) end end …

---

## [Features and conditions for those to be executed](https://www.ruby-forum.com/t/features-and-conditions-for-those-to-be-executed/153979)

<div class="topic-metadata">

**Author:** [@luislavena](https://www.ruby-forum.com/u/luislavena)\
**Replies:** 4\
**Last updated:** [November 24, 2008, 5:04pm UTC](https://www.ruby-forum.com/t/features-and-conditions-for-those-to-be-executed/153979 "2008-11-24T17:04:37Z")

</div>

Hello G.s, May this question be silly, so I’m exposing myself as a complete dumb :wink: I’ve been working on a project called rake-compiler, which enable the building of extension with C compilers in a standarized wa…

---

## [Rails: View specs and implicit parameters in link\_to()](https://www.ruby-forum.com/t/rails-view-specs-and-implicit-parameters-in-link-to/151059)

<div class="topic-metadata">

**Author:** [@mwalsh](https://www.ruby-forum.com/u/mwalsh)\
**Replies:** 3\
**Last updated:** [November 24, 2008, 5:01pm UTC](https://www.ruby-forum.com/t/rails-view-specs-and-implicit-parameters-in-link-to/151059 "2008-11-24T17:01:04Z")

</div>

Hi all, I’ve been cleaning up our routing file, and removed the default map.connect “:controller/:action” route. It’s thrown up a bunch of sloppy mistakes, which is great, but I also think I’ve found a problem with t…

---

## [Backtrace for passing specs via custom formatter](https://www.ruby-forum.com/t/backtrace-for-passing-specs-via-custom-formatter/153923)

<div class="topic-metadata">

**Author:** [@awarberg](https://www.ruby-forum.com/u/awarberg)\
**Replies:** 1\
**Last updated:** [November 24, 2008, 4:56pm UTC](https://www.ruby-forum.com/t/backtrace-for-passing-specs-via-custom-formatter/153923 "2008-11-24T16:56:20Z")

</div>

Hi, I’m using example.implementation\_backtrace in a custom formatter to get the path of the file a passing spec belongs to. Following rspec on github I saw that implementation\_backtrace is now deprecated and replaced…

---

## [Restful\_authentication's "permission\_denied" and rspec](https://www.ruby-forum.com/t/restful-authentications-permission-denied-and-rspec/153875)

<div class="topic-metadata">

**Author:** [@ramontayag](https://www.ruby-forum.com/u/ramontayag)\
**Replies:** 2\
**Last updated:** [November 24, 2008, 4:43pm UTC](https://www.ruby-forum.com/t/restful-authentications-permission-denied-and-rspec/153875 "2008-11-24T16:43:56Z")

</div>

Hi everyone, WIth restful\_authentication you get a method “permission\_denied” that you just slap onto the controller when you don’t want a user to gain access to something. In this method Rails does a bunch of stuff …

---

## [Backtrace for passing specs](https://www.ruby-forum.com/t/backtrace-for-passing-specs/154007)

<div class="topic-metadata">

**Author:** [@rubyphunk](https://www.ruby-forum.com/u/rubyphunk)\
**Replies:** 0\
**Last updated:** [November 24, 2008, 3:44pm UTC](https://www.ruby-forum.com/t/backtrace-for-passing-specs/154007 "2008-11-24T15:44:09Z")

</div>

Hi, I’m using example.implementation\_backtrace in a custom formatter to get the path of the file a passing spec belongs to. Following rspec on github I saw that implementation\_backtrace is now deprecated and replaced…

---

## [Cucumber, Webrat and http basic auth](https://www.ruby-forum.com/t/cucumber-webrat-and-http-basic-auth/153710)

<div class="topic-metadata">

**Author:** [@kwe](https://www.ruby-forum.com/u/kwe)\
**Replies:** 7\
**Last updated:** [November 23, 2008, 6:21pm UTC](https://www.ruby-forum.com/t/cucumber-webrat-and-http-basic-auth/153710 "2008-11-23T18:21:59Z")

</div>

Starting out with Cucumber and webrat and seem to be hitting a problem with a resource protected with http basic auth. i.e. The following feature… Feature: Manage Pages In order to add a reference pages As a admini…

---

## [Examples using cucumber, celerity, rspec](https://www.ruby-forum.com/t/examples-using-cucumber-celerity-rspec/153424)

<div class="topic-metadata">

**Author:** [@Alvin\_S](https://www.ruby-forum.com/u/Alvin_S)\
**Replies:** 2\
**Last updated:** [November 21, 2008, 1:28am UTC](https://www.ruby-forum.com/t/examples-using-cucumber-celerity-rspec/153424 "2008-11-21T01:28:19Z")

</div>

I created some simple examples using cucumber, celerity, and rspec to verify the behaviour of a web application. The examples include: verifying javascript ran on page load verifying results of AJAX calls responding…

---

## [LinkedIn Group](https://www.ruby-forum.com/t/linkedin-group/153291)

<div class="topic-metadata">

**Author:** [@Ashley\_M](https://www.ruby-forum.com/u/Ashley_M)\
**Replies:** 10\
**Last updated:** [November 20, 2008, 11:02pm UTC](https://www.ruby-forum.com/t/linkedin-group/153291 "2008-11-20T23:02:31Z")

</div>

Hi I was just thinking, would it be a good thing to have a LinkedIn group for RSpec? It’d be great to be able to find other RSpec users, either to help organise local Ruby events or to help when hiring people. Ashle…

---

## [RSpec, TestUnit, Cucumber and Autotest](https://www.ruby-forum.com/t/rspec-testunit-cucumber-and-autotest/153661)

<div class="topic-metadata">

**Author:** [@byrnejb](https://www.ruby-forum.com/u/byrnejb)\
**Replies:** 6\
**Last updated:** [November 20, 2008, 7:52pm UTC](https://www.ruby-forum.com/t/rspec-testunit-cucumber-and-autotest/153661 "2008-11-20T19:52:28Z")

</div>

OS=CentOS-5.2 Ruby=1.8.6 Rails=2.2.1\_RC Gems all up to date I have been experimenting with autotest and I have a few questions. given export AUTOFEATURES=TRUE if ./test exists (with tests) then these tests are ru…

---

## [Testing an action which requires picture](https://www.ruby-forum.com/t/testing-an-action-which-requires-picture/153106)

<div class="topic-metadata">

**Author:** [@manoah](https://www.ruby-forum.com/u/manoah)\
**Replies:** 12\
**Last updated:** [November 20, 2008, 7:09pm UTC](https://www.ruby-forum.com/t/testing-an-action-which-requires-picture/153106 "2008-11-20T19:09:02Z")

</div>

How can i test the action of a controller which requires picture? I mean, as part of the test I want to pass a picture (somekind of fixture) and test to see if the result is correct

---

## [Mocking and stubbing model relationships](https://www.ruby-forum.com/t/mocking-and-stubbing-model-relationships/153509)

<div class="topic-metadata">

**Author:** [@nickh](https://www.ruby-forum.com/u/nickh)\
**Replies:** 8\
**Last updated:** [November 20, 2008, 7:00pm UTC](https://www.ruby-forum.com/t/mocking-and-stubbing-model-relationships/153509 "2008-11-20T19:00:06Z")

</div>

Before writing specs for a one-to-many relationship between two models, I did some research and found that some people were creating proxy mocks, and others were using Matthew Heidemann’s #stub\_association! (which ess…

---

## [\[ANN\] Webrat Google group](https://www.ruby-forum.com/t/ann-webrat-google-group/153740)

<div class="topic-metadata">

**Author:** [@Ryan\_Briones](https://www.ruby-forum.com/u/Ryan_Briones)\
**Replies:** 0\
**Last updated:** [November 20, 2008, 6:04pm UTC](https://www.ruby-forum.com/t/ann-webrat-google-group/153740 "2008-11-20T18:04:36Z")

</div>

http://groups.google.com/group/webrat/ Been noticing a lot of webrat specific messages coming by the rspec-users mailing list, so I wanted people to be aware that there is also a Webrat Google group available for web…

---

## [Invitation to join RSpec Users](https://www.ruby-forum.com/t/invitation-to-join-rspec-users/153659)

<div class="topic-metadata">

**Author:** [@Ashley\_M](https://www.ruby-forum.com/u/Ashley_M)\
**Replies:** 0\
**Last updated:** [November 19, 2008, 9:50pm UTC](https://www.ruby-forum.com/t/invitation-to-join-rspec-users/153659 "2008-11-19T21:50:44Z")

</div>

Hi There wasn’t a lot of interest but I set up an RSpec Users group on LinkedIn\[1\] anyway. I did try to pre-approve everyone who has posted to this list since March, but LinkedIn’s CSV uploader appears to be borked,…

---

## [\`add\_scenario': wrong, number of arguments (1 for 2)](https://www.ruby-forum.com/t/add-scenario-wrong-number-of-arguments-1-for-2/153574)

<div class="topic-metadata">

**Author:** [@runxc](https://www.ruby-forum.com/u/runxc)\
**Replies:** 9\
**Last updated:** [November 19, 2008, 6:54pm UTC](https://www.ruby-forum.com/t/add-scenario-wrong-number-of-arguments-1-for-2/153574 "2008-11-19T18:54:26Z")

</div>

I am trying to get some old “rbehave” scripts working with cucumber. I am running into an error. I get the same error when I run the “calculator\_ruby\_features” example. Any suggestions? Bret C:\\work\\cucumber\\example…

---

## [Cucumber - how to spec a quick search box](https://www.ruby-forum.com/t/cucumber-how-to-spec-a-quick-search-box/153524)

<div class="topic-metadata">

**Author:** [@Mikel\_L](https://www.ruby-forum.com/u/Mikel_L)\
**Replies:** 5\
**Last updated:** [November 19, 2008, 3:56pm UTC](https://www.ruby-forum.com/t/cucumber-how-to-spec-a-quick-search-box/153524 "2008-11-19T15:56:50Z")

</div>

Hello all. Wondering if anyone else has solved this. Some websites (including the intranet app I am working on) have a form in the top corner of the site that is buttonless. If you focus on this form enter text and …

---

## [Testing on enter state](https://www.ruby-forum.com/t/testing-on-enter-state/153621)

<div class="topic-metadata">

**Author:** [@ramontayag](https://www.ruby-forum.com/u/ramontayag)\
**Replies:** 7\
**Last updated:** [November 19, 2008, 3:42pm UTC](https://www.ruby-forum.com/t/testing-on-enter-state/153621 "2008-11-19T15:42:44Z")

</div>

I was reading some old posts on how we shouldn’t test private methods, but there seemed to be an exception for states. When my model enters a state, a method is executed. (:on =\> Proc …) I just want to test this metho…

---

## [Extending the autotest discover rules](https://www.ruby-forum.com/t/extending-the-autotest-discover-rules/153589)

<div class="topic-metadata">

**Author:** [@mhfs](https://www.ruby-forum.com/u/mhfs)\
**Replies:** 3\
**Last updated:** [November 19, 2008, 4:57am UTC](https://www.ruby-forum.com/t/extending-the-autotest-discover-rules/153589 "2008-11-19T04:57:20Z")

</div>

Hello, We are creating tests for presenters (presenter pattern) classes. We are putting the implementation classes in app/presenters and we thought on putting the specs in spec/presenters. Question is, how could I ext…

---

## [Help: Attempts to run specs quitting midstream](https://www.ruby-forum.com/t/help-attempts-to-run-specs-quitting-midstream/152191)

<div class="topic-metadata">

**Author:** [@idahoev](https://www.ruby-forum.com/u/idahoev)\
**Replies:** 5\
**Last updated:** [November 19, 2008, 3:20am UTC](https://www.ruby-forum.com/t/help-attempts-to-run-specs-quitting-midstream/152191 "2008-11-19T03:20:47Z")

</div>

I am having a very frustrating problem running specs on my current project. When I run tests en masse with “rake spec” or with autotest, it frequently quits without completing all the tests. It also sometimes runs …

---

## [Autospec only runs specs in spec/models/ folder](https://www.ruby-forum.com/t/autospec-only-runs-specs-in-spec-models-folder/153564)

<div class="topic-metadata">

**Author:** [@wsimacek](https://www.ruby-forum.com/u/wsimacek)\
**Replies:** 2\
**Last updated:** [November 18, 2008, 10:54pm UTC](https://www.ruby-forum.com/t/autospec-only-runs-specs-in-spec-models-folder/153564 "2008-11-18T22:54:03Z")

</div>

Hi, Where do I change the mappings of the specs in my rails app. rspec/lib/autotest/rspec.rb? Given the latest versions in rspec, what is the bare minimum plugins/gems that I need to run autospec. I’ve been playing a…

---

## [Dealing with a retry inside of a rescue block](https://www.ruby-forum.com/t/dealing-with-a-retry-inside-of-a-rescue-block/153573)

<div class="topic-metadata">

**Author:** [@jgeiger](https://www.ruby-forum.com/u/jgeiger)\
**Replies:** 0\
**Last updated:** [November 18, 2008, 10:22pm UTC](https://www.ruby-forum.com/t/dealing-with-a-retry-inside-of-a-rescue-block/153573 "2008-11-18T22:22:48Z")

</div>

I’m trying to spec this method which is attempting to connect to beanstalkd message queue. I’m trying to figure out how to spec this so it catches the retry without actually retrying the block forever. Any help would …

---

## [Undefined method \`white\_list\_sanitizer'](https://www.ruby-forum.com/t/undefined-method-white-list-sanitizer/153555)

<div class="topic-metadata">

**Author:** [@Matt\_McNeil](https://www.ruby-forum.com/u/Matt_McNeil)\
**Replies:** 1\
**Last updated:** [November 18, 2008, 7:03pm UTC](https://www.ruby-forum.com/t/undefined-method-white-list-sanitizer/153555 "2008-11-18T19:03:53Z")

</div>

Hi there, After upgrading to the latest Rails RC (2.2.0) and rspec 1.1.11, I’m getting the following error in my specs (but not in the application itself): NoMethodError in ‘ApplicationHelper#truncate\_text truncates …

---

## [Cucumber autotest load error between 0.1.8 and 0.1.9](https://www.ruby-forum.com/t/cucumber-autotest-load-error-between-0-1-8-and-0-1-9/153506)

<div class="topic-metadata">

**Author:** [@harrylangdof](https://www.ruby-forum.com/u/harrylangdof)\
**Replies:** 2\
**Last updated:** [November 18, 2008, 4:38pm UTC](https://www.ruby-forum.com/t/cucumber-autotest-load-error-between-0-1-8-and-0-1-9/153506 "2008-11-18T16:38:07Z")

</div>

Hi, I’m new to the list and to Cucumber (and RSpec and testing in general) so I apologize if this has already come up. I searched the archive and didn’t see anything. Last week I installed Cucumber 0.1.8 for my Rails…

---

## [Spec'ing specific before\_filters in controllers](https://www.ruby-forum.com/t/specing-specific-before-filters-in-controllers/153516)

<div class="topic-metadata">

**Author:** [@codejoy](https://www.ruby-forum.com/u/codejoy)\
**Replies:** 0\
**Last updated:** [November 18, 2008, 9:44am UTC](https://www.ruby-forum.com/t/specing-specific-before-filters-in-controllers/153516 "2008-11-18T09:44:40Z")

</div>

rspec-users mailing list removed\_email\_address@domain.invalid http://rubyforge.org/mailman/listinfo/rspec-users

---

## [More Examples](https://www.ruby-forum.com/t/more-examples/153482)

<div class="topic-metadata">

**Author:** [@byrnejb](https://www.ruby-forum.com/u/byrnejb)\
**Replies:** 4\
**Last updated:** [November 18, 2008, 7:25am UTC](https://www.ruby-forum.com/t/more-examples/153482 "2008-11-18T07:25:47Z")

</div>

I have a feature spec that looks like this: Scenario: The entity common name should be normalized Given 1 valid entity And I am on the edit entity page When I fill in “Common Name” with " ANYThing WronG wITh tHiS?…

---

## [How to use config.gem for rspec and rspec-rails](https://www.ruby-forum.com/t/how-to-use-config-gem-for-rspec-and-rspec-rails/153493)

<div class="topic-metadata">

**Author:** [@hayafirst](https://www.ruby-forum.com/u/hayafirst)\
**Replies:** 0\
**Last updated:** [November 18, 2008, 12:27am UTC](https://www.ruby-forum.com/t/how-to-use-config-gem-for-rspec-and-rspec-rails/153493 "2008-11-18T00:27:53Z")

</div>

Hi, Is there anyway I can specify config.gem rspec :lib =\> “spec” config.gem rspec-rails :lib =\> “spec/rails” in my test.rb? Basically I got this after I specify rspec rake gems:unpack RAILS\_ENV=test (in /home/ywe…

---

## [Cucumber feature description](https://www.ruby-forum.com/t/cucumber-feature-description/151802)

<div class="topic-metadata">

**Author:** [@markthomas](https://www.ruby-forum.com/u/markthomas)\
**Replies:** 11\
**Last updated:** [November 17, 2008, 11:45pm UTC](https://www.ruby-forum.com/t/cucumber-feature-description/151802 "2008-11-17T23:45:08Z")

</div>

In the old Story Runner framework the feature description had a preamble that looked like As a… I want… So that… When I was moving to cucumber I seem to remember reading somewhere that that formulation was being ch…

---

## [Features and form filling - going declarative?](https://www.ruby-forum.com/t/features-and-form-filling-going-declarative/152761)

<div class="topic-metadata">

**Author:** [@diabolist](https://www.ruby-forum.com/u/diabolist)\
**Replies:** 13\
**Last updated:** [November 17, 2008, 11:04pm UTC](https://www.ruby-forum.com/t/features-and-form-filling-going-declarative/152761 "2008-11-17T23:04:43Z")

</div>

I’m working on writing features for a wizard. The wizard collects information from a number of different forms, and you can navigate through it in a number of ways. Anyhow one of these forms is a customer form collec…

---

## [Autotest style autotest/rails\_rspec doesn't seem to exist. Aborting](https://www.ruby-forum.com/t/autotest-style-autotest-rails-rspec-doesnt-seem-to-exist-aborting/153204)

<div class="topic-metadata">

**Author:** [@ramontayag](https://www.ruby-forum.com/u/ramontayag)\
**Replies:** 4\
**Last updated:** [November 17, 2008, 1:24am UTC](https://www.ruby-forum.com/t/autotest-style-autotest-rails-rspec-doesnt-seem-to-exist-aborting/153204 "2008-11-17T01:24:45Z")

</div>

Just upgraded rspec because I want to use cucumber. I downloaded the gems listed in the github wiki, and I submoduled the rspec and rspec-rails plugins. Autotest started to fail on me though. “Autotest style autotes…

---

## [Undefined method \`run?' for Test::Unit:Module](https://www.ruby-forum.com/t/undefined-method-run-for-test-module/153335)

<div class="topic-metadata">

**Author:** [@runxc](https://www.ruby-forum.com/u/runxc)\
**Replies:** 3\
**Last updated:** [November 17, 2008, 1:17am UTC](https://www.ruby-forum.com/t/undefined-method-run-for-test-module/153335 "2008-11-17T01:17:09Z")

</div>

Hello. I just ran into an error I wanted to share. The error message is below. I tracked down the error to the following conditions: I am using the new version of Watir (1.6.2) This version of Watir uses the “user-ch…

[Previous page](https://www.ruby-forum.com/c/testing/rspec/25.md?page=78)

[Next page](https://www.ruby-forum.com/c/testing/rspec/25.md?page=80)
