similar to: View spec failures without stack traces?!?

Displaying 20 results from an estimated 8000 matches similar to: "View spec failures without stack traces?!?"

2008 Jun 06
2
Problems with view spec and mocking will_paginate
Hi all, I have some failures that not I don''t understand this the pastie with index.erb.html http://pastie.org/private/zgohh6dcts04wpfagfgz5q and this is the pastie for view''s spec: http://pastie.org/210485 and the failure: 1) ActionView::TemplateError in ''/posts/index.html.erb should render list of posts'' undefined method `count'' for
2008 Jun 04
8
Not running correct specs under autotest:
I know this isn''t autotest-users but I''m not sure where else to bring this up: [["app/controllers/contents_controller.rb", Wed Jun 04 14:11:03 +0100 2008]] [["app/controllers/contents_controller.rb", Wed Jun 04 14:11:03 +0100 2008]] /System/Library/Frameworks/Ruby.framework/Versions/1.8/usr/bin/ruby -S script/spec -O spec/spec.opts spec/models/user_spec.rb
2007 Nov 06
2
Why is this view spec failing?
I can''t figure out why I am getting a failure. It renders out fine in the browser. <h1>New member</h1> <%= error_messages_for :member %> <% form_for(:member, :url => members_path) do |f| %> <fieldset> <legend>Member Info</legend> <p><label for="member[first_name]">First Name:</label> <%=
2007 Jul 06
3
stubbing helper methods for View specs
Hi there I have several view specs, that include the following snippet in their "before" block to stub the methods by acts_as_authenticated before :each do @u = mock_model(User) @u.should_receive(:name).and_return("Hans Muster") template.should_receive(:logged_in?).and_return(true) template.should_receive(:current_user).and_return(@u) end this
2007 May 17
4
How to mock helpers in view specs ?
Hi all, I am mocking the following Rails view (inside a partial): <%= render :partial => "forums/forum", :collection => forum_category.forums.readable_by(current_user? ? current_user : nil) %> My spec fails with the following message: 1) ActionView::TemplateError in ''forum_categories/index (anonymous user) should only render forums accessible to anonymous
2008 Jun 04
6
any_instance
Hi folks. I''m very interested in the status of a port of any_instance from Mocha to RSpec. In particular I have a spec suite that I wrote using RSpec but with Mocha that depends heavily on any_instance. This is because it stubs out one or two methods from an underlying API. In attempting to convert the suite to RSpec mocks (because that''s what we''re using for the rest
2007 Apr 05
5
Odd error handling in ActionView#compile_template causes WSOD
If a view file cannot be compiled (eg it has a block with a missing ''end'' statement), I''m experiencing WSODs - the browser reports a lost network connection, rather than the helpful compilation error that we used to have. When the compilation fails, ActionView#compile_template raises this error : TemplateError.new(find_base_path_for(file_name || template), file_name ||
2007 Oct 06
4
spec''ing views, mock_model associations
I writing a spec that returns the count of how many players in a game: it "should how many players in a link to all players" do render :partial =>"games/game", :object => @game response.should have_tag(''a'',"(2) Players") end I''m not sure how to do the mock model, I think it would be done two ways but unsure of the syntax: 1: add
2007 Oct 01
0
View Spec - Misbehaving
I''m trying to write my first view spec; I''ve done some controller specs with integrated views, but thought that isolating the views for some of these tests might be nice. So I wrote this: > describe PlayerContainer, "show" do > > PARENT_ID = 12 > CHILD_NAME = ''Child Name'' > PARENT_NAME = ''Parent Name'' > >
2006 Jan 16
1
Problem with production on Dreamhost - TemplateError
Hi all, I''m trying to deploy my app to Dreamhost for production. I''ve managed to solve all of the Error 500s and it''s *almost* working. When I try and view a page, I get a TemplateError that I don''t get when I''m running from home using InstantRails under Windows. The error is: ActionView::TemplateError (undefined method `user?'' for
2008 May 20
4
mock_model not stubbing model attribtues in view spec
Hi -- I am just getting to grips w/ view specs, and am having an issue with mock_model not stubbing the mocked model''s attributes. For instance, I have the following: <CODE> before do @input_timesheet = mock_model( InputTimesheet ) assigns[:input_timesheet] = @input_timesheet end it "should display a table element" do render
2007 Aug 30
1
alias_method_chain stack level too deep in Rake test only
I have an odd error. I have the following module: module ActionController module SslSupport def self.included(base) raise "#{base} does not define url_for" unless base.method_defined?(:url_for) unless base.respond_to?(:url_for_without_ssl_supprt) base.send :include, InstanceMethods base.send :alias_method_chain, :url_for, :ssl_support end
2007 Sep 10
6
RSpec view spec writing problem (unable to generate url_for in RESTful resource link_to)
Thanks, first, to everyone who''s asked and answered questions on this list, and to the creators of RSpec - it is all very helpful. I''ve searched the mailing list, and had a couple 2hr googling sessions that didn''t help me find an answer. I''ve run into a problem getting my first non-trivial view spec to run. I get an error when trying to generate a link_to()
2008 Mar 15
3
problem with config file
Hey there all if i have this in my gmap_api_key.yml file, production: ABQIAAAASPzYuwhUCPD9Vz98LPOPDhQXfahRKLczKzlJSy9lXc0oaHHYcxTFTjWleXY7LH-N3IAp9ruoqiU43w everything works fine but if i have this ..... production: texaspivot.com: ABQIAAAASPzYuwhUCPD9Vz98LPOPDhQXfahRKLczKzlJSy9lXc0oaHHYcxTFTjWleXY7LH-N3IAp9ruoqiU43w i get this ActionView::TemplateError (texaspivot.com) on line #1 of
2007 Nov 10
2
Problem with view spec - works inside the browser but spec fails with nil object
Hi, I''ve been trying to find an answer for this problem in the last couple hours, but I think no discussion was about this exact same thing. So here it goes, hope someone can help. I''m trying to spec a view which works correctly on the browser, but that generates the following error when I run "rake spec:views". ActionView::TemplateError in ''/survey/show
2006 Apr 06
10
Advice needed on tracking down unusual error
Does anyone have advice on how to go about locating the cause of this error message: ActionView::TemplateError (wrong number of arguments (3 for 1)) on line #4 of app/views/products/search.rhtml: 4: <%= start_form_tag :action => ''search'' %> I don''t see anything wrong with line 4 above. Some background: I''ve made a number of changes to Controllers,
2006 Nov 28
8
view specs with partials
When I first learned about the View specs I was very excited. I still am. However, I haven''t found them useful yet for one reason. They throw the following exception when ever a view renders another view, which is very common. ActionView::TemplateError in ''Event View message'' No rhtml, rxml, rjs or delegate template found for spec/rails/ view_spec/_info
2006 Jul 26
4
MasterView rails-optimize (x)html friendly template engine - Release 0.2.4
MasterView is a rails-optimized (x)html friendly template engine plugin that provides another option to the existing rails view templates (rhtml and rxml). The main idea is to provide a template engine that would provide all the power of layouts, partials, and rails helpers but still be editable/styleable in a WYSIWYG editor. It was also a major goal that the syntax of these attribute directives
2005 Nov 15
2
FormOptionsHelper select call failing
In Rails 0.14.3, I''m doing the following in a view: <%= select ''folder'', ''format'', [''a'', ''b'', ''c''] %> This line in is failing with: ActionView::TemplateError (too few arguments.) Am I calling select incorrectly? (Yes, the @folder object does exist, and does have an attribute
2006 Nov 07
3
include Helper in context?
Brandon, can you get your Helpers to work in rspec 0.7 ? I''m including them in the context but the render fails to see it. If you have it working, I''ll go back and bang my head against it some more, otherwise I''ll file a bug! Many thanks, Jerry context "account/login (view)" do include StandardHelpers specify ''displays title