Displaying 20 results from an estimated 300 matches similar to: "Do fixture_scenarios and RSpec peacibly coexist?"
2007 Sep 27
0
fixture_scenarios in trunk
Hi,
I saw a previous post from David answering someones question about
fixture_scenarios with rspec. Following that I upgraded my rspec and
rspec_on_rails to the trunk versions and then installed the fixture
scenario plugin.
Now whenever I run my (previously passing rspecs) I get the following
error for all tests...
...
148)
NoMethodError in ''Cart should show a
2005 Nov 26
4
activerecord rake test_mysql
Hi (I''m resubmitting this because
First question: This is the rails dev list, correct?
I''d like to submit a patch and am following the steps on this page:
http://dev.rubyonrails.org/
Here''s what I did (using mysql 5.0.15-nt):
created 2 databases:
activerecord_unittest
activerecord_unittest2
created 1 user: rails (giving all priveleges to both databases)
ran
2011 Jul 25
4
Rails 3 test database issues
I am having a problem using the test database in Rails 3. It
apparently has kept track of aspects of the database that I deleted
completely from my migrations at some point. I don''t always use the
''down'' part of a migration and sometimes just recreate the whole
database. I did rake db:migrate:reset and rake db:test:prepare, but
when I run my test it is trying to access
2006 Jul 24
3
Creating performance test fixtures from development db? How?
Hi all!
I''m looking into the testing chapter of Agile Web Development With Rails
(2nd ed.).
I want to performance test my app, but I''m too lazy to write fixtures for
performance test.
I''d rather use the data from my development db (because the data is so close
to the production data).
How do I get the data into the test db without writing fixtures?
Could you please
2006 Jun 24
5
Rake vs Ruby for running tests (error discrepency)
I''m having (to me) a strange problem with errors when running my tests
with rake as opposed to using ruby. If I do rake test:units I get this
error for several tests, but not all:
13) Error:
test_player_has_game_statistics_for_season(PlayerSeasonTest):
ActiveRecord::StatementInvalid: Mysql::Error: Duplicate entry ''22'' for
key 1: INSERT INTO positions (`name`, `id`,
2007 Jul 22
18
db:fixtures:load order
I was trying to deal with foreign key issues related to order of
fixture loading when I came across this:
http://techpolesen.blogspot.com/2007/04/rails-fixture-tips.html
This got me looking deeper into rails and I noticed that
db:fixtures:load calls Fixtures.create_fixtures once for each fixture
file. However, Fixtures.create_fixtures is capable of taking multiple
files and also handle the
2006 Apr 13
1
Setting up Testing model, getting an error
I setup a testing model in my Depot web app from the Agile Web
Development with Rails book and came up with the following errors:
Loaded suite test/unit/product_test
Started
EE
Finished in 0.050279 seconds.
1) Error:
test_create(ProductTest):
Errno::ENOENT: No such file or directory -
/Users/Mike/Sites/depot/config/../test/fixtures/categories
2005 Dec 12
2
Using a lib in YAML fixtures
I''m using the runt library [1] to do some temporal expression
matching. I want to keep the expression in a binary field in my db.
I figured that then in order to do the fixtures, I''d need to do some
erb in the yaml file. So I came up with this:
onetime:
id: 1
name: One Time
description: This event occurs only one time.
timex: <%= REYear.new(7) & REMonth.new(24)
2007 Jun 15
3
Error when running functional test - Errno::ENOENT
Hello,
I''m getting an error when running functional tests as follows, using
Mac OSX 10.4.9, Rails 1.2.3 .
When I run:
ruby test/functional/campaign_controller_test.rb
I get this error:
Started
E
Finished in 0.027402 seconds.
1) Error:
test_should_get_icon_data(CampaignControllerTest):
Errno::ENOENT: No such file or directory - /usr/src/projects/myproject/
2008 Jan 16
0
[CruiseControl] RubyOnRails build 8649 failed
The build failed.
CHANGES
-------
Revision 8649 committed by gbuesing on 2008-01-16 20:07:10
Introducing DateTime #utc, #utc? and #utc_offset, for duck-typing compatibility with Time. Closes #10002
M /trunk/activesupport/CHANGELOG
M /trunk/activesupport/lib/active_support/core_ext/date_time/calculations.rb
M /trunk/activesupport/test/core_ext/date_time_ext_test.rb
TEST FAILURES AND
2006 Jan 18
15
Anyone got Globalize working???
Hi all
In another thread I complain about an error I get after trying to get
Globalize working.
http://www.ruby-forum.com/topic/51988#new
Now I want to ask you, if anybody of you has ever got Globalize working?
I have done exactly what''s written in the (absolutely much too short)
tutorial of its wiki...
http://globalize.diluvia.net/wiki
...and I''m very frustrated that no
2006 Jul 18
1
Fixtures Max Size? SystemStackError: stack level too deep
Hello,
I have a table of zipcodes that I am using in my application, so there
are approximately 50,000 rows in this table. I have dumped the table to
a fixture yaml file to represent this data, but when I try to load it, I
get this error: SystemStackError: stack level too deep
Is there a max size allowed for a fixture file..?
Here is the --trace output:
rake db:fixtures:load --trace
**
2005 Mar 09
9
Unit testing + instance variables
After *much* digging and playing around, I finally figured out how to
unit test instance variables that are created by actions. It was
more difficult than I expected. It seems like there should have been
a more straight forward way to do this. Can someone enlighten me? A
simplified and somewhat contrived example of what I am current doing:
Thanks.
Matt
>>
# My Controller of interest
2006 Jan 06
4
Design flaw with Fixtures?
I''ve been trying to add unit testing for collection of models with
complex relationships -- and failing miserably.
Because of the complexity of the relationships, I''m using a database
which validates foreign key constraints (PostgreSQL 8).
I''m finding it nearly impossible to generate tests that are independent
of each other. The basic problem is the DELETE then
2005 Dec 23
2
SQLite in-memory
I left ":memory:" in database.yml for testing and the most simple
tests in the Agile book do not work (see trace below for test_truth).
Since that''s what comes with the distributed database.yml I suppose
it''s me doing something wrong.
Did someone get SQLite ":memory:" working? How does it grab the schema?
-- fxn
% rake test_units
(in
2006 Nov 24
7
Anyone know whats going on with PostgreSQL async_exec errors?
-----BEGIN PGP SIGNED MESSAGE-----
Hash: SHA1
Anyone know what''s going on with ActiveRecord Edge and 1.2RC1 unit
tests. I get 13 failures from the "async_exec" method call. ie:
test_callback_rollback_in_save(ConcurrentTransactionTest):
ActiveRecord::StatementInvalid: NoMethodError: undefined method
`async_exec'' for #<PGconn:0xb75a8754>: SET
2007 Feb 13
16
Error against latest trunk while testing via spec for model
Hi
I just did an update to lates trunk
=================
context "Given a generated venue_spec.rb with fixtures loaded" do
fixtures :venues
specify "fixtures should load two Venues" do
Venue.should have(2).records
end
end
==================
gives me
==========
1)
TypeError in ''Given a generated venue_spec.rb with fixtures loaded
fixtures should load two
2011 Aug 10
1
How to stop Rspec loading my Cucumber fixtures
I have a bunch of fixtures designed to populate the database for my Cucumber
integration tests.
But at this stage I want my database to be empty when using Rspec.
So, I moved the fixtures from `/spec/fixtures` to
`features/support/fixtures`, and updated `features/support/env.rb` to read:
Fixtures.reset_cache
fixtures_folder = File.join(RAILS_ROOT, ''features'',
2009 Feb 02
2
looking for help with NoMethodError: undefined method `key?' for #<String:0x4795488>
Hi all,
Any help with this would be appreciated. I''m using instant rails,
updated to 2.2.2, on Windows XP.
I''ve created my DB and scaffolded a few things and put some fixtures
into place, and when I run the tests I get many errors that look like
this:
---------------------------------
1) Error:
test_the_truth(EntityTest):
NoMethodError: undefined method `key?'' for
2005 Nov 10
6
Manually loading fixture data
Hi all,
I''ve got some tables with fixed amounts of data in them (a "states"
table, for example). For tables like this I can easily put *all* of the
data in the fixture.
For general futzing purposes, and for those times I want to reload a
database from scratch outside of testing (for whatever reason), what''s
the best approach? I thought perhaps ActiveRecord::Base had