aboutsummaryrefslogtreecommitdiffstats
path: root/activerecord/lib/active_record/fixtures.rb
Commit message (Collapse)AuthorAgeFilesLines
...
* Prefer to instantiate fixtures with model classes instead of their names, ↵Jeremy Kemper2008-01-051-13/+14
| | | | | | avoiding excess constant lookups. Closes #10677 [nwilmes] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8561 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Cache fixture model class. References #10677 [nwilmes]Jeremy Kemper2008-01-051-2/+10
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8560 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Ruby 1.9: Forwards compatibility change for fixtures and the new CSV module ↵Michael Koziarski2008-01-031-1/+1
| | | | | | [JEG2] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8544 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Ruby 1.9 compat: fix two failing tests since String#each has been removed. ↵Jeremy Kemper2008-01-021-1/+3
| | | | | | Closes #10655. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8524 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Ruby 1.9 compat: Fixtures inherits Hash instead of YAML::Omap since it's now ↵Jeremy Kemper2007-12-221-2/+2
| | | | | | insertion-ordered. Work around a &:procname crash. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8480 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Revert [8392]. Closes #10568, reopens #10379.Jeremy Kemper2007-12-191-13/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8442 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Make the Fixtures Test::Unit enhancements more supporting for double-loaded ↵Rick Olson2007-12-151-2/+13
| | | | | | test cases. Closes #10379 [brynary] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8392 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Be careful not to reference ActiveRecord if it isn't loaded, fixing rake ↵Jeremy Kemper2007-12-091-1/+6
| | | | | | test when you're working without a database. [eedn] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8339 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Foxy fixtures: support single-table inheritance. Closes #10234.Jeremy Kemper2007-11-261-1/+13
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8219 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Foxy fixtures: allow mixed usage to make migration easier and more ↵Jeremy Kemper2007-11-261-11/+18
| | | | | | attractive. Closes #10004. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8218 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixed that create table with :id => false and fixtures don't play nice ↵David Heinemeier Hansson2007-11-251-2/+6
| | | | | | together (closes #10154) [jbarnette] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8205 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add 'foxy' support for fixtures of polymorphic associations. Closes #10183 ↵Michael Koziarski2007-11-201-0/+35
| | | | | | [jbarnette, David Lowenfels] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8170 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Smattering of grammatical fixes to documentation. Closes #10083 [BobSilva]Marcel Molina2007-11-081-7/+7
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8113 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Make fixtures work with the new test subclasses. [tarmo, Koz]Michael Koziarski2007-10-311-6/+6
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8060 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Foxy fixtures. Adapter#disable_referential_integrity. Closes #9981.Jeremy Kemper2007-10-261-15/+295
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8036 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Quote table names. Defaults to column quoting. Closes #4593.Jeremy Kemper2007-10-161-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7932 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures test fixes and general cleanup. Closes #9682 [norbert]Jeremy Kemper2007-09-281-97/+91
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7667 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added fixture caching thatll speed up a normal fixture-powered test suite ↵David Heinemeier Hansson2007-09-281-15/+56
| | | | | | between 50% and 100% (closes #9682) [frederick.cheung@gmail.com] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7662 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* self.fixture_class_names is defined twice in fixtures.rb (closes #7135) [jarkko]David Heinemeier Hansson2007-09-221-3/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@7584 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures: correctly delete and insert fixtures in a single transaction. ↵Jeremy Kemper2007-06-051-1/+1
| | | | | | Closes #8553. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6944 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures: people(:technomancy, :josh) returns both fixtures. Closes #7880.Jeremy Kemper2007-06-051-9/+15
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6940 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Oracle binary fixtures; pull fixture insertion into the adapters. Closes #7987.Jeremy Kemper2007-05-261-1/+3
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6859 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fix column type detection while loading fixtures. Closes #7987 [roderickvd]Rick Olson2007-05-211-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6798 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures: fix YAML ordered map support. Closes #2665.Jeremy Kemper2007-03-091-6/+18
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6360 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Setting fixtures automatically for integration tests is a bit harder -- will ↵David Heinemeier Hansson2007-02-251-0/+2
| | | | | | have to wait until the test superclass reform is implemented git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6228 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added fixtures :all to test_helper.rb to assume that most people just want ↵David Heinemeier Hansson2007-02-251-3/+12
| | | | | | all their fixtures loaded all the time [DHH] Added fixtures :all as a way of loading all fixtures in the fixture directory at once (closes #7214) [manfred] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6227 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures use the table name and connection from set_fixture_class. Closes #7330.Jeremy Kemper2007-01-241-0/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@6023 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Change fixture_path to a class inheritable accessor allowing test cases to ↵Michael Koziarski2006-11-211-1/+1
| | | | | | have their own custom set of fixtures. Closes #6672 [zdennis] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5604 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Compare to 0 rather than call zero? to handle nil.Jeremy Kemper2006-10-111-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5282 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Don't rollback in teardown unless a transaction was started. Don't start a ↵Jeremy Kemper2006-10-091-4/+4
| | | | | | transaction in create_fixtures if a transaction is started. Closes #6282. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5270 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Improve yaml fixtures error reporting. Closes #6205.Jeremy Kemper2006-09-131-13/+16
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@5104 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Fixtures: correct escaping of \n and \r. Closes #5859.Jeremy Kemper2006-08-241-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4811 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Use require_dependency and not require to load modelsNicholas Seckar2006-08-121-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4753 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Tweak fixtures so they don't try to use a non-ActiveRecord class. [Kevin Clark]Rick Olson2006-08-111-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4752 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* occured -> occurred. Closes #5559.Jeremy Kemper2006-07-101-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4604 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Ignore fixtures in test cases if there are no database configurations. ↵Jeremy Kemper2006-07-101-2/+2
| | | | | | References #5497. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4603 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* r4720@asus: jeremy | 2006-06-28 18:12:57 -0700Jeremy Kemper2006-06-291-2/+4
| | | | | | | Don't be such a hardass. References #5497. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4508 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Don't assume Active Record is available. Closes #5497.Jeremy Kemper2006-06-281-0/+2
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4505 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* r4644@asus: jeremy | 2006-06-16 14:57:03 -0700Jeremy Kemper2006-06-191-2/+2
| | | | | | | | | | | | | | | | | | | | | locking r4645@asus: jeremy | 2006-06-17 12:41:30 -0700 missing reply fixture r4646@asus: jeremy | 2006-06-19 13:05:23 -0700 Use a per-thread (rather than global) transaction mutex so you may execute concurrent transactions on separate connections. r4647@asus: jeremy | 2006-06-19 13:07:23 -0700 PostgreSQL: introduce allow_concurrency option which determines whether to use blocking or asynchronous #execute. Adapters with blocking #execute will deadlock Ruby threads. The default value is ActiveRecord::Base.allow_concurrency. r4648@asus: jeremy | 2006-06-19 13:08:40 -0700 Pass the default allow_concurrency when instantiating new connections. r4649@asus: jeremy | 2006-06-19 13:11:12 -0700 Break out concurrent transaction tests and run them for PostgreSQLAdapter only (need to fork or system('some_test_script') for the other adapters) r4650@asus: jeremy | 2006-06-19 13:42:48 -0700 Row locking. Provide a locking clause with the :lock finder option or true for the default "FOR UPDATE". r4661@asus: jeremy | 2006-06-19 15:36:51 -0700 excise the junk mutex git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4460 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Quell warnings. Closes #5245.Jeremy Kemper2006-06-011-3/+4
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4392 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add support for FrontBase (http://www.frontbase.com/) with a new adapter ↵Marcel Molina2006-04-271-1/+7
| | | | | | thanks to the hard work of one Mike Laster. Closes #4093. [mlaster@metavillage.com] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@4291 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* fix AR tests for sqliteRick Olson2006-03-161-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3896 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Catch FixtureClassNotFound when using instantiated fixtures on a fixture ↵Rick Olson2006-03-141-2/+4
| | | | | | that has no ActiveRecord model [Rick Olson] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3866 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Allow set_fixture_class to take Classes instead of strings for a class in a ↵Rick Olson2006-03-061-2/+7
| | | | | | module. Raise FixtureClassNotFound if a fixture can't load. [Rick Olson] closes #4095 git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3804 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Clear stale, cached connections left behind by defunct threads. Eliminate ↵Jeremy Kemper2006-03-011-1/+1
| | | | | | duplicate connection cache. git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3729 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Make rake load_fixtures work with the new, flexible, fixtures api. [Rick ↵Michael Koziarski2006-02-281-1/+1
| | | | | | Olson]. Closes #3995 git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3706 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Change Fixtures.create_fixtures arity to be backwards compatibleNicholas Seckar2006-02-281-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3694 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Add set_fixture_class to allow the use of table name accessors with models ↵Nicholas Seckar2006-02-271-9/+16
| | | | | | which use set_default_name. Closes #3935 git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3690 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Only load .yml files in sub-directoriesDavid Heinemeier Hansson2006-02-271-1/+1
| | | | git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3685 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
* Added that fixtures to placed in subdirectories of the main fixture files ↵David Heinemeier Hansson2006-02-271-1/+8
| | | | | | are also loaded (closes #3937) [dblack@wobblini.net] git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@3683 5ecf4fe2-1ee6-0310-87b1-e25e094e27de