kennyj
75322ac5b8
Added *instance_writer: false* for stored/serialized attributes.
2012-07-07 16:36:21 +09:00
Nathan Broadbent
b31eac5609
Replaced all 'for' loops with Enumerable#each
2012-01-30 03:15:49 +08:00
Aaron Patterson
522c0fdb55
The primary key is always initialized in the @attributes hash to nil (unless
...
another value has been specified).
2012-01-25 14:42:22 -08:00
Jon Leighton
50d395f96e
Raise error when using write_attribute with a non-existent attribute.
...
Previously we would just silently write the attribute. This can lead to
subtle bugs (for example, see the change in AutosaveAssociation where a
through association would wrongly gain an attribute.
Also, ensuring that we never gain any new attributes after
initialization will allow me to reduce our dependence on method_missing.
2011-09-13 00:01:58 +01:00
John Firebaugh
1723a7a6c6
Move to_xml tests to xml_serialization_test.rb
...
One duplicate was eliminated: test_to_xml_including_methods/
test_methods_are_called_on_object.
2011-07-17 11:34:07 -07:00
Aaron Patterson
61774e0d49
please use ruby -I lib:test path/to/test.rb, or export RUBY_OPT
2011-06-06 15:47:13 -07:00
Jon Leighton
253bb6b926
Refactor Active Record test connection setup. Please see the RUNNING_UNIT_TESTS file for details, but essentially you can now configure things in test/config.yml. You can also run tests directly via the command line, e.g. ruby path/to/test.rb (no rake needed, uses default db connection from test/config.yml). This will help us fix the CI by enabling us to isolate the different Rails versions to different databases.
2011-06-04 23:47:03 +01:00
Aaron Patterson
5b42e96602
make sure de-serialization happens on object instantiation
2011-02-01 15:23:55 -08:00
Santiago Pastorino
b451de0d6d
Deletes trailing whitespaces (over text files only find * -type f -exec sed 's/[ \t]*$//' -i {} \;)
2010-08-14 04:12:33 -03:00
Neeraj Singh
807239f5a1
Making Active Record base_test.rb thinner by moving tests
...
to relevant files.
Number of assertions before refactoring:
2391 tests, 7579 assertions, 0 failures, 0 errors
Number of assertions after refactoring:
2391 tests, 7579 assertions, 0 failures, 0 errors
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-08-03 10:45:54 +02:00
Lawrence Pit
60504e62c8
to_xml with :include should skip_instruct on the included records [ #4506 state:resolved]
...
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-04-30 14:22:57 +02:00
Jeremy Kemper
39814fcce0
Merge branch 'ar-test-cleanup' of git://git.geeksomnia.com/rails
...
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8681 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-21 17:20:51 +00:00
Jeremy Kemper
1e70928014
Fix paths
...
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8661 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-18 07:31:37 +00:00
Jeremy Kemper
42b39ae3f2
Move tests to cases
...
git-svn-id: http://svn-commit.rubyonrails.org/rails/trunk@8660 5ecf4fe2-1ee6-0310-87b1-e25e094e27de
2008-01-18 07:30:42 +00:00