diff options
author | Eric Davis <edavis@littlestreamsoftware.com> | 2010-01-27 18:29:03 +0000 |
---|---|---|
committer | Eric Davis <edavis@littlestreamsoftware.com> | 2010-01-27 18:29:03 +0000 |
commit | 9044305b9335bb74f607944ffb3d6dd483da8f0b (patch) | |
tree | 646cd39bba4dfd5b5b08469c9fa01d53627ef6b6 /test/exemplars/issue_category_exemplar.rb | |
parent | d1c90d9abfd54dfa815e3401ce60af1e288ab122 (diff) | |
download | redmine-9044305b9335bb74f607944ffb3d6dd483da8f0b.tar.gz redmine-9044305b9335bb74f607944ffb3d6dd483da8f0b.zip |
Added some exemplars for object daddy to generate test data.
git-svn-id: svn+ssh://rubyforge.org/var/svn/redmine/trunk@3340 e93f8b46-1217-0410-a6f0-8f06a7374b81
Diffstat (limited to 'test/exemplars/issue_category_exemplar.rb')
-rw-r--r-- | test/exemplars/issue_category_exemplar.rb | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/test/exemplars/issue_category_exemplar.rb b/test/exemplars/issue_category_exemplar.rb new file mode 100644 index 000000000..318947c29 --- /dev/null +++ b/test/exemplars/issue_category_exemplar.rb @@ -0,0 +1,9 @@ +class IssueCategory < ActiveRecord::Base + generator_for :name, :method => :next_name + + def self.next_name + @last_name ||= 'Category 0001' + @last_name.succ! + @last_name + end +end |