]> git.openstreetmap.org Git - rails.git/blobdiff - test/factories/changesets.rb
Merge remote-tracking branch 'upstream/pull/5296'
[rails.git] / test / factories / changesets.rb
index f76b73126d0374eed28f9eb0a9d03138571bf4f0..d4ebdcee133d8811822db1f8974e8f13066f3b27 100644 (file)
@@ -1,8 +1,13 @@
-FactoryGirl.define do
+FactoryBot.define do
   factory :changeset do
-    created_at Time.now.utc
-    closed_at Time.now.utc + 1.day
+    created_at { Time.now.utc }
+    closed_at { Time.now.utc + 1.day }
 
     user
+
+    trait :closed do
+      created_at { Time.now.utc - 5.hours }
+      closed_at { Time.now.utc - 4.hours }
+    end
   end
 end