From 60f4081e135bdcd893d60192e652c4b829c656dd Mon Sep 17 00:00:00 2001 From: Robert Speicher Date: Fri, 1 Apr 2016 20:29:48 -0400 Subject: Factories don't have to be limited to `ActiveRecord` objects [ci skip] --- doc/development/testing.md | 2 ++ 1 file changed, 2 insertions(+) (limited to 'doc/development') diff --git a/doc/development/testing.md b/doc/development/testing.md index a7e85ecebed..3d1c4ccab47 100644 --- a/doc/development/testing.md +++ b/doc/development/testing.md @@ -22,6 +22,8 @@ fixture replacement. resulting record to pass validation. - When instantiating from a factory, don't supply extraneous attributes that aren't required by the test. +- Factories don't have to be limited to `ActiveRecord` objects. + [See example](https://gitlab.com/gitlab-org/gitlab-ce/commit/0b8cefd3b2385a21cfed779bd659978c0402766d). [factory_girl]: https://github.com/thoughtbot/factory_girl [Traits]: http://www.rubydoc.info/gems/factory_girl/file/GETTING_STARTED.md#Traits -- cgit v1.2.1