Re: [rspec-users] Rspec Style

2013-10-30 Thread Pat Maddox
Curtis, hey man, I saw your post in the rspec list archives (http://rubyforge.org/pipermail/rspec-users/2013-August/021811.html). I use context with pattern A: describe UsersController do describe "POST create" do it "creates a user" do ... end context "with bad data" do

Re: [rspec-users] [Rspec] How do you nest before(:all) or after(:all) blocks?

2013-10-24 Thread David Chelimsky
___ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] [Rspec] How do you nest before(:all) or after(:all) blocks?

2013-10-24 Thread Dhananjay V.
> http://rspec.lighthouseapp.com/projects/5645/tickets/632 something i wish i could get additional information from other users?? I could not see the status of the ticket as it was restricted..Any updates with regards to the use of the global variable objects in the same script call before test

Re: [rspec-users] [Rspec] How do you nest before(:all) or after(:all) blocks?

2013-10-24 Thread Dhananjay V.
David Chelimsky wrote in post #777566: > On Wed, Feb 4, 2009 at 3:07 AM, John Kolokotronis > wrote: >> describe "This is a set of tests: " do >>end >> >> - this should only appear once >> - test 1 >> - this should only appear once >> - test 2 >> >> So my question is, how can you add before

Re: [rspec-users] RSpec with devise test helpers

2013-10-22 Thread Zach Dennis
Can you provide a gist of your spec helper, controller spec, and controller implementation? On Wed, Oct 16, 2013 at 3:17 PM, Paul Ols wrote: > I've set my Rails (engine) project to include devise and other tools > like FactoryGirl. > I'd like to write some tests with contexts around anon/authen

[rspec-users] RSpec with devise test helpers

2013-10-16 Thread Paul Ols
I've set my Rails (engine) project to include devise and other tools like FactoryGirl. I'd like to write some tests with contexts around anon/authenticated users. In my spec_helper.rb's RSpec.configure block, I have this: config.include Devise::TestHelpers, type: :controller Which gives me this,

[rspec-users] Rspec Style

2013-08-29 Thread Curtis Schofield
My Question is about ordering of describes / context and the various styles that people are using that deviate from . Some context first: Started TDD when i was a university researcher - as a way to do bug fixes without regression. Started using rspec in 2006 on the side and eventually switched o

[rspec-users] RSpec can't define singleton error when trying to mock gets and puts for Hash Elements

2013-08-02 Thread Mohnish G j
I have a Book Model which is a ruby script that assigns prices to certain predefined Book titles mentioned in the program. Here's how the book model looks:- class Book attr_accessor :books def initialize books puts "Welcome to setting book price program" @books =

[rspec-users] RSPEC FAILURE

2013-06-25 Thread oliver
Hello I've got somthing like this error in my rspec. Can you help me to fix this: I appreciate all those replies. Failures: 1) EmployeeMstsController PUT update with valid params updates the requested e mployee_mst Failure/Error: put :update, :id => employee_mst.id, :employee_mst => {'thes

Re: [rspec-users] RSpec in controller

2013-06-10 Thread oliver
Problem solved!!! -- View this message in context: http://ruby.11.x6.nabble.com/RSpec-in-controller-tp4991621p4991676.html Sent from the rspec-users mailing list archive at Nabble.com. ___ rspec-users mailing list rspec-users@rubyforge.org http://rub

Re: [rspec-users] RSpec in controller

2013-06-10 Thread oliver
On my _form.html.erb, I have this: <%= f.select :group_name, options_for_select(@group_mst.collect{|x| [x.group_name]}), {:multiple => :multiple} %> - On my user_mst_controller.rb: def new @user_

Re: [rspec-users] rspec-users Digest, Vol 84, Issue 8

2013-06-10 Thread Oliver Jesus
Yes I've done that. I think it is on rendering on causes error.-On my _form.html.erb, I have this: <%= f.select :group_name, options_for_select(@group_mst.collect{|x| [x.group_name]}), {:multiple => :mul

Re: [rspec-users] RSpec in controller

2013-06-10 Thread Andy Lindeman
On Mon, Jun 10, 2013 at 1:46 AM, oliver wrote: > hello! when I've run bundle exec rspec spec --backtrace I've got something > like this error. What is the possible cause of this. Thank you for help in > advance! Hi Oliver-- Can you paste your controller, view, and spec on gist.github.com? -- An

[rspec-users] RSpec in controller

2013-06-09 Thread oliver
late.rb:135:in `block in render' # C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-3.0.9/lib/active_suppor t/notifications.rb:52:in `block in instrument' # C:/Ruby192/lib/ruby/gems/1.9.1/gems/activesupport-3.0.9/lib/active_suppor t/notifications/instrumenter.rb:21:in `instrument' #

Re: [rspec-users] rspec-users Digest, Vol 84, Issue 1

2013-06-09 Thread Oliver Jesus
- next part -- An HTML attachment was scrubbed... URL: <http://rubyforge.org/pipermail/rspec-users/attachments/20130530/3d4f29ef/attachment-0001.html> -- Message: 3 Date: Tue, 04 Jun 2013 13:01:48 +0200 From: Aashish Kiran To: rspec-users@rubyforge.o

Re: [rspec-users] RSpec 2, Rails 3, and SSL routes

2013-06-04 Thread Aashish Kiran
I too came across same situation (i.e., testing ssl request in rails with specs). Thinking there should be a solution. Thanks, Aashish -- Posted via http://www.ruby-forum.com/. ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.or

Re: [rspec-users] Rspec matchers confused by hashes?

2013-05-02 Thread Kwasi Mensah
ng with the original case that inspired this). > > > Vighnesh > > > ___ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] Rspec matchers confused by hashes?

2013-05-02 Thread Arne Brasseur
ails with one level of using [] but >> passes with two levels. >> >> I'm using the command: >> bundle exec rspec spec/requests/test_hash_bug_spec.rb >> >> I'm using the following rspec gems: >> rspec (2.11.0) >> rspec-core (2.11.1) >> rspec-expectations (2.11.3) >> rspec-mocks (2.11.3) >> rspec-rails (2.11.0) >> >> And I can provide my full gem list if needed. >> >> Kwasi >> > > > ___ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] Rspec matchers confused by hashes?

2013-05-02 Thread Vighnesh Rege
I was wrong. This also works: ``` it do @test_hash["foobar"].size.should be 3 end ``` Looks like the error was due to the missing dot between size and should. This test: ``` it do should be 3 end ``` gives the same error: ``` 1) HashBug Test fails Failure/Error:

Re: [rspec-users] Rspec matchers confused by hashes?

2013-05-02 Thread Vighnesh Rege
On Thu, May 2, 2013 at 3:01 PM, Kwasi Mensah wrote: >@test_hash["foobar"].size should be 1 > Shouldn't there be a dot between size and should? Also, shouldn't the expected value be 3? Even after making these changes: ``` @test_hash["foobar"].should be 3 ``` the test fails for a reason t

Re: [rspec-users] Rspec matchers confused by hashes?

2013-05-02 Thread Kwasi Mensah
sorry if this gets posted twice. I accidentally sent this before I was confirmed for the mailing list. On Thu, May 2, 2013 at 5:11 PM, Kwasi Mensah wrote: > I'm having trouble with one of my rspecs and it's coming down to the tests > being confused about what the subject is. Here's an example s

[rspec-users] Rspec + include Rails.application.routes.url_helpers

2013-03-27 Thread Ezequiel Delpero
Hello there, I'm having some issues trying to test a custom helper. And I been trying to figure this out without luck. Please, see attachs for more information. Thanks in advance. Attachments: http://www.ruby-forum.com/attachment/8268/errors.txt http://www.ruby-forum.com/attachment/8269/spec_help

Re: [rspec-users] Rspec + Devise + BaseController

2013-03-20 Thread David Chelimsky
On Wed, Mar 20, 2013 at 11:21 AM, Ezequiel Delpero wrote: > Finally I could solve the problem. The problem was on the definition of > the anonymous controller on the spec: > > instead of: > > controller do > def index > end > end > > I used: > > controller(Admins::Base) do

Re: [rspec-users] Rspec + Devise + BaseController

2013-03-20 Thread Ezequiel Delpero
Finally I could solve the problem. The problem was on the definition of the anonymous controller on the spec: instead of: controller do def index end end I used: controller(Admins::Base) do def index end end You need to specify always the anonymous cont

[rspec-users] Rspec + Devise + BaseController

2013-03-20 Thread Ezequiel Delpero
Hello there, I'm creating a base controller for the admin section of a project. All controllers whitin the admin section will inherit from it. # #app/controllers/admins/base_controller.rb class Admins::BaseController < ApplicationController l

[rspec-users] rspec output not displaying properly in Windows

2013-03-08 Thread Andrew Pennebaker
rspec's coloration displays incorrectly in Windows. Example: C:\>rspec ... ←[36m # ./lib/github_teams/authentication.rb:82:in `github_api'←[0m ←[36m # ./lib/github_teams/authentication.rb:87:in `github'←[0m ←[36m # ./lib/github_teams/team.rb:10:in `initialize'←[0m ←[36m # ./spec/li

Re: [rspec-users] RSpec newbie

2012-11-24 Thread Perry Smith
On Nov 24, 2012, at 3:00 AM, Andrew Premdas wrote: > The book is quite old now. It still has great value for understanding core > BDD principles, and for covering the range of things you can do with RSpec, > but if you use it as a guide to follow step by step without sufficient > background un

Re: [rspec-users] RSpec newbie

2012-11-24 Thread David Paschich
ils? Or would it be better (less > frustration, etc) if I plowed through the other chapters? > > Any other hints or suggestions would be welcomed as well. > > Thank you, > Perry Smith > > ___ >

Re: [rspec-users] RSpec newbie

2012-11-24 Thread Guirec Corbel
___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] RSpec newbie

2012-11-24 Thread Andrew Premdas
On 24 November 2012 03:24, Perry Smith wrote: > I've never really done BDD or TDD. I've done various tests but not really > allowing the tests to direct the development > > I've read various books and I bought the RSpec book and was reading it -- > up to chapter 4. > > Today while torquing with

[rspec-users] RSpec newbie

2012-11-23 Thread Perry Smith
I've never really done BDD or TDD. I've done various tests but not really allowing the tests to direct the development I've read various books and I bought the RSpec book and was reading it -- up to chapter 4. Today while torquing with a toy Rails project, a small change mushroomed into a maj

Re: [rspec-users] rspec failure upon revisit

2012-11-07 Thread Drew Davis
I found the issue was case sensitivity 'Sign up' vs. 'Sign Up' -- Posted via http://www.ruby-forum.com/. ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] rspec failure upon revisit

2012-11-06 Thread Lee Quarella
ed examples: > > rspec ./spec/requests/layout_links_spec.rb:25 # LayoutLinks should have > a signup page at '/signup' > > Is this something I can fix? Looks to be searching for a signup page > that doesn't exist (?). > > Please reply if you have a chance. Thanks, Andrew > > -- > Posted via http://www.ruby-forum.com/. > ___ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] .rspec ci reporter configuration file

2012-11-02 Thread Andy Lindeman
On Fri, Nov 2, 2012 at 6:07 AM, Adnan Behram wrote: > Is there a way to add date to report.html file name so that it looks > like for example: report_02_11_2012.html > > my current configuration looks like: > --out /somefolder/report.html I think you can probably use the shell. Something like: r

[rspec-users] .rspec ci reporter configuration file

2012-11-02 Thread Adnan Behram
Is there a way to add date to report.html file name so that it looks like for example: report_02_11_2012.html my current configuration looks like: --out /somefolder/report.html -- Posted via http://www.ruby-forum.com/. ___ rspec-users mailing list rspe

Re: [rspec-users] Rspec for thor script

2012-09-14 Thread David Chelimsky
On Fri, Sep 14, 2012 at 11:31 AM, ankush m. wrote: > Hello all, > I recently developed a CLI extending thor API. > While i was trying to write specs for thor's tasks, I couldn't find any > way to write the same for tasks with mandatory options or with options. > So can anyone please gui

[rspec-users] Rspec for thor script

2012-09-14 Thread ankush m.
Hello all, I recently developed a CLI extending thor API. While i was trying to write specs for thor's tasks, I couldn't find any way to write the same for tasks with mandatory options or with options. So can anyone please guide me for the same? -- Posted via http://www.ruby-forum.com/

Re: [rspec-users] RSpec Selenium Webdriver Html Report with Screenshots

2012-09-03 Thread David Tishkoff
Serguei Cambour wrote in post #1074435: > Just a piecec pf code to create a screen shot: > > private void takeScreenShot(RuntimeException e, String fileName) { > > File screenShot = ((TakesScreenshot) > driver).getScreenshotAs(OutputType.FILE); > > try { > > FileUtils.copyFile(scree

Re: [rspec-users] RSpec Selenium Webdriver Html Report with Screenshots

2012-09-03 Thread Javix
ed via http://www.ruby-forum.com/. > ___ > rspec-users mailing list > rspec...@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] RSpec Selenium Webdriver Html Report with Screenshots

2012-09-03 Thread Javix
to create html report with the screenshot generated on > failure? Would really appreciate your help! > > -- > Posted via http://www.ruby-forum.com/. > ___ > rspec-users mailing list > rspec...@rubyforge.org

[rspec-users] RSpec Selenium Webdriver Html Report with Screenshots

2012-09-01 Thread David Tishkoff
Hello, I'm using Rake + RSpec + Selenium-WebDriver for the web testing, Is there a way to create html report with the screenshot generated on failure? Would really appreciate your help! -- Posted via http://www.ruby-forum.com/. ___ rspec-users mailing

Re: [rspec-users] Rspec: How to mock class method

2012-07-26 Thread Bas Vodde
tiveRecord::Base >>> def method_user >>> if Message.method_a('anythings') >>> #... some code >>> end >>> end >>> end >>> ``` >>> I want to test method_user,but I don't want to test Message#method_a >>> How

Re: [rspec-users] Rspec: How to mock class method

2012-07-26 Thread Srushti Ambekallu
x27;t want to test Message#method_a >> How I can mock Message with method_a? >> >> Thanks! >> >> -- >> Posted via http://www.ruby-forum.com/. >> ___ >> rspec-users mailing list >> rspec-users@rubyforg

Re: [rspec-users] Rspec: How to mock class method

2012-07-26 Thread Bas Vodde
t method_user,but I don't want to test Message#method_a > How I can mock Message with method_a? > > Thanks! > > -- > Posted via http://www.ruby-forum.com/. > _______ > rspec-users mailing list > rspec-users@rubyforge.org > http:/

[rspec-users] Rspec: How to mock class method

2012-07-26 Thread bill gate
Hi, I have two model: Message, User message.rb ``` class Message < ActiveRecord::Base class << self def method_a(args) [1,2] end end end ``` user.rb ``` class User < ActiveRecord::Base def method_user if Message.method_a('anythings') #... some code end end end

Re: [rspec-users] rspec-rails does not have a matcher for assert_generates

2012-07-26 Thread David Chelimsky
esting. If you give me an example of how/when you'd use it I can try to explain. > i can of-course call 'assert_generates' from rspec > > -- > best, > deepak > > ___ > rspec-users ma

[rspec-users] rspec-rails does not have a matcher for assert_generates

2012-07-26 Thread deepak kannan
hi, rails minitest has assertions for assert_generates, assert_recognizes and assert_routing rpsec's "routes_to" delegates to assert_recognizes http://rubydoc.info/gems/rspec-rails/frames But there is no mention of assert_generates http://api.rubyonrails.org/classes/ActionDispatch/Assertions/Rou

Re: [rspec-users] RSpec/rails & Capybara: #within

2012-07-23 Thread Justin Ko
On Jul 22, 2012, at 3:08 PM, Salvatore Pelligra wrote: > I'm new with Capybara and after a good amount of google, I still can't > figure out how the #within methods works! > I can use it only if I call visit before? There's no way to use it on a > string, like the `page = Capybara.string(html_str

[rspec-users] RSpec/rails & Capybara: #within

2012-07-22 Thread Salvatore Pelligra
I'm new with Capybara and after a good amount of google, I still can't figure out how the #within methods works! I can use it only if I call visit before? There's no way to use it on a string, like the `page = Capybara.string(html_string)` trick? When describe a view, I want something like that: d

Re: [rspec-users] Rspec include paths

2012-06-08 Thread David Chelimsky
On Fri, Jun 8, 2012 at 4:03 PM, Michael Madrid wrote: > 'm using rspec 2.10 with Rails 3.2.1 and have problems with classes not > being found. > > I have put a class called DbTasks under a dir app/util. Under spec, i've > created file util/db_tasks_spec.rb which runs afer i included the line: > >

Re: [rspec-users] RSpec 2/Rails 3 - content_for in view specs

2012-06-08 Thread jared
__ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > >___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

[rspec-users] Rspec include paths

2012-06-08 Thread Michael Madrid
'm using rspec 2.10 with Rails 3.2.1 and have problems with classes not being found. I have put a class called DbTasks under a dir app/util. Under spec, i've created file util/db_tasks_spec.rb which runs afer i included the line: require File.join(File.dirname(FILE), '../../app/util/db_tasks') H

[rspec-users] RSpec controller methods testing

2012-05-31 Thread zombiebit
*I am testing my controller and I run coverage "rcov" to learn how much I covered the test. However I cannot test Ruby methods. For example, This is my controller,* class AuthenticationsController < ApplicationController def index @authentications = current_user.authentications if

Re: [rspec-users] RSpec testing update action with ajax

2012-05-30 Thread Justin Ko
_uuid).with("6").and_return(mock_widget(:update_attributes > => true)) Need to pass #save! as the stub > mock_widget.should_receive(:update_attributes).with({'these' => > 'params'}) > xhr :put, :update, :uuid => "6", :widget => {'these' => 'params'}, > :format => :js > response.should be_success >end > end > > end > > *Where is the stuck point? How should I solve it?* > > -- > View this message in context: > http://ruby.11.n6.nabble.com/RSpec-testing-update-action-with-ajax-tp4975810.html > Sent from the rspec-users mailing list archive at Nabble.com. > ___ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

[rspec-users] RSpec testing update action with ajax

2012-05-30 Thread zombiebit
Hey, I want to test my Rails app. When you click the image ajax sends to data to DB and the data is updated in there. When I try to test, I faced with this problem, 1) RwsController Update widget score takes widget rate information Failure/Error: mock_widget.should_receive(:update_attribut

Re: [rspec-users] RSpec fails testing on ActiveRecord

2012-05-29 Thread Todd Sedano
y-forum.com/. > ___ > rspec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users > ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] RSpec fails testing on ActiveRecord

2012-05-29 Thread Kashyap KMBC
t/7448/database.yml > http://www.ruby-forum.com/attachment/7449/Ruby_on_Rails__Welcome_aboard.html > > > -- > Posted via http://www.ruby-forum.com/. > ___ > rspec-users mailing

[rspec-users] RSpec fails testing on ActiveRecord

2012-05-29 Thread Frédéric Champreux
Hi, I'm new to RoR, and following the RoR 3.2 Tutorial from Michael Hartl. When it comes to execute testing (chap. 3.2.1), RSpec returns a hundred of errors starting with this one (and all looking the same more or less): /home/fred/.rvm/gems/ruby-1.9.3-p0@ODQ/gems/activerecord-3.2.1/lib/active_r

Re: [rspec-users] rspec-mocks and rspec-rails-2.10.1 are released!

2012-05-08 Thread Roger Pack
Thanks David. -- Posted via http://www.ruby-forum.com/. ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] rspec-2.10 is released!

2012-05-05 Thread Matt Wynne
Corrections to documentation links: On 4 May 2012, at 02:37, David Chelimsky wrote: > rspec-2.10 is released! > > Cucumber docs > > http://rubydoc.info/gems/rspec-core > http://rubydoc.info/gems/rspec-expectations > http://rubydoc.info/gems/rspec-mocks > http://rubydoc.info/gems/rspec-rails ht

[rspec-users] rspec-mocks and rspec-rails-2.10.1 are released!

2012-05-04 Thread David Chelimsky
These are patch releases recommended for anybody who has already upgraded to 2.10. ### rspec-mocks-2.10.1 full changelog: http://github.com/rspec/rspec-mocks/compare/v2.10.0...v2.10.1 Bug fixes * fix [regression of edge case behavior](https://github.com/rspec/rspec-mocks/issues/132) * fixed

Re: [rspec-users] rspec 2.10.0 breaks controller specs...

2012-05-04 Thread David Chelimsky
On Fri, May 4, 2012 at 3:07 PM, Patrick J. Collins wrote: > Apparently 2.10.0 doesn't like this line in devise's > lib/devise/test_helpers.rb >  @request.env['warden'] = Warden::Proxy.new(@request.env, manager) Please file bug reports to https://github.com/rspec/rspec-rails/issues, and please lo

[rspec-users] rspec 2.10.0 breaks controller specs...

2012-05-04 Thread Patrick J. Collins
Apparently 2.10.0 doesn't like this line in devise's lib/devise/test_helpers.rb @request.env['warden'] = Warden::Proxy.new(@request.env, manager) ... This worked fine in 2.8.1, but now all my controller specs give me: Failure/Error: Unable to find matching line from backtrace NoMethodErr

[rspec-users] rspec-2.10 is released!

2012-05-03 Thread David Chelimsky
rspec-2.10 is released! Cucumber docs http://rubydoc.info/gems/rspec-core http://rubydoc.info/gems/rspec-expectations http://rubydoc.info/gems/rspec-mocks http://rubydoc.info/gems/rspec-rails API Docs (RDoc) http://relishapp.com/gems/rspec-core http://relishapp.com/gems/rspec-expectations http:

Re: [rspec-users] rspec-users Digest, Vol 70, Issue 13

2012-04-18 Thread Nasir Jamal
David First issue temporarily sorted by using the 'include' for now until 2.10 comes out. Please ignore the second issue because while doing find and replace I did "full_path" instead of "fullpath". My bad, apologies for that. Kind regards, Nas Date: Wed, 18 Apr 2012 01:59:09 -0700 (PDT) Fr

Re: [rspec-users] RSpec exactly behavior (it doesn't exactly fail)

2012-04-15 Thread David Chelimsky
t; > > It would be nice if it would fail. Is there any reason for not failing > > > > already at this point in time? > > > > > > > > (I'm using RSpec 2.6-0. I quickly browsed the latest and didn't see > > > >

Re: [rspec-users] RSpec exactly behavior (it doesn't exactly fail)

2012-04-15 Thread Bas Vodde
ing RSpec 2.6-0. I quickly browsed the latest and didn't see this >>> changed) >>> >>> Thanks, >>> >>> Bas >> There is no philosophical reason for this to happen, and there are other >> types of failures that do fail-fast (e.g. ob

Re: [rspec-users] RSpec exactly behavior (it doesn't exactly fail)

2012-04-15 Thread David Chelimsky
Actually I just went ahead and fixed it sans-bug report: https://github.com/rspec/rspec-mocks/commit/fb9c76c2e40b4b25f4dcc5de95f8c60319b6d9c1. It'll be fixed in the next release (2.10). Cheers, David -- David Chelimsky Sent with Sparrow (http://www.sparrowmailapp.com/?sig) On Sunday, April

Re: [rspec-users] RSpec exactly behavior (it doesn't exactly fail)

2012-04-15 Thread David Chelimsky
On Sunday, April 15, 2012 at 1:32 AM, Bas Vodde wrote: > > Hiya all, > > I've got a quick question related to RSpec. I was test-driving some code and > ended up in an endless loop. I was surprised by this, but traced it down to > the mock not failing on additional calls but only in the end. Let

[rspec-users] RSpec exactly behavior (it doesn't exactly fail)

2012-04-14 Thread Bas Vodde
Hiya all, I've got a quick question related to RSpec. I was test-driving some code and ended up in an endless loop. I was surprised by this, but traced it down to the mock not failing on additional calls but only in the end. Let me explain. I was writing code like this: subject.wrapper.sho

Re: [rspec-users] Rspec with Nested Resources

2012-04-13 Thread Justin Ko
On Apr 12, 2012, at 11:32 AM, Arnaldo Junior wrote: > Hi, I have problems to implement the tests with RSpec with nested > routes in views, as I implement these tests? > Always gives error that it can not find the routes. > > #config/routes.rb > > resources :controller1 do >resources :contro

[rspec-users] Rspec with Nested Resources

2012-04-12 Thread Arnaldo Junior
Hi, I have problems to implement the tests with RSpec with nested routes in views, as I implement these tests? Always gives error that it can not find the routes. #config/routes.rb resources :controller1 do resources :controller2 end My test view #spec/views/controller2/index.html.erb_spec

[rspec-users] Rspec - gem_original_require': no such file to load -- rhom/rhom_db_adapter

2012-04-05 Thread Suresh Babu Madineni
Hello, Iam trying to use Rspec to test helper methods in my project. When i run the rspec command on my file, the following error note is displayed. C:/RhoStudio/ruby/lib/ruby/site_ruby/1.8/rubygems/custom_require.rb:36:in *`gem_original_require': no such file to load -- rhom/rhom_db_adapter (L

[rspec-users] rspec-expectations-2.9.1 is released!

2012-04-03 Thread David Chelimsky
rspec-expectations-2.9.1 is released! This is a bug-fix only release, and is recommended for everybody using rspec-2.9. ### rspec-expectations-2.9.1 / 2012-04-03 [full changelog](http://github.com/rspec/rspec-expectations/compare/v2.9.0...2.9.1) Bug fixes * Provide a helpful message if the di

Re: [rspec-users] [rspec-rails] Mailer tests should be similar to Controller tests

2012-03-29 Thread David Chelimsky
On Mon, Mar 26, 2012 at 7:20 PM, Paulo Luis Franchini Casaretto wrote: > Hey, > > When I'm testing a controller, I basically test three things. > Does it assign the variables the view needs? > Does it render the right template? > Does it do whatever the action is supposed to do? > And when testing

Re: [rspec-users] Rspec not loading fixtures

2012-03-26 Thread David Chelimsky
On Thu, Mar 22, 2012 at 9:54 AM, Pito Salas wrote: > I am taking over a code base and am trying to run the tests. I am > somewhat new to RSpec so this might be a trivial problem. > > Basically I can tell that the fixtures are not getting loaded. All 100 > tests fail with a similar error. > > But I

[rspec-users] [rspec-rails] Mailer tests should be similar to Controller tests

2012-03-26 Thread Paulo Luis Franchini Casaretto
Hey, When I'm testing a controller, I basically test three things. Does it assign the variables the view needs? Does it render the right template? Does it do whatever the action is supposed to do? And when testing mailers I feel it should be basically the same. Does it assign the variables the v

Re: [rspec-users] rspec-rails does execute any tests

2012-03-23 Thread David Chelimsky
On Fri, Mar 23, 2012 at 3:34 AM, Josh Moore wrote: > I  have inherited a rails 2.3.14 application with no tests. I have gotten > cucumber working but when I try to user rspec will not run any of the test > cases. These are the first four lines in myspec/spec_helper.rb. > > ENV["RAILS_ENV"] ||= 'te

[rspec-users] rspec-rails does execute any tests

2012-03-23 Thread Josh Moore
I have inherited a rails 2.3.14 application with no tests. I have gotten cucumber working but when I try to user rspec will not run any of the test cases. These are the first four lines in myspec/spec_helper.rb. ENV["RAILS_ENV"] ||= 'test' require File.expand_path(File.join(File.dirname(__FILE

[rspec-users] Rspec not loading fixtures

2012-03-22 Thread Pito Salas
I am taking over a code base and am trying to run the tests. I am somewhat new to RSpec so this might be a trivial problem. Basically I can tell that the fixtures are not getting loaded. All 100 tests fail with a similar error. But I don't know why. Below is the code, with my narrative with ***

Re: [rspec-users] rspec-2.9.0 is released!

2012-03-17 Thread Luke Melia
___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

[rspec-users] rspec-2.9.0 is released!

2012-03-17 Thread David Chelimsky
rspec-2.9.0 is released wtih lots of bug fixes and a few minor feature improvements as well. Enjoy! ### rspec-core-2.9.0 / 2012-03-17 [full changelog](http://github.com/rspec/rspec-core/compare/v2.8.0...v2.9.0) Enhancements * Support for "X minutes X seconds" spec run duration in formatter. (uz

Re: [rspec-users] RSpec & JRuby

2012-03-14 Thread Justin Ko
On Mar 14, 2012, at 1:15 AM, Srushti Ambekallu wrote: > We're working on a project with a bunch of padrino services running on JRuby > 1.6.5. Currently, the tests are written Test::Unit, but we want to move to > writing specs. We tried rspec but that seemed to fail, until we looked closer > an

[rspec-users] RSpec & JRuby

2012-03-14 Thread Srushti Ambekallu
We're working on a project with a bunch of padrino services running on JRuby 1.6.5. Currently, the tests are written Test::Unit, but we want to move to writing specs. We tried rspec but that seemed to fail, until we looked closer and found that JRuby 1.6.6 has fixed whatever the issue was. We a

Re: [rspec-users] rspec-2.9.0.rc1 is released!

2012-03-12 Thread David Chelimsky
There was an error in one of the gemspecs so I just released 2.9.0.rc2. No other changes since rc1. Cheers, David On Sun, Mar 11, 2012 at 9:10 PM, David Chelimsky wrote: > rspec-2.9.0.rc1 has been released, with numerous enhancements and bug fixes: > > ### rspec-core-2.9.0.rc1 / 2012-03-11 > [fu

[rspec-users] rspec-2.9.0.rc1 is released!

2012-03-11 Thread David Chelimsky
rspec-2.9.0.rc1 has been released, with numerous enhancements and bug fixes: ### rspec-core-2.9.0.rc1 / 2012-03-11 [full changelog](http://github.com/rspec/rspec-core/compare/v2.8.0...v2.9.0.rc1) Enhancements * Support for "X minutes X seconds" spec run duration in formatter. (uzzz) * Strip whit

[rspec-users] Rspec 2 expectations matching what is received, but failing

2012-02-17 Thread thoen
I noticed a couple of similar posts (such as http://groups.google.com/group/rspec/browse_thread/thread/81554bd8ad0b03a3/ed61a787c00dd601?lnk=gst&q=received+expected+is+the+same+as+got#ed61a787c00dd601), but they didn't seem to have the same situation I have. Also, I apologize in advance for postin

Re: [rspec-users] RSpec spec works on rails 3.2.0, fails on 3.2.0

2012-02-14 Thread David Chelimsky
On Tue, Feb 14, 2012 at 1:14 PM, Jason Floyd wrote: > I have a spec that passes in rails 3.2.0, but fails in 3.2.1, and I have > no idea why. > > Here's the spec: > > it "can be shown on the company menu" do >  doclib = Factory(:document_library, title: 'Test', menu: false, > company: true) >  doc

[rspec-users] RSpec spec works on rails 3.2.0, fails on 3.2.0

2012-02-14 Thread Jason Floyd
I have a spec that passes in rails 3.2.0, but fails in 3.2.1, and I have no idea why. Here's the spec: it "can be shown on the company menu" do doclib = Factory(:document_library, title: 'Test', menu: false, company: true) doclib.should be_valid end Here's the error message I get when runnin

[rspec-users] Rspec testing (gunfight at coral)

2012-02-10 Thread Paul Fashanu
Can any one give me an explanation on whats going on in this exercise. And any advice on how i should go about it. I dont need any exact codes just yet. But at least a good idea on how to start will be good Thanks Exercise 2: Gunfight at the OK Corral Description Overview This exercise is

Re: [rspec-users] RSpec Requestable Examples

2012-01-30 Thread Zach Dennis
I forgot to answer your question more directly. I see things in the requestable/selectable approach which I would like to continue to explore and see if it pans out. So far I like the requestable/selectable approach for the reasons I mentioned in the other email. In short term practical use there

Re: [rspec-users] RSpec Requestable Examples

2012-01-30 Thread Zach Dennis
On Sun, Jan 29, 2012 at 3:04 PM, Lenny Marks wrote: > > On Jan 27, 2012, at 9:56 PM, Zach Dennis wrote: > >> I would be interested to hear any thoughts from the community about >> the ability to request specific examples from a shared example group >> as expressed in the rspec-requestable-examples

Re: [rspec-users] RSpec Requestable Examples

2012-01-29 Thread Lenny Marks
spec-users mailing list > rspec-users@rubyforge.org > http://rubyforge.org/mailman/listinfo/rspec-users ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] RSpec Requestable Examples

2012-01-28 Thread Zach Dennis
On Sat, Jan 28, 2012 at 5:56 PM, David Chelimsky wrote: > On Fri, Jan 27, 2012 at 8:56 PM, Zach Dennis wrote: >> I would be interested to hear any thoughts from the community about >> the ability to request specific examples from a shared example group >> as expressed in the rspec-requestable-exa

Re: [rspec-users] RSpec Requestable Examples

2012-01-28 Thread David Chelimsky
2/01/27/rspec-requestable-examples > > Git repository: https://github.com/mhs/rspec-requestable-examples > > -- > Zach Dennis > http://www.continuousthinking.com > http://www.mutuallyhuman.com > @zachdennis (twitter) > ___ > rspec-user

[rspec-users] RSpec Requestable Examples

2012-01-27 Thread Zach Dennis
I would be interested to hear any thoughts from the community about the ability to request specific examples from a shared example group as expressed in the rspec-requestable-examples gem. Here's the post that introduces them: http://mutuallyhuman.com/blog/2012/01/27/rspec-requestable-examples Gi

Re: [rspec-users] rspec output on windows

2012-01-16 Thread Thomas Krebs
thanks - that worked! -- Posted via http://www.ruby-forum.com/. ___ rspec-users mailing list rspec-users@rubyforge.org http://rubyforge.org/mailman/listinfo/rspec-users

Re: [rspec-users] rspec output on windows

2012-01-16 Thread Luis Lavena
On Mon, Jan 16, 2012 at 5:41 PM, Thomas Krebs wrote: > I have rails 3.1.3 and rspec 2.8.0 on windows 7 (32bit) installed. > When running rspec I receive the following output: > > ←[32m.←[0m←[32m.←[0m > > Finished in 0.33 seconds > ←[32m2 examples, 0 failures←[0m > > I have no glue how to get rid o

[rspec-users] rspec output on windows

2012-01-16 Thread Thomas Krebs
I have rails 3.1.3 and rspec 2.8.0 on windows 7 (32bit) installed. When running rspec I receive the following output: ←[32m.←[0m←[32m.←[0m Finished in 0.33 seconds ←[32m2 examples, 0 failures←[0m I have no glue how to get rid of the "special characters". Since I am new to rails I appreciate any

Re: [rspec-users] rspec and requests, and folders conventions

2012-01-16 Thread David Chelimsky
On Jan 16, 2012, at 9:16 AM, S Ahmed wrote: > I'm trying to run rspec requests, using jruby, and I set the defaults in a > env.rb file, but it doesn't seem to be loaded when I run the specs. > > My folder setup is: > > /spec/requests/ > /spec/requests/section/section_spec.rb > /spec/support/env

  1   2   3   4   5   6   7   8   9   10   >