similar to: Speed Up RSpec Tests

Displaying 20 results from an estimated 20000 matches similar to: "Speed Up RSpec Tests"

2013 Nov 22
2
Cancan Rspec load_and_authorize_resource
Hello! While running bundle exec rake, I receive following error (see in attached file) However, my tests are steel passing with command rspec spec/controllers/ Some info: ads_controller.rb: class AdsController < ApplicationController load_and_authorize_resource except: :create end ads_controller_spec.rb: require ''spec_helper'' describe AdsController do render_views
2013 Jun 19
0
Running RSpec tests, how can I resolve a “Curl::Err::OutOfMemoryError”?
Running an rspec test with ruby bindings for libcurl (with curb<https://github.com/taf2/curb>) like so: it "Should return a certain user in a JSON array" do $var = Curl::Easy.new("some-url.com") $var.perform response = JSON.parse($var.body_str) response[''user''].should eq(''some user name'') end and sometimes I get this error:
2013 Jun 18
1
Getting rspec error: Net::SMTPServerBusy: Relay access denied
I''m trying to test registration emails (sent with devise), and I keep getting the error: Net::SMTPServerBusy: 454 4.7.1 <model_spec-hcDgGtZH8xNBDgjK7y7TUQ@public.gmane.org>: Relay access denied I''m running Rails 3.2.11 with Capybara, and I have (temporarily) chopped my spec_helper.rb and test.rb files down to the bare minimum, still getting the error above.
2011 Nov 12
1
Using require_relative to speed up rspec require time.
Hi, I noticed recently that require ''rspec'' on my machine was taking close to half a second. That''s not a huge amount of time, but it is still the single slowest part of my test suite. It boils down to Ruby 1.9''s rather slow require. I''m using 1.9.3, but I''d still like to shave off some of the require time. As an experiment, I went into
2013 Mar 16
3
Do you ALWAYS use "bundle exec rspec spec" tests?
I''m going through Michael Hartl''s Rails tutorial, and I am happy to report that (as of the end of section 7) I''m able to get things working. (That said, I skipped the section on automated testing, as Hartl warned that automated testing is the most likely part of his book to become outdated.) There is a heavy emphasis on the "bundle exec rspec spec" tests.
2012 Aug 04
4
Rspec
Hi all i''m trying to learn Rspec testing can anyone suggest me the best book to learn Rspec with good sample code. Thanks in advance -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To post to this group, send email to rubyonrails-talk-/JYPxA39Uh5TLH3MbocFF+G/Ez6ZCGd0@public.gmane.org To unsubscribe from this group,
2013 Mar 28
0
Can not determine issue in my factories with factory girl in rspec
Hi Folks, I hope you''re doing good. Sorry for a long email. I am just trying my best to learn something new and, need your help to understand/ sort a small issue which I am not able to figure out. I have create couple of factories and created some examples for rspec for one of my projects. I have got everything working on my local. Even, my specs are green on local for both ruby
2013 Oct 08
1
Trouble with rspec and FactoryGirl Sequence
I''m following Michael Hartl''s Ruby on Rails 3 Tutorial but I''m using Rails 3.2.8 and FactoryGirl 4.2.0 and rspec 2.14.1 I''m in chapter 10 trying to generate tests for pagination (using will_paginate 3.2.5 which works fine in dev) I can get FactoryGirl to test just fine if I don''t use Sequence but I can''t seem to figure out the correct syntax
2013 Mar 02
0
Problems getting rspec testing working in OSX?
Hey Gang, Running into a weird error when trying to follow puppetlabs'' blog: https://puppetlabs.com/blog/the-next-generation-of-puppet-module-testing/ I''m running 10.8.2, using default ruby, in an attempt to make my home env a little more sane, (ran into weird rbenv issues at work, which I won''t go into here) The google tells me not a whole lot. Appreciate any help
2013 Aug 30
3
rspec-puppet not working
I''m trying to get rspec-puppet working and have run into a problem. I have a VM running ubuntu lucid, have installed rubygems 1.3.5 from the apt package and have install rspec-puppet (and other required gems), and rake, using gem install. I''ve run rspec-puppet-init in the module I want to test, and have created a very basic spec file for one of the classes in my module.
2012 Dec 20
0
Testing Torquebox scheduled jobs with rspec
Hi everyone, I am using Rspec for testing in a Ruby on Rails application for a client. We are using Torquebox and he asked me to created a Torquebox scheduled job [1], but I can''t find any information on how to write tests for it. Can anyone help me? Best regards, Daniel Sousa 1: http://torquebox.org/documentation/current/scheduled-jobs.html -- You received this message because you
2013 Feb 28
0
StackOverflow Question: Need help with my Rspec Request Spec!
Hi all, Any help would be much appreciated. Please see question posted on SO: http://stackoverflow.com/questions/15137336/devise-authentication-not-working-in-test-environment-with-rspec-request-spec-an -- You received this message because you are subscribed to the Google Groups "Ruby on Rails: Talk" group. To unsubscribe from this group and stop receiving emails from it, send an
2012 Sep 15
2
[RSpec Testing] Methods take two arguments
Hello, Here is my *pdf_helper.rb* => http://pastebin.com/QU1kTKXk. I want to test, if self.create method can take more than two arguments. But, when I try to run my test. It showed *PdfHelper Should have two arguments Failure/Error: create_pdf.should_receive(object,template).with(user,file) NameError: undefined local variable or method `create_pdf'' for
2012 Nov 12
7
RSpec: controller POST create
Rails 3.1.3 rspec-rails (2.11.4) rspec 2.11.1 I am new to rspec. I don''t quite understand tests for POST create part. I have generated scaffold, and simultaneously it generated controller_spec.rb as well. it "assigns a newly created plan as @plan" do post :create, {:plan => valid_attributes}, valid_session assigns(:plan).should be_a(Plan)
2013 Jan 09
2
Rails 3.2.10 and Rspec Tests that Fail?
The following tests used to reside in requests directory and used to work ... since I have upgraded to rails 3.2.9 and now 3.2.10 they fail. I have the following tests in(I am only showing the first two tests): spec/features/authentication_pages_spec.rb require ''spec_helper'' describe "Authentication" do subject { page }
2013 May 02
1
trouble-with-capybara-and-rspec-on-a-new-model-spec
I have searched a lot for a solution, but I could not find it! I am trying to make a rails application after watching Michael Hartl''s tutorial and when i fill data manually and submit it nothing happens and nothing records in the Mailers table and I am facing the following error: Failures: 1) Mailer pages mail us with valid information should send a mail Failure/Error: expect
2013 Jun 27
5
Is it possible to pass extra flags to Puppet via rspec?`
Hello, I''m writing my first puppet function rspec test and am having a problem which I don''t see how to solve. The function (and the test) involve access to files through the File Server. In order for the function (and the test) to work I need to pass "--fileserverconf=fileserver.conf" parameter to Puppet. So far I haven''t found a way to do that. If I
2013 Oct 10
0
RSpec-testing an entire puppet master
Has anyone ever written rspec-puppet-based code to check an entire site, i.e. looping over all node names - with proper facts - to verify that the catalog for each node is OK? I haven''t seen any examples of this. /P -- You received this message because you are subscribed to the Google Groups "Puppet Users" group. To unsubscribe from this group and stop receiving emails from
2013 Aug 15
0
Rspec, Puppet Custom Functions and Mocking..
Hey, I could use some advice here. We''ve had a puppet module out for a while (https://github.com/Nextdoor/puppet_thycotic) that provides us a way to retrieve private keys, passwords, etc from Thycotic''s SecretServerOnline.com service. This module was written in a hurry almost 2 years ago and has never had any real attention paid to it internally until now. We''re
2012 Nov 18
3
remarkable activerecord association RSpec
i''m using gem Remarkable activerecord for association. i''ve installed remarkable and remarkable activerecrod both gem. i''ve added both gem in my Gemfile. i''ve added "remarkable_activerecord" as required in spec_helper.rb. describe Authentication do FactoryGirl.build(:authentication).should belong_to(:user)