diff options
Diffstat (limited to 'test/exemplars/change_exemplar.rb')
-rw-r--r-- | test/exemplars/change_exemplar.rb | 15 |
1 files changed, 15 insertions, 0 deletions
diff --git a/test/exemplars/change_exemplar.rb b/test/exemplars/change_exemplar.rb new file mode 100644 index 000000000..97985fbf5 --- /dev/null +++ b/test/exemplars/change_exemplar.rb @@ -0,0 +1,15 @@ +class Change < ActiveRecord::Base + generator_for :action => 'A' + generator_for :path, :method => :next_path + generator_for :changeset, :method => :generate_changeset + + def self.next_path + @last_path ||= 'test/dir/aaa0001' + @last_path.succ! + @last_path + end + + def self.generate_changeset + Changeset.generate! + end +end |