test/dummy_app/log/test.log in active_snapshot-0.2.3 vs test/dummy_app/log/test.log in active_snapshot-0.2.4
- old
+ new
@@ -1,1346 +1,2109 @@
- [1m[35m (1.8ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (1.1ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)[0m
+ [1m[35m (1.7ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[35m (1.0ms)[0m [1m[35mCREATE TABLE "schema_migrations" ("version" varchar NOT NULL PRIMARY KEY)[0m
[1m[35m (1.0ms)[0m [1m[35mCREATE TABLE "ar_internal_metadata" ("key" varchar NOT NULL PRIMARY KEY, "value" varchar, "created_at" datetime(6) NOT NULL, "updated_at" datetime(6) NOT NULL)[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.2ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
Migrating to SetUpTestTables (20210128155312)
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[35m (0.3ms)[0m [1m[35mCREATE TABLE "posts" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "a" integer, "b" integer, "created_at" datetime(6) NOT NULL, "updated_at" datetime(6) NOT NULL)[0m
+ [1m[35m (0.4ms)[0m [1m[35mCREATE TABLE "posts" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "a" integer, "b" integer, "created_at" datetime(6) NOT NULL, "updated_at" datetime(6) NOT NULL)[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "comments" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "content" varchar, "post_id" integer, "created_at" datetime(6) NOT NULL, "updated_at" datetime(6) NOT NULL)[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE INDEX "index_comments_on_post_id" ON "comments" ("post_id")[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "notes" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "body" varchar, "post_id" integer, "created_at" datetime(6) NOT NULL, "updated_at" datetime(6) NOT NULL)[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE INDEX "index_notes_on_post_id" ON "notes" ("post_id")[0m
- [1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20210128155312"]]
- [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveRecord::SchemaMigration Create (0.2ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20210128155312"]]
+ [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
Migrating to CreateSnapshotsTables (20210306100122)
- [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
- [1m[35m (0.3ms)[0m [1m[35mCREATE TABLE "snapshots" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "item_type" varchar NOT NULL, "item_id" integer NOT NULL, "identifier" varchar NOT NULL, "user_type" varchar, "user_id" integer, "metadata" text, "created_at" datetime NOT NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[35m (0.3ms)[0m [1m[35mCREATE TABLE "snapshots" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "item_type" varchar NOT NULL, "item_id" integer NOT NULL, "identifier" varchar NOT NULL, "user_type" varchar, "user_id" integer, "metadata" text, "created_at" datetime(6) NOT NULL)[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE INDEX "index_snapshots_on_item" ON "snapshots" ("item_type", "item_id")[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE INDEX "index_snapshots_on_identifier" ON "snapshots" ("identifier")[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE INDEX "index_snapshots_on_user" ON "snapshots" ("user_type", "user_id")[0m
- [1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "snapshot_items" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "snapshot_id" integer NOT NULL, "item_type" varchar NOT NULL, "item_id" integer NOT NULL, "object" text NOT NULL, "created_at" datetime NOT NULL, "child_group_name" varchar)[0m
+ [1m[35m (0.1ms)[0m [1m[35mCREATE TABLE "snapshot_items" ("id" integer PRIMARY KEY AUTOINCREMENT NOT NULL, "snapshot_id" integer NOT NULL, "item_type" varchar NOT NULL, "item_id" integer NOT NULL, "object" text NOT NULL, "created_at" datetime(6) NOT NULL, "child_group_name" varchar)[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE INDEX "index_snapshot_items_on_snapshot_id" ON "snapshot_items" ("snapshot_id")[0m
[1m[35m (0.1ms)[0m [1m[35mCREATE INDEX "index_snapshot_items_on_item" ON "snapshot_items" ("item_type", "item_id")[0m
[1m[36mActiveRecord::SchemaMigration Create (0.1ms)[0m [1m[32mINSERT INTO "schema_migrations" ("version") VALUES (?)[0m [["version", "20210306100122"]]
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
- [1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveRecord::InternalMetadata Load (0.2ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveRecord::InternalMetadata Create (0.2ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["key", "environment"], ["value", "test"], ["created_at", "2021-08-19 23:28:07.589659"], ["updated_at", "2021-08-19 23:28:07.589659"]]
+ [1m[36mActiveRecord::InternalMetadata Create (0.3ms)[0m [1m[32mINSERT INTO "ar_internal_metadata" ("key", "value", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["key", "environment"], ["value", "test"], ["created_at", "2022-02-25 19:12:04.897521"], ["updated_at", "2022-02-25 19:12:04.897521"]]
[1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
- [1m[35m (0.7ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (1.0ms)[0m [1m[31mDELETE FROM posts;[0m
[1m[35m (0.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
- [1m[35m (0.7ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
[1m[35m (0.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
- [1m[35m (0.7ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
[1m[35m (0.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
+ [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:12:04.909679"], ["updated_at", "2022-02-25 19:12:04.909679"]]
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-19 23:28:07.601363"], ["updated_at", "2021-08-19 23:28:07.601363"]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:12:04.928557"]]
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[35m (1.1ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::InternalMetadata Load (0.2ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
+ [1m[35m (6.6ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:12:12.893690"], ["updated_at", "2022-02-25 19:12:12.893690"]]
+ [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:12:12.908543"]]
[1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[35m (1.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
+ [1m[35m (6.5ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:13:03.860645"], ["updated_at", "2022-02-25 19:13:03.860645"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:07.616280"]]
- [1m[36mTRANSACTION (1.2ms)[0m [1m[36mcommit transaction[0m
- [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:13:03.875638"]]
+ [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
id: 1
a: 1
b: 3
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:28:07.601363000 Z
+ utc: &1 2022-02-25 19:13:03.860645000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:07.601363000 Z
+ time: 2022-02-25 19:13:03.860645000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:28:07.601363000 Z
-','2021-08-19 23:28:07.639023',NULL)[0m
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ time: 2022-02-25 19:13:03.860645000 Z
+','2022-02-25 19:13:03.893865',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Update (0.8ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.2ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:07.643299"]]
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:13:03.898486"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:28:07.601363000 Z
+ utc: &1 2022-02-25 19:13:03.860645000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:07.601363000 Z
+ time: 2022-02-25 19:13:03.860645000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:28:07.601363000 Z
-','2021-08-19 23:28:07.646425',NULL)[0m
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ time: 2022-02-25 19:13:03.860645000 Z
+','2022-02-25 19:13:03.902588',NULL)[0m
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+-----------------------------
+SnapshotItemTest: test_object
+-----------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.3ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------
+SnapshotItemTest: test_validations
+----------------------------------
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_relationships
+------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------------------
ActiveSnapshotTest: test_exposes_main_module
--------------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
ActiveSnapshotTest: test_exposes_version
----------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
ActiveSnapshotTest: test_snapshot_lifecycle
-------------------------------------------
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.2ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:28:07.688491"], ["updated_at", "2021-08-19 23:28:07.688491"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.4ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:13:03.964212"], ["updated_at", "2022-02-25 19:13:03.964212"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:07.691182"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:13:03.968271"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:07.601363000 Z
+ time: 2022-02-25 19:13:03.860645000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: *1
- time: 2021-08-19 23:28:07.601363000 Z
-','2021-08-19 23:28:07.694320',NULL),(NULL,3,'Comment',1,'---
+ time: 2022-02-25 19:13:03.860645000 Z
+','2022-02-25 19:13:03.972211',NULL),(NULL,3,'Comment',1,'---
id: 1
content: foo
post_id: 1
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.688491000 Z
+ utc: 2022-02-25 19:13:03.964212000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:07.688491000 Z
+ time: 2022-02-25 19:13:03.964212000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.688491000 Z
+ utc: 2022-02-25 19:13:03.964212000 Z
zone: *1
- time: 2021-08-19 23:28:07.688491000 Z
-','2021-08-19 23:28:07.694320','comments')[0m
+ time: 2022-02-25 19:13:03.964212000 Z
+','2022-02-25 19:13:03.972211','comments')[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:28:07.695499"], ["id", 1]]
- [1m[36mPost Update (0.0ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:28:07.695924"], ["id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:13:03.973406"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:13:03.973883"], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:28:07.696917"], ["updated_at", "2021-08-19 23:28:07.696917"]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:13:03.975029"], ["updated_at", "2022-02-25 19:13:03.975029"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2021-08-19 23:28:07.697739"], ["updated_at", "2021-08-19 23:28:07.697739"]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:13:03.975912"], ["updated_at", "2022-02-25 19:13:03.975912"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
[1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-19 23:28:07.601363"], ["id", 1]]
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:28:07.688491"], ["updated_at", "2021-08-19 23:28:07.688491"]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:13:03.860645"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:13:03.964212"], ["updated_at", "2022-02-25 19:13:03.964212"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------
+SnapshotTest: test_relationships
+--------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_fetch_reified_items
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.4ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:13:03.995905"], ["updated_at", "2022-02-25 19:13:03.995905"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:13:03.998326"], ["updated_at", "2022-02-25 19:13:03.998326"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:13:04.000765"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:13:03.995905000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:13:03.995905000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:13:03.995905000 Z
+','2022-02-25 19:13:04.004888',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: Example comment
+post_id: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:13:03.998326000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:13:03.998326000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:13:03.998326000 Z
+ zone: *1
+ time: 2022-02-25 19:13:03.998326000 Z
+','2022-02-25 19:13:04.004888','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_build_snapshot_item
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------
SnapshotTest: test_restore
--------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
- [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------
-SnapshotTest: test_build_snapshot_item
---------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
---------------------------------------
-SnapshotTest: test_fetch_reified_items
---------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:13:04.021808"], ["updated_at", "2022-02-25 19:13:04.021808"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:13:04.024515"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------
SnapshotTest: test_validations
------------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------
-SnapshotTest: test_metadata
----------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------
-SnapshotTest: test_relationships
---------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_relationships
-------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-----------------------------------
-SnapshotItemTest: test_validations
-----------------------------------
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------
-SnapshotItemTest: test_object
------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_restore_item!
-------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.6ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
SnapshotsConcernTest: test_has_snapshot_children
------------------------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
SnapshotsConcernTest: test_relationships
----------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
SnapshotsConcernTest: test_create_snapshot!
-------------------------------------------
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2021-08-19 23:28:07.754325"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:13:04.040908"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:07.601363000 Z
+ time: 2022-02-25 19:13:03.860645000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: *1
- time: 2021-08-19 23:28:07.601363000 Z
-','2021-08-19 23:28:07.757455',NULL)[0m
+ time: 2022-02-25 19:13:03.860645000 Z
+','2022-02-25 19:13:04.043969',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:07.759398"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:13:04.057459"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:07.601363000 Z
+ time: 2022-02-25 19:13:03.860645000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: *1
- time: 2021-08-19 23:28:07.601363000 Z
-','2021-08-19 23:28:07.762080',NULL)[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ time: 2022-02-25 19:13:03.860645000 Z
+','2022-02-25 19:13:04.060607',NULL)[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:07.764341"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:13:04.063001"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:07.601363000 Z
+ time: 2022-02-25 19:13:03.860645000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:07.601363000 Z
+ utc: 2022-02-25 19:13:03.860645000 Z
zone: *1
- time: 2021-08-19 23:28:07.601363000 Z
-','2021-08-19 23:28:07.767417',NULL)[0m
+ time: 2022-02-25 19:13:03.860645000 Z
+','2022-02-25 19:13:04.066440',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-----------------------------------------------
InstallGeneratorTest: test_should_add_migration
-----------------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[35m (1.5ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[35m (1.1ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
[1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
- [1m[35m (1.9ms)[0m [1m[31mDELETE FROM posts;[0m
- [1m[35m (1.4ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
- [1m[35m (1.2ms)[0m [1m[31mDELETE FROM snapshots;[0m
- [1m[35m (1.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
- [1m[35m (1.0ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
- [1m[35m (1.0ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[35m (6.6ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-19 23:28:46.603059"], ["updated_at", "2021-08-19 23:28:46.603059"]]
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:15:25.078053"], ["updated_at", "2022-02-25 19:15:25.078053"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:46.616208"]]
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:15:25.092481"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
id: 1
a: 1
b: 3
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:28:46.603059000 Z
+ utc: &1 2022-02-25 19:15:25.078053000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:46.603059000 Z
+ time: 2022-02-25 19:15:25.078053000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:28:46.603059000 Z
-','2021-08-19 23:28:46.631882',NULL)[0m
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
- [1m[36mPost Update (0.7ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
+ time: 2022-02-25 19:15:25.078053000 Z
+','2022-02-25 19:15:25.111188',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Update (0.8ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:46.635496"]]
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:15:25.115568"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:28:46.603059000 Z
+ utc: &1 2022-02-25 19:15:25.078053000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:46.603059000 Z
+ time: 2022-02-25 19:15:25.078053000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:28:46.603059000 Z
-','2021-08-19 23:28:46.638687',NULL)[0m
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
+ time: 2022-02-25 19:15:25.078053000 Z
+','2022-02-25 19:15:25.119373',NULL)[0m
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+-------------------------------------------
+SnapshotsConcernTest: test_create_snapshot!
+-------------------------------------------
+ [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:15:25.153158"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.078053000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:15:25.078053000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.078053000 Z
+ zone: *1
+ time: 2022-02-25 19:15:25.078053000 Z
+','2022-02-25 19:15:25.156246',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:15:25.157969"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.078053000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:15:25.078053000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.078053000 Z
+ zone: *1
+ time: 2022-02-25 19:15:25.078053000 Z
+','2022-02-25 19:15:25.160211',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:15:25.161627"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.078053000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:15:25.078053000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.078053000 Z
+ zone: *1
+ time: 2022-02-25 19:15:25.078053000 Z
+','2022-02-25 19:15:25.163956',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
-ActiveSnapshotTest: test_exposes_version
+SnapshotsConcernTest: test_relationships
----------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------------------
+SnapshotsConcernTest: test_has_snapshot_children
+------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------
+SnapshotItemTest: test_object
+-----------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.3ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_relationships
+------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------
+SnapshotItemTest: test_validations
+----------------------------------
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:15:25.194468"], ["updated_at", "2022-02-25 19:15:25.194468"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:15:25.198294"], ["updated_at", "2022-02-25 19:15:25.198294"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.2ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:15:25.200794"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:15:25.194468000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:15:25.194468000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:15:25.194468000 Z
+','2022-02-25 19:15:25.205518',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: Example comment
+post_id: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.198294000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:15:25.198294000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:15:25.198294000 Z
+ zone: *1
+ time: 2022-02-25 19:15:25.198294000 Z
+','2022-02-25 19:15:25.205518','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:15:25.213227"], ["updated_at", "2022-02-25 19:15:25.213227"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:15:25.216071"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'ParentWithoutChildren',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:15:25.213227000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:15:25.213227000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:15:25.213227000 Z
+','2022-02-25 19:15:25.217553',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ?, "updated_at" = ? WHERE "posts"."id" = ?[0m [["a", 9], ["b", 9], ["updated_at", "2022-02-25 19:15:25.218410"], ["id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_build_snapshot_item
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------
+SnapshotTest: test_restore
+--------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------
+SnapshotTest: test_validations
+------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.2ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_fetch_reified_items
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------
+SnapshotTest: test_relationships
+--------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------
+InstallGeneratorTest: test_should_add_migration
+-----------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------------
+ActiveSnapshotTest: test_exposes_main_module
+--------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
ActiveSnapshotTest: test_snapshot_lifecycle
-------------------------------------------
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.2ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:28:46.668148"], ["updated_at", "2021-08-19 23:28:46.668148"]]
+ [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:15:25.250285"], ["updated_at", "2022-02-25 19:15:25.250285"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:46.670427"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:15:25.254114"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:15:25.078053000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:46.603059000 Z
+ time: 2022-02-25 19:15:25.078053000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:15:25.078053000 Z
zone: *1
- time: 2021-08-19 23:28:46.603059000 Z
-','2021-08-19 23:28:46.672991',NULL),(NULL,3,'Comment',1,'---
+ time: 2022-02-25 19:15:25.078053000 Z
+','2022-02-25 19:15:25.258085',NULL),(NULL,3,'Comment',1,'---
id: 1
content: foo
post_id: 1
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.668148000 Z
+ utc: 2022-02-25 19:15:25.250285000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:46.668148000 Z
+ time: 2022-02-25 19:15:25.250285000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.668148000 Z
+ utc: 2022-02-25 19:15:25.250285000 Z
zone: *1
- time: 2021-08-19 23:28:46.668148000 Z
-','2021-08-19 23:28:46.672991','comments')[0m
+ time: 2022-02-25 19:15:25.250285000 Z
+','2022-02-25 19:15:25.258085','comments')[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:28:46.673978"], ["id", 1]]
- [1m[36mPost Update (0.0ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:28:46.674338"], ["id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:15:25.269725"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:15:25.270370"], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:28:46.675175"], ["updated_at", "2021-08-19 23:28:46.675175"]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:15:25.271722"], ["updated_at", "2022-02-25 19:15:25.271722"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2021-08-19 23:28:46.675840"], ["updated_at", "2021-08-19 23:28:46.675840"]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:15:25.273014"], ["updated_at", "2022-02-25 19:15:25.273014"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
- [1m[36mPost Update (0.0ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-19 23:28:46.603059"], ["id", 1]]
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:28:46.668148"], ["updated_at", "2021-08-19 23:28:46.668148"]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:15:25.078053"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:15:25.250285"], ["updated_at", "2022-02-25 19:15:25.250285"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------------
-ActiveSnapshotTest: test_exposes_main_module
---------------------------------------------
+ [1m[36mTRANSACTION (108.7ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------
+ActiveSnapshotTest: test_exposes_version
+----------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[35m (1.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
+ [1m[35m (6.5ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:16:53.817957"], ["updated_at", "2022-02-25 19:16:53.817957"]]
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:16:53.832548"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
+id: 1
+a: 1
+b: 3
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:16:53.817957000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:16:53.817957000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:16:53.817957000 Z
+','2022-02-25 19:16:53.851096',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Update (0.7ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.5ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:16:53.855336"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:16:53.817957000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:16:53.817957000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:16:53.817957000 Z
+','2022-02-25 19:16:53.859488',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+--------------------------------
+SnapshotTest: test_relationships
+--------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
--------------------------------------
SnapshotTest: test_fetch_reified_items
--------------------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------
-SnapshotTest: test_relationships
---------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:16:53.899474"], ["updated_at", "2022-02-25 19:16:53.899474"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:16:53.902868"], ["updated_at", "2022-02-25 19:16:53.902868"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:16:53.904842"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:16:53.899474000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:16:53.899474000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:16:53.899474000 Z
+','2022-02-25 19:16:53.908424',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: Example comment
+post_id: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:16:53.902868000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:16:53.902868000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:16:53.902868000 Z
+ zone: *1
+ time: 2022-02-25 19:16:53.902868000 Z
+','2022-02-25 19:16:53.908424','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------
-SnapshotTest: test_validations
-------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.5ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:16:53.915861"], ["updated_at", "2022-02-25 19:16:53.915861"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:16:53.919313"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'ParentWithoutChildren',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:16:53.915861000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:16:53.915861000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:16:53.915861000 Z
+','2022-02-25 19:16:53.920892',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ?, "updated_at" = ? WHERE "posts"."id" = ?[0m [["a", 9], ["b", 9], ["updated_at", "2022-02-25 19:16:53.921931"], ["id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_build_snapshot_item
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------
-SnapshotTest: test_metadata
----------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------
SnapshotTest: test_restore
--------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
[1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+------------------------------
+SnapshotTest: test_validations
+------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.2ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------
-SnapshotTest: test_build_snapshot_item
---------------------------------------
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
-InstallGeneratorTest: test_should_add_migration
------------------------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
SnapshotsConcernTest: test_has_snapshot_children
------------------------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-----------------------------------------
-SnapshotsConcernTest: test_relationships
-----------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
SnapshotsConcernTest: test_create_snapshot!
-------------------------------------------
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2021-08-19 23:28:46.720422"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:17:11.237904"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:16:53.817957000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:46.603059000 Z
+ time: 2022-02-25 19:16:53.817957000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:16:53.817957000 Z
zone: *1
- time: 2021-08-19 23:28:46.603059000 Z
-','2021-08-19 23:28:46.723268',NULL)[0m
+ time: 2022-02-25 19:16:53.817957000 Z
+','2022-02-25 19:17:11.241539',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:46.725154"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:17:11.244057"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:16:53.817957000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:46.603059000 Z
+ time: 2022-02-25 19:16:53.817957000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:16:53.817957000 Z
zone: *1
- time: 2021-08-19 23:28:46.603059000 Z
-','2021-08-19 23:28:46.727906',NULL)[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ time: 2022-02-25 19:16:53.817957000 Z
+','2022-02-25 19:17:11.247382',NULL)[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:28:46.729775"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:17:11.250501"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:16:53.817957000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:28:46.603059000 Z
+ time: 2022-02-25 19:16:53.817957000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:28:46.603059000 Z
+ utc: 2022-02-25 19:16:53.817957000 Z
zone: *1
- time: 2021-08-19 23:28:46.603059000 Z
-','2021-08-19 23:28:46.732939',NULL)[0m
+ time: 2022-02-25 19:16:53.817957000 Z
+','2022-02-25 19:17:11.254169',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------
+SnapshotsConcernTest: test_relationships
+----------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
-----------------------------
SnapshotItemTest: test_object
-----------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_relationships
+------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------
SnapshotItemTest: test_validations
----------------------------------
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.2ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_restore_item!
-------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+-----------------------------------------------
+InstallGeneratorTest: test_should_add_migration
+-----------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_relationships
-------------------------------------
+--------------------------------------------
+ActiveSnapshotTest: test_exposes_main_module
+--------------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[35m (1.5ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------
+ActiveSnapshotTest: test_exposes_version
+----------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-------------------------------------------
+ActiveSnapshotTest: test_snapshot_lifecycle
+-------------------------------------------
+ [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:17:11.285298"], ["updated_at", "2022-02-25 19:17:11.285298"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:17:11.288619"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:16:53.817957000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:16:53.817957000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:16:53.817957000 Z
+ zone: *1
+ time: 2022-02-25 19:16:53.817957000 Z
+','2022-02-25 19:17:11.291952',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: foo
+post_id: 1
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:17:11.285298000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:17:11.285298000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:17:11.285298000 Z
+ zone: *1
+ time: 2022-02-25 19:17:11.285298000 Z
+','2022-02-25 19:17:11.291952','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:17:11.293152"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:17:11.293750"], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:17:11.295547"], ["updated_at", "2022-02-25 19:17:11.295547"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:17:11.296717"], ["updated_at", "2022-02-25 19:17:11.296717"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
+ [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:16:53.817957"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:17:11.285298"], ["updated_at", "2022-02-25 19:17:11.285298"]]
+ [1m[36mTRANSACTION (0.2ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[35m (1.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
[1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
- [1m[35m (1.9ms)[0m [1m[31mDELETE FROM posts;[0m
- [1m[35m (1.3ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
- [1m[35m (1.2ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (6.5ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
[1m[35m (1.0ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
- [1m[35m (1.1ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
- [1m[35m (1.0ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[35m (1.0ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-19 23:29:11.308109"], ["updated_at", "2021-08-19 23:29:11.308109"]]
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:18:38.895863"], ["updated_at", "2022-02-25 19:18:38.895863"]]
[1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:11.320795"]]
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:18:38.910682"]]
+ [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
id: 1
a: 1
b: 3
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:29:11.308109000 Z
+ utc: &1 2022-02-25 19:18:38.895863000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:11.308109000 Z
+ time: 2022-02-25 19:18:38.895863000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:29:11.308109000 Z
-','2021-08-19 23:29:11.336271',NULL)[0m
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
- [1m[36mPost Update (0.6ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
+ time: 2022-02-25 19:18:38.895863000 Z
+','2022-02-25 19:18:38.929364',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Update (0.8ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:11.339527"]]
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:18:38.933744"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:29:11.308109000 Z
+ utc: &1 2022-02-25 19:18:38.895863000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:11.308109000 Z
+ time: 2022-02-25 19:18:38.895863000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:29:11.308109000 Z
-','2021-08-19 23:29:11.342050',NULL)[0m
- [1m[36mTRANSACTION (0.4ms)[0m [1m[36mcommit transaction[0m
+ time: 2022-02-25 19:18:38.895863000 Z
+','2022-02-25 19:18:38.937428',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------
+InstallGeneratorTest: test_should_add_migration
+-----------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------
-SnapshotTest: test_validations
-------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.0ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------
-SnapshotTest: test_metadata
----------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------
-SnapshotTest: test_relationships
---------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------
SnapshotTest: test_restore
--------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
- [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:18:38.986638"], ["updated_at", "2022-02-25 19:18:38.986638"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:18:38.990142"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'ParentWithoutChildren',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:18:38.986638000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:18:38.986638000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:18:38.986638000 Z
+','2022-02-25 19:18:38.992515',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ?, "updated_at" = ? WHERE "posts"."id" = ?[0m [["a", 9], ["b", 9], ["updated_at", "2022-02-25 19:18:38.993451"], ["id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (222.6ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+--------------------------------
+SnapshotTest: test_relationships
+--------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------------
SnapshotTest: test_fetch_reified_items
--------------------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------
+SnapshotTest: test_validations
+------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------------
SnapshotTest: test_build_snapshot_item
--------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------------------
-ActiveSnapshotTest: test_snapshot_lifecycle
--------------------------------------------
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.2ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:29:11.384159"], ["updated_at", "2021-08-19 23:29:11.384159"]]
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.4ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:18:39.254042"], ["updated_at", "2022-02-25 19:18:39.254042"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:11.386301"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.2ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:18:39.258961"], ["updated_at", "2022-02-25 19:18:39.258961"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
-id: 1
-a: 2
-b: 4
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:18:39.261360"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
- zone: &1 !ruby/object:ActiveSupport::TimeZone
+ utc: &1 2022-02-25 19:18:39.254042000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:11.308109000 Z
+ time: 2022-02-25 19:18:39.254042000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
- zone: *1
- time: 2021-08-19 23:29:11.308109000 Z
-','2021-08-19 23:29:11.389012',NULL),(NULL,3,'Comment',1,'---
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:18:39.254042000 Z
+','2022-02-25 19:18:39.265432',NULL),(NULL,3,'Comment',1,'---
id: 1
-content: foo
-post_id: 1
+content: Example comment
+post_id: 2
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.384159000 Z
+ utc: 2022-02-25 19:18:39.258961000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:11.384159000 Z
+ time: 2022-02-25 19:18:39.258961000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.384159000 Z
+ utc: 2022-02-25 19:18:39.258961000 Z
zone: *1
- time: 2021-08-19 23:29:11.384159000 Z
-','2021-08-19 23:29:11.389012','comments')[0m
+ time: 2022-02-25 19:18:39.258961000 Z
+','2022-02-25 19:18:39.265432','comments')[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:29:11.390035"], ["id", 1]]
- [1m[36mPost Update (0.0ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:29:11.390390"], ["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:29:11.391260"], ["updated_at", "2021-08-19 23:29:11.391260"]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.0ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2021-08-19 23:29:11.391968"], ["updated_at", "2021-08-19 23:29:11.391968"]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
- [1m[36mPost Update (0.0ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-19 23:29:11.308109"], ["id", 1]]
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:29:11.384159"], ["updated_at", "2021-08-19 23:29:11.384159"]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-----------------------------------------
-ActiveSnapshotTest: test_exposes_version
-----------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------------
-ActiveSnapshotTest: test_exposes_main_module
---------------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_relationships
-------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_restore_item!
-------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-----------------------------------
-SnapshotItemTest: test_validations
-----------------------------------
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------
-SnapshotItemTest: test_object
------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
SnapshotsConcernTest: test_create_snapshot!
-------------------------------------------
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2021-08-19 23:29:11.411538"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.4ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:18:39.272765"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
+ utc: 2022-02-25 19:18:38.895863000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:11.308109000 Z
+ time: 2022-02-25 19:18:38.895863000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
+ utc: 2022-02-25 19:18:38.895863000 Z
zone: *1
- time: 2021-08-19 23:29:11.308109000 Z
-','2021-08-19 23:29:11.413742',NULL)[0m
+ time: 2022-02-25 19:18:38.895863000 Z
+','2022-02-25 19:18:39.276423',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:11.415146"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:18:39.278218"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
+ utc: 2022-02-25 19:18:38.895863000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:11.308109000 Z
+ time: 2022-02-25 19:18:38.895863000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
+ utc: 2022-02-25 19:18:38.895863000 Z
zone: *1
- time: 2021-08-19 23:29:11.308109000 Z
-','2021-08-19 23:29:11.417040',NULL)[0m
+ time: 2022-02-25 19:18:38.895863000 Z
+','2022-02-25 19:18:39.280872',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:11.418345"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:18:39.282819"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
+ utc: 2022-02-25 19:18:38.895863000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:11.308109000 Z
+ time: 2022-02-25 19:18:38.895863000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:11.308109000 Z
+ utc: 2022-02-25 19:18:38.895863000 Z
zone: *1
- time: 2021-08-19 23:29:11.308109000 Z
-','2021-08-19 23:29:11.420235',NULL)[0m
+ time: 2022-02-25 19:18:38.895863000 Z
+','2022-02-25 19:18:39.285362',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
SnapshotsConcernTest: test_has_snapshot_children
------------------------------------------------
- [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
SnapshotsConcernTest: test_relationships
----------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
-InstallGeneratorTest: test_should_add_migration
------------------------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
- [1m[35m (1.4ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+--------------------------------------------
+ActiveSnapshotTest: test_exposes_main_module
+--------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------
+ActiveSnapshotTest: test_exposes_version
+----------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-------------------------------------------
+ActiveSnapshotTest: test_snapshot_lifecycle
+-------------------------------------------
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:18:39.294715"], ["updated_at", "2022-02-25 19:18:39.294715"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:18:39.297819"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:18:38.895863000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:18:38.895863000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:18:38.895863000 Z
+ zone: *1
+ time: 2022-02-25 19:18:38.895863000 Z
+','2022-02-25 19:18:39.301421',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: foo
+post_id: 1
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:18:39.294715000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:18:39.294715000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:18:39.294715000 Z
+ zone: *1
+ time: 2022-02-25 19:18:39.294715000 Z
+','2022-02-25 19:18:39.301421','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:18:39.302761"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:18:39.303707"], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:18:39.305622"], ["updated_at", "2022-02-25 19:18:39.305622"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:18:39.306646"], ["updated_at", "2022-02-25 19:18:39.306646"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
+ [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:18:38.895863"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:18:39.294715"], ["updated_at", "2022-02-25 19:18:39.294715"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------
+SnapshotItemTest: test_object
+-----------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_relationships
+------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------
+SnapshotItemTest: test_validations
+----------------------------------
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[35m (1.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.5ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
[1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
- [1m[35m (1.8ms)[0m [1m[31mDELETE FROM posts;[0m
- [1m[35m (1.2ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
- [1m[35m (1.1ms)[0m [1m[31mDELETE FROM snapshots;[0m
- [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
- [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
- [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[35m (6.7ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-19 23:29:21.079132"], ["updated_at", "2021-08-19 23:29:21.079132"]]
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:19:22.963999"], ["updated_at", "2022-02-25 19:19:22.963999"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:21.092194"]]
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:19:22.978887"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
id: 1
a: 1
b: 3
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:29:21.079132000 Z
+ utc: &1 2022-02-25 19:19:22.963999000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:21.079132000 Z
+ time: 2022-02-25 19:19:22.963999000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:29:21.079132000 Z
-','2021-08-19 23:29:21.107905',NULL)[0m
- [1m[36mTRANSACTION (1.0ms)[0m [1m[36mcommit transaction[0m
- [1m[36mPost Update (1.0ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
+ time: 2022-02-25 19:19:22.963999000 Z
+','2022-02-25 19:19:22.997867',NULL)[0m
+ [1m[36mTRANSACTION (0.9ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Update (0.8ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.4ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:21.113375"]]
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:19:23.002578"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-19 23:29:21.079132000 Z
+ utc: &1 2022-02-25 19:19:22.963999000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:21.079132000 Z
+ time: 2022-02-25 19:19:22.963999000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-19 23:29:21.079132000 Z
-','2021-08-19 23:29:21.117615',NULL)[0m
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ time: 2022-02-25 19:19:22.963999000 Z
+','2022-02-25 19:19:23.006416',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------------
+ActiveSnapshotTest: test_exposes_main_module
+--------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
ActiveSnapshotTest: test_exposes_version
----------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
ActiveSnapshotTest: test_snapshot_lifecycle
-------------------------------------------
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.2ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:29:21.148886"], ["updated_at", "2021-08-19 23:29:21.148886"]]
+ [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:19:23.043351"], ["updated_at", "2022-02-25 19:19:23.043351"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:21.151063"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:19:23.046474"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:21.079132000 Z
+ time: 2022-02-25 19:19:22.963999000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: *1
- time: 2021-08-19 23:29:21.079132000 Z
-','2021-08-19 23:29:21.153591',NULL),(NULL,3,'Comment',1,'---
+ time: 2022-02-25 19:19:22.963999000 Z
+','2022-02-25 19:19:23.049655',NULL),(NULL,3,'Comment',1,'---
id: 1
content: foo
post_id: 1
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.148886000 Z
+ utc: 2022-02-25 19:19:23.043351000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:21.148886000 Z
+ time: 2022-02-25 19:19:23.043351000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.148886000 Z
+ utc: 2022-02-25 19:19:23.043351000 Z
zone: *1
- time: 2021-08-19 23:29:21.148886000 Z
-','2021-08-19 23:29:21.153591','comments')[0m
+ time: 2022-02-25 19:19:23.043351000 Z
+','2022-02-25 19:19:23.049655','comments')[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:29:21.154558"], ["id", 1]]
- [1m[36mPost Update (0.0ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-20 23:29:21.154916"], ["id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:19:23.050847"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:19:23.051327"], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:29:21.155758"], ["updated_at", "2021-08-19 23:29:21.155758"]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:19:23.052418"], ["updated_at", "2022-02-25 19:19:23.052418"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.0ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2021-08-19 23:29:21.156425"], ["updated_at", "2021-08-19 23:29:21.156425"]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:19:23.053323"], ["updated_at", "2022-02-25 19:19:23.053323"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-19 23:29:21.079132"], ["id", 1]]
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2021-08-19 23:29:21.148886"], ["updated_at", "2021-08-19 23:29:21.148886"]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:19:22.963999"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:19:23.043351"], ["updated_at", "2022-02-25 19:19:23.043351"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:19:23.069046"], ["updated_at", "2022-02-25 19:19:23.069046"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:19:23.070836"], ["updated_at", "2022-02-25 19:19:23.070836"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:19:23.073031"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:19:23.069046000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:19:23.069046000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:19:23.069046000 Z
+','2022-02-25 19:19:23.078150',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: Example comment
+post_id: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:19:23.070836000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:19:23.070836000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:19:23.070836000 Z
+ zone: *1
+ time: 2022-02-25 19:19:23.070836000 Z
+','2022-02-25 19:19:23.078150','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+------------------------------
+SnapshotTest: test_validations
+------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.4ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:19:23.094599"], ["updated_at", "2022-02-25 19:19:23.094599"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:19:23.097768"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'ParentWithoutChildren',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:19:23.094599000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:19:23.094599000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:19:23.094599000 Z
+','2022-02-25 19:19:23.100095',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ?, "updated_at" = ? WHERE "posts"."id" = ?[0m [["a", 9], ["b", 9], ["updated_at", "2022-02-25 19:19:23.101221"], ["id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------
+SnapshotTest: test_restore
+--------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------------
-ActiveSnapshotTest: test_exposes_main_module
---------------------------------------------
+--------------------------------
+SnapshotTest: test_relationships
+--------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_fetch_reified_items
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_build_snapshot_item
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
SnapshotsConcernTest: test_has_snapshot_children
------------------------------------------------
- [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
SnapshotsConcernTest: test_create_snapshot!
-------------------------------------------
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2021-08-19 23:29:21.176506"]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.5ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:19:23.125570"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:21.079132000 Z
+ time: 2022-02-25 19:19:22.963999000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: *1
- time: 2021-08-19 23:29:21.079132000 Z
-','2021-08-19 23:29:21.179444',NULL)[0m
+ time: 2022-02-25 19:19:22.963999000 Z
+','2022-02-25 19:19:23.130331',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:21.182276"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:19:23.132665"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:21.079132000 Z
+ time: 2022-02-25 19:19:22.963999000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: *1
- time: 2021-08-19 23:29:21.079132000 Z
-','2021-08-19 23:29:21.185087',NULL)[0m
+ time: 2022-02-25 19:19:22.963999000 Z
+','2022-02-25 19:19:23.136079',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2021-08-19 23:29:21.186765"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:19:23.138146"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-19 23:29:21.079132000 Z
+ time: 2022-02-25 19:19:22.963999000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-19 23:29:21.079132000 Z
+ utc: 2022-02-25 19:19:22.963999000 Z
zone: *1
- time: 2021-08-19 23:29:21.079132000 Z
-','2021-08-19 23:29:21.189732',NULL)[0m
+ time: 2022-02-25 19:19:22.963999000 Z
+','2022-02-25 19:19:23.141546',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
SnapshotsConcernTest: test_relationships
----------------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
-InstallGeneratorTest: test_should_add_migration
------------------------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------
-SnapshotTest: test_fetch_reified_items
---------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------
-SnapshotTest: test_relationships
---------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------
-SnapshotTest: test_build_snapshot_item
---------------------------------------
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------
-SnapshotTest: test_restore
---------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
- [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.4ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------
-SnapshotTest: test_validations
-------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------
-SnapshotTest: test_metadata
----------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------
-SnapshotItemTest: test_object
------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------
SnapshotItemTest: test_validations
----------------------------------
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
@@ -1349,183 +2112,205 @@
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------
+SnapshotItemTest: test_object
+-----------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------
SnapshotItemTest: test_relationships
------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_restore_item!
-------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
- [1m[35m (2.4ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (0.7ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[36mActiveRecord::InternalMetadata Load (1.3ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
- [1m[35m (1.2ms)[0m [1m[31mDELETE FROM posts;[0m
- [1m[35m (1.3ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
- [1m[35m (3.1ms)[0m [1m[31mDELETE FROM snapshots;[0m
- [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
- [1m[35m (1.8ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
- [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+-----------------------------------------------
+InstallGeneratorTest: test_should_add_migration
+-----------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[35m (1.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
+ [1m[35m (6.6ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
+ [1m[35m (1.0ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.2ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-27 20:45:59.108921"], ["updated_at", "2021-08-27 20:45:59.108921"]]
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:20:35.789310"], ["updated_at", "2022-02-25 19:20:35.789310"]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:45:59.125328"]]
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.4ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:20:35.803837"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.5ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.6ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (0.1ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
id: 1
a: 1
b: 3
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-27 20:45:59.108921000 Z
+ utc: &1 2022-02-25 19:20:35.789310000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:45:59.108921000 Z
+ time: 2022-02-25 19:20:35.789310000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-27 20:45:59.108921000 Z
-','2021-08-27 20:45:59.147514',NULL)[0m
+ time: 2022-02-25 19:20:35.789310000 Z
+','2022-02-25 19:20:35.822170',NULL)[0m
[1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Update (0.8ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:45:59.151704"]]
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:20:35.826497"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-27 20:45:59.108921000 Z
+ utc: &1 2022-02-25 19:20:35.789310000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:45:59.108921000 Z
+ time: 2022-02-25 19:20:35.789310000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-27 20:45:59.108921000 Z
-','2021-08-27 20:45:59.154831',NULL)[0m
- [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ time: 2022-02-25 19:20:35.789310000 Z
+','2022-02-25 19:20:35.830224',NULL)[0m
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------
+InstallGeneratorTest: test_should_add_migration
+-----------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
SnapshotsConcernTest: test_create_snapshot!
-------------------------------------------
[1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (1.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2021-08-27 20:45:59.199189"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:20:35.871008"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:45:59.108921000 Z
+ time: 2022-02-25 19:20:35.789310000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: *1
- time: 2021-08-27 20:45:59.108921000 Z
-','2021-08-27 20:45:59.203510',NULL)[0m
+ time: 2022-02-25 19:20:35.789310000 Z
+','2022-02-25 19:20:35.874056',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:45:59.205310"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:20:35.875642"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:45:59.108921000 Z
+ time: 2022-02-25 19:20:35.789310000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: *1
- time: 2021-08-27 20:45:59.108921000 Z
-','2021-08-27 20:45:59.207556',NULL)[0m
+ time: 2022-02-25 19:20:35.789310000 Z
+','2022-02-25 19:20:35.877986',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:45:59.209081"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:20:35.879416"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:45:59.108921000 Z
+ time: 2022-02-25 19:20:35.789310000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: *1
- time: 2021-08-27 20:45:59.108921000 Z
-','2021-08-27 20:45:59.211345',NULL)[0m
+ time: 2022-02-25 19:20:35.789310000 Z
+','2022-02-25 19:20:35.883477',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
SnapshotsConcernTest: test_relationships
----------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
SnapshotsConcernTest: test_has_snapshot_children
------------------------------------------------
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------
+SnapshotItemTest: test_object
+-----------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------
SnapshotItemTest: test_relationships
------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------
SnapshotItemTest: test_validations
----------------------------------
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
@@ -1534,134 +2319,332 @@
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------
-SnapshotItemTest: test_object
------------------------------
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_fetch_reified_items
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------
+SnapshotTest: test_build_snapshot_item
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_restore_item!
-------------------------------------
+------------------------------
+SnapshotTest: test_validations
+------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------
+SnapshotTest: test_relationships
+--------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.4ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:20:35.931214"], ["updated_at", "2022-02-25 19:20:35.931214"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:20:35.934708"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'ParentWithoutChildren',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:20:35.931214000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:20:35.931214000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:20:35.931214000 Z
+','2022-02-25 19:20:35.936688',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ?, "updated_at" = ? WHERE "posts"."id" = ?[0m [["a", 9], ["b", 9], ["updated_at", "2022-02-25 19:20:35.937620"], ["id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------
+SnapshotTest: test_restore
+--------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.4ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:20:35.950273"], ["updated_at", "2022-02-25 19:20:35.950273"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:20:35.954355"], ["updated_at", "2022-02-25 19:20:35.954355"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:20:35.956695"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:20:35.950273000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:20:35.950273000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:20:35.950273000 Z
+','2022-02-25 19:20:35.961347',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: Example comment
+post_id: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:20:35.954355000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:20:35.954355000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:20:35.954355000 Z
+ zone: *1
+ time: 2022-02-25 19:20:35.954355000 Z
+','2022-02-25 19:20:35.961347','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
-InstallGeneratorTest: test_should_add_migration
------------------------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
ActiveSnapshotTest: test_snapshot_lifecycle
-------------------------------------------
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-27 20:45:59.248858"], ["updated_at", "2021-08-27 20:45:59.248858"]]
+ [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:20:35.967145"], ["updated_at", "2022-02-25 19:20:35.967145"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:45:59.251463"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:20:35.970506"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:45:59.108921000 Z
+ time: 2022-02-25 19:20:35.789310000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.108921000 Z
+ utc: 2022-02-25 19:20:35.789310000 Z
zone: *1
- time: 2021-08-27 20:45:59.108921000 Z
-','2021-08-27 20:45:59.254446',NULL),(NULL,3,'Comment',1,'---
+ time: 2022-02-25 19:20:35.789310000 Z
+','2022-02-25 19:20:35.974518',NULL),(NULL,3,'Comment',1,'---
id: 1
content: foo
post_id: 1
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.248858000 Z
+ utc: 2022-02-25 19:20:35.967145000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:45:59.248858000 Z
+ time: 2022-02-25 19:20:35.967145000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:45:59.248858000 Z
+ utc: 2022-02-25 19:20:35.967145000 Z
zone: *1
- time: 2021-08-27 20:45:59.248858000 Z
-','2021-08-27 20:45:59.254446','comments')[0m
+ time: 2022-02-25 19:20:35.967145000 Z
+','2022-02-25 19:20:35.974518','comments')[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-28 20:45:59.255601"], ["id", 1]]
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-28 20:45:59.256049"], ["id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:20:35.976249"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:20:35.987493"], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-27 20:45:59.257086"], ["updated_at", "2021-08-27 20:45:59.257086"]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:20:35.989308"], ["updated_at", "2022-02-25 19:20:35.989308"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2021-08-27 20:45:59.257919"], ["updated_at", "2021-08-27 20:45:59.257919"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:20:35.990552"], ["updated_at", "2022-02-25 19:20:35.990552"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
- [1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-27 20:45:59.108921"], ["id", 1]]
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2021-08-27 20:45:59.248858"], ["updated_at", "2021-08-27 20:45:59.248858"]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:20:35.789310"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:20:35.967145"], ["updated_at", "2022-02-25 19:20:35.967145"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------------------
ActiveSnapshotTest: test_exposes_main_module
--------------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
ActiveSnapshotTest: test_exposes_version
----------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[35m (1.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
+ [1m[35m (6.6ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
+ [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
+ [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------
-SnapshotTest: test_build_snapshot_item
---------------------------------------
+ [1m[36mPost Create (0.4ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:21:38.597166"], ["updated_at", "2022-02-25 19:21:38.597166"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:21:38.612142"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
+id: 1
+a: 1
+b: 3
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:21:38.597166000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.597166000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:21:38.597166000 Z
+','2022-02-25 19:21:38.630816',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Update (0.8ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:21:38.635374"]]
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:21:38.597166000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.597166000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:21:38.597166000 Z
+','2022-02-25 19:21:38.639020',NULL)[0m
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+-----------------------------
+SnapshotItemTest: test_object
+-----------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_relationships
+------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------
+SnapshotItemTest: test_validations
+----------------------------------
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------------
SnapshotTest: test_fetch_reified_items
--------------------------------------
@@ -1672,413 +2655,712 @@
--------------------------
SnapshotTest: test_restore
--------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
[1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------
-SnapshotTest: test_metadata
----------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
---------------------------------
-SnapshotTest: test_relationships
---------------------------------
- [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:21:38.700920"], ["updated_at", "2022-02-25 19:21:38.700920"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:21:38.704492"], ["updated_at", "2022-02-25 19:21:38.704492"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:21:38.706644"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:21:38.700920000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.700920000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:21:38.700920000 Z
+','2022-02-25 19:21:38.712301',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: Example comment
+post_id: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.704492000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.704492000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.704492000 Z
+ zone: *1
+ time: 2022-02-25 19:21:38.704492000 Z
+','2022-02-25 19:21:38.712301','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------
SnapshotTest: test_validations
------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[35m (1.5ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (0.8ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
- [1m[35m (1.4ms)[0m [1m[31mDELETE FROM posts;[0m
- [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
- [1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
- [1m[35m (0.6ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
- [1m[35m (0.9ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
- [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.2ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-27 20:46:32.110903"], ["updated_at", "2021-08-27 20:46:32.110903"]]
- [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+--------------------------------------
+SnapshotTest: test_build_snapshot_item
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:21:38.727758"], ["updated_at", "2022-02-25 19:21:38.727758"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:21:38.730675"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:46:32.123411"]]
- [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+--------------------------------
+SnapshotTest: test_relationships
+--------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------------
+ActiveSnapshotTest: test_exposes_main_module
+--------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------
+ActiveSnapshotTest: test_exposes_version
+----------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-------------------------------------------
+ActiveSnapshotTest: test_snapshot_lifecycle
+-------------------------------------------
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:21:38.738636"], ["updated_at", "2022-02-25 19:21:38.738636"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:21:38.742989"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.597166000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: *1
+ time: 2022-02-25 19:21:38.597166000 Z
+','2022-02-25 19:21:38.746771',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: foo
+post_id: 1
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.738636000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.738636000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.738636000 Z
+ zone: *1
+ time: 2022-02-25 19:21:38.738636000 Z
+','2022-02-25 19:21:38.746771','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:21:38.748173"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:21:38.748703"], ["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:21:38.749982"], ["updated_at", "2022-02-25 19:21:38.749982"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:21:38.750934"], ["updated_at", "2022-02-25 19:21:38.750934"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
+ [1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:21:38.597166"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:21:38.738636"], ["updated_at", "2022-02-25 19:21:38.738636"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------
+InstallGeneratorTest: test_should_add_migration
+-----------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------------------
+SnapshotsConcernTest: test_has_snapshot_children
+------------------------------------------------
+ [1m[36mPost Load (0.3ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------
+SnapshotsConcernTest: test_relationships
+----------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-------------------------------------------
+SnapshotsConcernTest: test_create_snapshot!
+-------------------------------------------
+ [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.4ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:21:38.788191"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (1.4ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.597166000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: *1
+ time: 2022-02-25 19:21:38.597166000 Z
+','2022-02-25 19:21:38.792986',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:21:38.795333"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.597166000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: *1
+ time: 2022-02-25 19:21:38.597166000 Z
+','2022-02-25 19:21:38.798731',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:21:38.800642"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
+id: 1
+a: 2
+b: 4
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:21:38.597166000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:21:38.597166000 Z
+ zone: *1
+ time: 2022-02-25 19:21:38.597166000 Z
+','2022-02-25 19:21:38.803548',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[35m (1.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
+ [1m[36mActiveRecord::SchemaMigration Pluck (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
[1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
- [1m[35m (1.2ms)[0m [1m[31mDELETE FROM posts;[0m
- [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
+ [1m[35m (6.5ms)[0m [1m[31mDELETE FROM posts;[0m
+ [1m[35m (0.8ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
[1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshots;[0m
[1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
[1m[35m (0.8ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
- [1m[35m (0.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
+ [1m[35m (0.9ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.2ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-27 20:46:36.394557"], ["updated_at", "2021-08-27 20:46:36.394557"]]
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2022-02-25 19:22:05.476133"], ["updated_at", "2022-02-25 19:22:05.476133"]]
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:46:36.407070"]]
- [1m[36mTRANSACTION (0.8ms)[0m [1m[36mcommit transaction[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (1.5ms)[0m [1m[34mSELECT sqlite_version(*)[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT "schema_migrations"."version" FROM "schema_migrations" ORDER BY "schema_migrations"."version" ASC[0m
- [1m[36mActiveRecord::InternalMetadata Load (0.1ms)[0m [1m[34mSELECT "ar_internal_metadata".* FROM "ar_internal_metadata" WHERE "ar_internal_metadata"."key" = ? LIMIT ?[0m [["key", "environment"], ["LIMIT", 1]]
- [1m[35m (1.3ms)[0m [1m[31mDELETE FROM posts;[0m
- [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'posts';[0m
- [1m[35m (0.7ms)[0m [1m[31mDELETE FROM snapshots;[0m
- [1m[35m (0.7ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshots';[0m
- [1m[35m (0.7ms)[0m [1m[31mDELETE FROM snapshot_items;[0m
- [1m[35m (0.1ms)[0m [1m[33mUPDATE `sqlite_sequence` SET `seq` = 0 WHERE `name` = 'snapshot_items';[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."a" = ? AND "posts"."b" = ? LIMIT ?[0m [["a", 1], ["b", 3], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mPost Create (0.2ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 3], ["created_at", "2021-08-27 20:46:45.337718"], ["updated_at", "2021-08-27 20:46:45.337718"]]
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:46:45.350182"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:22:05.490924"]]
[1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[35m (0.0ms)[0m [1m[34mSELECT sqlite_version(*)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,1,'Post',1,'---
id: 1
a: 1
b: 3
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-27 20:46:45.337718000 Z
+ utc: &1 2022-02-25 19:22:05.476133000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:46:45.337718000 Z
+ time: 2022-02-25 19:22:05.476133000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-27 20:46:45.337718000 Z
-','2021-08-27 20:46:45.366180',NULL)[0m
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
- [1m[36mPost Update (0.7ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
+ time: 2022-02-25 19:22:05.476133000 Z
+','2022-02-25 19:22:05.509251',NULL)[0m
+ [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mPost Update (0.8ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 2], ["b", 4], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:46:45.369589"]]
- [1m[36mTRANSACTION (0.7ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "v2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:22:05.513970"]]
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.3ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,2,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: &1 2021-08-27 20:46:45.337718000 Z
+ utc: &1 2022-02-25 19:22:05.476133000 Z
zone: &2 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:46:45.337718000 Z
+ time: 2022-02-25 19:22:05.476133000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
utc: *1
zone: *2
- time: 2021-08-27 20:46:45.337718000 Z
-','2021-08-27 20:46:45.372362',NULL)[0m
- [1m[36mTRANSACTION (0.5ms)[0m [1m[36mcommit transaction[0m
+ time: 2022-02-25 19:22:05.476133000 Z
+','2022-02-25 19:22:05.517708',NULL)[0m
+ [1m[36mTRANSACTION (0.6ms)[0m [1m[36mcommit transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
+---------------------------
+SnapshotTest: test_metadata
+---------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.2ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------------------
-InstallGeneratorTest: test_should_add_migration
------------------------------------------------
+--------------------------------------
+SnapshotTest: test_fetch_reified_items
+--------------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------
SnapshotTest: test_relationships
--------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------
+SnapshotTest: test_validations
+------------------------------
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------------------------
+SnapshotTest: test_single_model_snapshots_without_children
+----------------------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Create (0.3ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:22:05.566200"], ["updated_at", "2022-02-25 19:22:05.566200"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "ParentWithoutChildren"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:22:05.569864"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'ParentWithoutChildren',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:22:05.566200000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:22:05.566200000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:22:05.566200000 Z
+','2022-02-25 19:22:05.572027',NULL)[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mParentWithoutChildren Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ?, "updated_at" = ? WHERE "posts"."id" = ?[0m [["a", 9], ["b", 9], ["updated_at", "2022-02-25 19:22:05.572967"], ["id", 2]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "ParentWithoutChildren"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------
SnapshotTest: test_restore
--------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
- [1m[36mPost Update (0.2ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
--------------------------------------
SnapshotTest: test_build_snapshot_item
--------------------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.3ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------
-SnapshotTest: test_validations
-------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" IS NULL AND "snapshots"."item_id" IS NULL AND "snapshots"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "random"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+-----------------------------------------------------
+SnapshotTest: test_fetch_reified_items_with_sti_class
+-----------------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mSubPost Create (0.5ms)[0m [1m[32mINSERT INTO "posts" ("a", "b", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["a", 1], ["b", 2], ["created_at", "2022-02-25 19:22:05.589975"], ["updated_at", "2022-02-25 19:22:05.589975"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.2ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "Example comment"], ["post_id", 2], ["created_at", "2022-02-25 19:22:05.594950"], ["updated_at", "2022-02-25 19:22:05.594950"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "v1"], ["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 2], ["identifier", "v1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:22:05.597775"]]
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mSubPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 2], ["LIMIT", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mNote Load (0.1ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 2]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'SubPost',2,'---
+id: 2
+a: 1
+b: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: &1 2022-02-25 19:22:05.589975000 Z
+ zone: &2 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:22:05.589975000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: *1
+ zone: *2
+ time: 2022-02-25 19:22:05.589975000 Z
+','2022-02-25 19:22:05.602664',NULL),(NULL,3,'Comment',1,'---
+id: 1
+content: Example comment
+post_id: 2
+created_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:22:05.594950000 Z
+ zone: &1 !ruby/object:ActiveSupport::TimeZone
+ name: Etc/UTC
+ time: 2022-02-25 19:22:05.594950000 Z
+updated_at: !ruby/object:ActiveSupport::TimeWithZone
+ utc: 2022-02-25 19:22:05.594950000 Z
+ zone: *1
+ time: 2022-02-25 19:22:05.594950000 Z
+','2022-02-25 19:22:05.602664','comments')[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::Snapshot Load (0.0ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 2], ["item_type", "Post"], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Load (0.1ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------
-SnapshotTest: test_fetch_reified_items
---------------------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------
-SnapshotTest: test_metadata
----------------------------
- [1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
---------------------------------------------
-ActiveSnapshotTest: test_exposes_main_module
---------------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-----------------------------------------
-ActiveSnapshotTest: test_exposes_version
-----------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
ActiveSnapshotTest: test_snapshot_lifecycle
-------------------------------------------
[1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-27 20:46:45.427588"], ["updated_at", "2021-08-27 20:46:45.427588"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mComment Create (0.3ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:22:05.609561"], ["updated_at", "2022-02-25 19:22:05.609561"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "snapshot-1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.2ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:46:45.430393"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "snapshot-1"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:22:05.612792"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:46:45.337718000 Z
+ time: 2022-02-25 19:22:05.476133000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: *1
- time: 2021-08-27 20:46:45.337718000 Z
-','2021-08-27 20:46:45.433489',NULL),(NULL,3,'Comment',1,'---
+ time: 2022-02-25 19:22:05.476133000 Z
+','2022-02-25 19:22:05.616971',NULL),(NULL,3,'Comment',1,'---
id: 1
content: foo
post_id: 1
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.427588000 Z
+ utc: 2022-02-25 19:22:05.609561000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:46:45.427588000 Z
+ time: 2022-02-25 19:22:05.609561000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.427588000 Z
+ utc: 2022-02-25 19:22:05.609561000 Z
zone: *1
- time: 2021-08-27 20:46:45.427588000 Z
-','2021-08-27 20:46:45.433489','comments')[0m
+ time: 2022-02-25 19:22:05.609561000 Z
+','2022-02-25 19:22:05.616971','comments')[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-28 20:46:45.434798"], ["id", 1]]
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-28 20:46:45.435324"], ["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:22:05.618983"], ["id", 1]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-26 19:22:05.620010"], ["id", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2021-08-27 20:46:45.436673"], ["updated_at", "2021-08-27 20:46:45.436673"]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:22:05.621430"], ["updated_at", "2022-02-25 19:22:05.621430"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2021-08-27 20:46:45.437717"], ["updated_at", "2021-08-27 20:46:45.437717"]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?)[0m [["content", "bar"], ["post_id", 1], ["created_at", "2022-02-25 19:22:05.622705"], ["updated_at", "2022-02-25 19:22:05.622705"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 3]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ?[0m [["id", 1]]
[1m[36mComment Load (0.1ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."id" = ?[0m [["id", 1]]
[1m[36mComment Destroy (0.1ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 2]]
[1m[36mComment Destroy (0.0ms)[0m [1m[31mDELETE FROM "comments" WHERE "comments"."id" = ?[0m [["id", 3]]
- [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2021-08-27 20:46:45.337718"], ["id", 1]]
- [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2021-08-27 20:46:45.427588"], ["updated_at", "2021-08-27 20:46:45.427588"]]
+ [1m[36mPost Update (0.1ms)[0m [1m[33mUPDATE "posts" SET "updated_at" = ? WHERE "posts"."id" = ?[0m [["updated_at", "2022-02-25 19:22:05.476133"], ["id", 1]]
+ [1m[36mComment Create (0.1ms)[0m [1m[32mINSERT INTO "comments" ("id", "content", "post_id", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?)[0m [["id", 1], ["content", "foo"], ["post_id", 1], ["created_at", "2022-02-25 19:22:05.609561"], ["updated_at", "2022-02-25 19:22:05.609561"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
- [1m[35m (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
+ [1m[36mActiveSnapshot::SnapshotItem Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshot_items"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.0ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots"[0m
+ [1m[36mActiveSnapshot::Snapshot Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "snapshots" WHERE "snapshots"."identifier" = ?[0m [["identifier", "snapshot-1"]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[35m (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mComment Count (0.1ms)[0m [1m[34mSELECT COUNT(*) FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.4ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+--------------------------------------------
+ActiveSnapshotTest: test_exposes_main_module
+--------------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+----------------------------------------
+ActiveSnapshotTest: test_exposes_version
+----------------------------------------
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------------
SnapshotItemTest: test_relationships
------------------------------------
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------
-SnapshotItemTest: test_restore_item!
-------------------------------------
+-----------------------------
+SnapshotItemTest: test_object
+-----------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
- [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
- [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mTRANSACTION (0.2ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[36mbegin transaction[0m
----------------------------------
SnapshotItemTest: test_validations
----------------------------------
- [1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mActiveSnapshot::SnapshotItem Exists? (0.2ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_type" IS NULL LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" IS NULL AND "snapshot_items"."snapshot_id" IS NULL AND "snapshot_items"."item_id" IS NULL LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" WHERE "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Post"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_id" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_type" = ? LIMIT ?[0m [["item_id", 1], ["snapshot_id", 1], ["item_type", "Foobar"], ["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshot_items" WHERE "snapshot_items"."item_type" = ? AND "snapshot_items"."snapshot_id" = ? AND "snapshot_items"."item_id" = ? LIMIT ?[0m [["item_type", "Foobar"], ["snapshot_id", 1], ["item_id", 1], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
------------------------------
-SnapshotItemTest: test_object
------------------------------
+------------------------------------
+SnapshotItemTest: test_restore_item!
+------------------------------------
[1m[36mActiveSnapshot::Snapshot Load (0.1ms)[0m [1m[34mSELECT "snapshots".* FROM "snapshots" ORDER BY "snapshots"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mActiveSnapshot::SnapshotItem Load (0.0ms)[0m [1m[34mSELECT "snapshot_items".* FROM "snapshot_items" WHERE "snapshot_items"."snapshot_id" = ?[0m [["snapshot_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mPost Update (0.3ms)[0m [1m[33mUPDATE "posts" SET "a" = ?, "b" = ? WHERE "posts"."id" = ?[0m [["a", 1], ["b", 3], ["id", 1]]
+ [1m[36mTRANSACTION (0.2ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.5ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------------
-SnapshotsConcernTest: test_has_snapshot_children
-------------------------------------------------
- [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
- [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
----------------------------------------
SnapshotsConcernTest: test_relationships
----------------------------------------
- [1m[36mTRANSACTION (0.0ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
-------------------------------------------
SnapshotsConcernTest: test_create_snapshot!
-------------------------------------------
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.2ms)[0m [1m[34mSELECT "posts".* FROM "posts" ORDER BY "posts"."id" ASC LIMIT ?[0m [["LIMIT", 1]]
[1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 1"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.3ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2021-08-27 20:46:45.472428"]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
- [1m[36mPost Load (0.1ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.4ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 1"], ["metadata", "---\n:foo: :bar\n"], ["created_at", "2022-02-25 19:22:05.657495"]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.2ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,3,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:46:45.337718000 Z
+ time: 2022-02-25 19:22:05.476133000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: *1
- time: 2021-08-27 20:46:45.337718000 Z
-','2021-08-27 20:46:45.475771',NULL)[0m
+ time: 2022-02-25 19:22:05.476133000 Z
+','2022-02-25 19:22:05.661726',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 2"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:46:45.477983"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 2"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:22:05.663723"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
- [1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,4,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:46:45.337718000 Z
+ time: 2022-02-25 19:22:05.476133000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: *1
- time: 2021-08-27 20:46:45.337718000 Z
-','2021-08-27 20:46:45.480667',NULL)[0m
+ time: 2022-02-25 19:22:05.476133000 Z
+','2022-02-25 19:22:05.666294',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
- [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2021-08-27 20:46:45.482456"]]
+ [1m[36mActiveSnapshot::Snapshot Create (0.1ms)[0m [1m[32mINSERT INTO "snapshots" ("item_type", "item_id", "identifier", "metadata", "created_at") VALUES (?, ?, ?, ?, ?)[0m [["item_type", "Post"], ["item_id", 1], ["identifier", "foobar 3"], ["metadata", "--- {}\n"], ["created_at", "2022-02-25 19:22:05.679118"]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" WHERE "posts"."id" = ? LIMIT ?[0m [["id", 1], ["LIMIT", 1]]
[1m[36mComment Load (0.0ms)[0m [1m[34mSELECT "comments".* FROM "comments" WHERE "comments"."post_id" = ?[0m [["post_id", 1]]
[1m[36mNote Load (0.0ms)[0m [1m[34mSELECT "notes".* FROM "notes" WHERE "notes"."post_id" = ?[0m [["post_id", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::SnapshotItem Create Many (0.1ms)[0m [1m[32mINSERT INTO "snapshot_items" ("id","snapshot_id","item_type","item_id","object","created_at","child_group_name") VALUES (NULL,5,'Post',1,'---
id: 1
a: 2
b: 4
created_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: &1 !ruby/object:ActiveSupport::TimeZone
name: Etc/UTC
- time: 2021-08-27 20:46:45.337718000 Z
+ time: 2022-02-25 19:22:05.476133000 Z
updated_at: !ruby/object:ActiveSupport::TimeWithZone
- utc: 2021-08-27 20:46:45.337718000 Z
+ utc: 2022-02-25 19:22:05.476133000 Z
zone: *1
- time: 2021-08-27 20:46:45.337718000 Z
-','2021-08-27 20:46:45.485020',NULL)[0m
+ time: 2022-02-25 19:22:05.476133000 Z
+','2022-02-25 19:22:05.682462',NULL)[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mRELEASE SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.0ms)[0m [1m[35mSAVEPOINT active_record_1[0m
[1m[36mActiveSnapshot::Snapshot Exists? (0.1ms)[0m [1m[34mSELECT 1 AS one FROM "snapshots" WHERE "snapshots"."identifier" = ? AND "snapshots"."item_id" = ? AND "snapshots"."item_type" = ? LIMIT ?[0m [["identifier", "foobar 3"], ["item_id", 1], ["item_type", "Post"], ["LIMIT", 1]]
[1m[36mTRANSACTION (0.0ms)[0m [1m[31mROLLBACK TO SAVEPOINT active_record_1[0m
[1m[36mTRANSACTION (0.3ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+------------------------------------------------
+SnapshotsConcernTest: test_has_snapshot_children
+------------------------------------------------
+ [1m[36mPost Load (0.3ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mPost Load (0.0ms)[0m [1m[34mSELECT "posts".* FROM "posts" LIMIT ?[0m [["LIMIT", 1]]
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m
+ [1m[36mTRANSACTION (0.0ms)[0m [1m[36mbegin transaction[0m
+-----------------------------------------------
+InstallGeneratorTest: test_should_add_migration
+-----------------------------------------------
+ [1m[36mTRANSACTION (0.1ms)[0m [1m[31mrollback transaction[0m