(2.2ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (112.5ms) DROP DATABASE IF EXISTS "indices_test"  (351.1ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (1.9ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (4.1ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (137.9ms) DROP DATABASE IF EXISTS "indices_test"  (316.8ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.1ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.3ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (148.8ms) DROP DATABASE IF EXISTS "indices_test"  (295.6ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.3ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (1.0ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.4ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (166.7ms) DROP DATABASE IF EXISTS "indices_test"  (285.2ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.8ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (1.4ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.5ms) SELECT version FROM "schema_migrations"  (6.0ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.5ms) ROLLBACK  (0.1ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (181.6ms) DROP DATABASE IF EXISTS "indices_test"  (306.6ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.1ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.3ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (182.6ms) DROP DATABASE IF EXISTS "indices_test"  (317.5ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.2ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.3ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (1.2ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (174.5ms) DROP DATABASE IF EXISTS "indices_test"  (298.5ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.2ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.3ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (177.8ms) DROP DATABASE IF EXISTS "indices_test"  (357.8ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.4ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.4ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.3ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (178.9ms) DROP DATABASE IF EXISTS "indices_test"  (319.6ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.3ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (178.7ms) DROP DATABASE IF EXISTS "indices_test"  (379.3ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.4ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------ ApiTest: test_hash ------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (160.6ms) DROP DATABASE IF EXISTS "indices_test"  (357.7ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.3ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.2ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (182.7ms) DROP DATABASE IF EXISTS "indices_test"  (367.9ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.6ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (178.8ms) DROP DATABASE IF EXISTS "indices_test"  (366.8ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.4ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.2ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (175.6ms) DROP DATABASE IF EXISTS "indices_test"  (381.1ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.6ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.4ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (182.7ms) DROP DATABASE IF EXISTS "indices_test"  (354.5ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (12.4ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (179.4ms) DROP DATABASE IF EXISTS "indices_test"  (359.9ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.4ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.5ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (108.9ms) DROP DATABASE IF EXISTS "indices_test"  (1944.0ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.4ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.3ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (181.5ms) DROP DATABASE IF EXISTS "indices_test"  (303.2ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.5ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.4ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (1.3ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (188.4ms) DROP DATABASE IF EXISTS "indices_test"  (350.7ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (3.7ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (1.3ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.5ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (6.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (121.3ms) DROP DATABASE IF EXISTS "indices_test"  (359.7ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (10.9ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (109.9ms) DROP DATABASE IF EXISTS "indices_test"  (1148.8ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.1ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.3ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (141.3ms) DROP DATABASE IF EXISTS "indices_test"  (270.0ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.4ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.9ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (1.1ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.4ms) SELECT version FROM "schema_migrations"  (0.3ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_truth -----------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- ApiTest: test_format --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (194.7ms) DROP DATABASE IF EXISTS "indices_test"  (276.8ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (2.7ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)  (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('0') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateProducts (20161104164148)  (0.2ms) BEGIN  (14.2ms) CREATE TABLE "products" ("id" serial primary key, "name" character varying, "category" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104164148"]]  (6.2ms) COMMIT ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (7.1ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'products' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname  ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 17:47:08.622440"], ["updated_at", "2016-11-04 17:47:08.622440"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.8ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.3ms) SAVEPOINT active_record_1 SQL (1.7ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:10:42.658875"], ["updated_at", "2016-11-04 18:10:42.658875"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:11:19.825308"], ["updated_at", "2016-11-04 18:11:19.825308"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:12:17.854116"], ["updated_at", "2016-11-04 18:12:17.854116"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.4ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:13:09.703085"], ["updated_at", "2016-11-04 18:13:09.703085"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:14:09.298165"], ["updated_at", "2016-11-04 18:14:09.298165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:14:31.508093"], ["updated_at", "2016-11-04 18:14:31.508093"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:15:02.784628"], ["updated_at", "2016-11-04 18:15:02.784628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:16:06.927144"], ["updated_at", "2016-11-04 18:16:06.927144"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:20:53.024588"], ["updated_at", "2016-11-04 18:20:53.024588"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:21:09.267397"], ["updated_at", "2016-11-04 18:21:09.267397"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:22:00.775509"], ["updated_at", "2016-11-04 18:22:00.775509"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (190.8ms) DROP DATABASE IF EXISTS "indices_test"  (417.7ms) CREATE DATABASE "indices_test" ENCODING = 'utf8' SQL (0.3ms) CREATE EXTENSION IF NOT EXISTS "plpgsql"  (3.6ms) CREATE TABLE "products" ("id" serial primary key, "name" character varying, "category" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  (1.4ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)   (0.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")  (0.3ms) SELECT version FROM "schema_migrations"  (0.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20161104164148') ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateShops (20161104182219)  (0.1ms) BEGIN  (6.7ms) CREATE TABLE "shops" ("id" serial primary key, "name" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104182219"]]  (0.5ms) COMMIT ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (2.6ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'products' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname   (2.2ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'shops' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.3ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:23:13.250403"], ["updated_at", "2016-11-04 18:23:13.250403"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.4ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:24:26.691727"], ["updated_at", "2016-11-04 18:24:26.691727"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:24:59.925114"], ["updated_at", "2016-11-04 18:24:59.925114"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:25:27.779758"], ["updated_at", "2016-11-04 18:25:27.779758"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (2.5ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)   (0.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateProducts (20161104164148)  (0.1ms) BEGIN  (2.5ms) CREATE TABLE "products" ("id" serial primary key, "name" character varying, "category" character varying, "shop_id" integer, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104164148"]]  (0.6ms) COMMIT Migrating to CreateShops (20161104182219)  (0.3ms) BEGIN  (2.0ms) CREATE TABLE "shops" ("id" serial primary key, "name" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104182219"]]  (0.5ms) COMMIT ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (1.7ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'products' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname   (1.3ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'shops' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:26:31.451992"], ["updated_at", "2016-11-04 18:26:31.451992"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:27:33.359464"], ["updated_at", "2016-11-04 18:27:33.359464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:28:19.922027"], ["updated_at", "2016-11-04 18:28:19.922027"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:29:15.860272"], ["updated_at", "2016-11-04 18:29:15.860272"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.4ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:32:24.474415"], ["updated_at", "2016-11-04 18:32:24.474415"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (13.1ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.4ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:34:58.631136"], ["updated_at", "2016-11-04 18:34:58.631136"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 18:35:03.798322"], ["updated_at", "2016-11-04 18:35:03.798322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (6.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (6.1ms) INSERT INTO "products" ("name", "category", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["created_at", "2016-11-04 19:48:33.124401"], ["updated_at", "2016-11-04 19:48:33.124401"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (2.0ms) ROLLBACK ActiveRecord::SchemaMigration Load (28.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.5ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.3ms) SAVEPOINT active_record_1 SQL (25.0ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:14:52.360404"], ["updated_at", "2016-11-06 16:14:52.360404"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:14:52.389217"], ["updated_at", "2016-11-06 16:14:52.389217"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:14:52.390544"], ["updated_at", "2016-11-06 16:14:52.390544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:14:52.391670"], ["updated_at", "2016-11-06 16:14:52.391670"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.0ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:15:20.200016"], ["updated_at", "2016-11-06 16:15:20.200016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:15:20.203305"], ["updated_at", "2016-11-06 16:15:20.203305"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:15:20.204501"], ["updated_at", "2016-11-06 16:15:20.204501"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:15:20.205679"], ["updated_at", "2016-11-06 16:15:20.205679"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:15:37.998970"], ["updated_at", "2016-11-06 16:15:37.998970"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:15:38.002130"], ["updated_at", "2016-11-06 16:15:38.002130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:15:38.003280"], ["updated_at", "2016-11-06 16:15:38.003280"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:15:38.004407"], ["updated_at", "2016-11-06 16:15:38.004407"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:16:04.258282"], ["updated_at", "2016-11-06 16:16:04.258282"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:16:04.261662"], ["updated_at", "2016-11-06 16:16:04.261662"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:16:04.262894"], ["updated_at", "2016-11-06 16:16:04.262894"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:16:04.264036"], ["updated_at", "2016-11-06 16:16:04.264036"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:21:55.961933"], ["updated_at", "2016-11-06 16:21:55.961933"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:21:55.965289"], ["updated_at", "2016-11-06 16:21:55.965289"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:21:55.966478"], ["updated_at", "2016-11-06 16:21:55.966478"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:21:55.967588"], ["updated_at", "2016-11-06 16:21:55.967588"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.4ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:23:21.101932"], ["updated_at", "2016-11-06 16:23:21.101932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:23:21.105290"], ["updated_at", "2016-11-06 16:23:21.105290"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:23:21.106436"], ["updated_at", "2016-11-06 16:23:21.106436"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:23:21.107530"], ["updated_at", "2016-11-06 16:23:21.107530"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:24:12.968582"], ["updated_at", "2016-11-06 16:24:12.968582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:24:12.972832"], ["updated_at", "2016-11-06 16:24:12.972832"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:24:12.974462"], ["updated_at", "2016-11-06 16:24:12.974462"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:24:12.975933"], ["updated_at", "2016-11-06 16:24:12.975933"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]}  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:24:40.192122"], ["updated_at", "2016-11-06 16:24:40.192122"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:25:04.938751"], ["updated_at", "2016-11-06 16:25:04.938751"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:25:05.169119"], ["updated_at", "2016-11-06 16:25:05.169119"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:25:05.196055"], ["updated_at", "2016-11-06 16:25:05.196055"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:25:05.203322"], ["updated_at", "2016-11-06 16:25:05.203322"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]}  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:25:25.647348"], ["updated_at", "2016-11-06 16:25:25.647348"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:25:25.768365"], ["updated_at", "2016-11-06 16:25:25.768365"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:25:25.774913"], ["updated_at", "2016-11-06 16:25:25.774913"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:25:25.780474"], ["updated_at", "2016-11-06 16:25:25.780474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:26:07.461310"], ["updated_at", "2016-11-06 16:26:07.461310"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:26:07.582669"], ["updated_at", "2016-11-06 16:26:07.582669"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:26:07.589775"], ["updated_at", "2016-11-06 16:26:07.589775"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:26:07.596593"], ["updated_at", "2016-11-06 16:26:07.596593"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]}  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (2.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:28:21.382094"], ["updated_at", "2016-11-06 16:28:21.382094"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:28:21.393909"], ["updated_at", "2016-11-06 16:28:21.393909"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:28:21.400848"], ["updated_at", "2016-11-06 16:28:21.400848"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:28:21.407518"], ["updated_at", "2016-11-06 16:28:21.407518"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:32:09.465308"], ["updated_at", "2016-11-06 16:32:09.465308"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:32:09.494066"], ["updated_at", "2016-11-06 16:32:09.494066"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:32:09.501248"], ["updated_at", "2016-11-06 16:32:09.501248"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:32:09.507834"], ["updated_at", "2016-11-06 16:32:09.507834"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Shop Load (6.7ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (49, 48, 47, 46)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:32:35.154602"], ["updated_at", "2016-11-06 16:32:35.154602"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:32:35.177185"], ["updated_at", "2016-11-06 16:32:35.177185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:32:35.184098"], ["updated_at", "2016-11-06 16:32:35.184098"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:32:35.190818"], ["updated_at", "2016-11-06 16:32:35.190818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:36:58.762922"], ["updated_at", "2016-11-06 16:36:58.762922"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:36:58.785458"], ["updated_at", "2016-11-06 16:36:58.785458"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:36:58.795303"], ["updated_at", "2016-11-06 16:36:58.795303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:36:58.801788"], ["updated_at", "2016-11-06 16:36:58.801788"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (54, 55, 56, 57) {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:desc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (57, 56, 55, 54) {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (54, 55, 56, 57) {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (57, 56, 55, 54)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:38:24.799033"], ["updated_at", "2016-11-06 16:38:24.799033"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:38:24.809789"], ["updated_at", "2016-11-06 16:38:24.809789"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:38:24.817281"], ["updated_at", "2016-11-06 16:38:24.817281"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:38:24.823787"], ["updated_at", "2016-11-06 16:38:24.823787"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (58, 59, 60, 61) {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:desc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (61, 60, 59, 58) {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (58, 59, 60, 61) {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (61, 60, 59, 58)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.5ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "a"], ["created_at", "2016-11-06 16:38:36.000351"], ["updated_at", "2016-11-06 16:38:36.000351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "b"], ["created_at", "2016-11-06 16:38:36.009512"], ["updated_at", "2016-11-06 16:38:36.009512"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "c"], ["created_at", "2016-11-06 16:38:36.015063"], ["updated_at", "2016-11-06 16:38:36.015063"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "d"], ["created_at", "2016-11-06 16:38:36.020200"], ["updated_at", "2016-11-06 16:38:36.020200"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (62, 63, 64, 65) {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:desc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (65, 64, 63, 62) {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (62, 63, 64, 65) {:query=>{:match_all=>{}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (65, 64, 63, 62)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:42:21.531390"], ["updated_at", "2016-11-06 16:42:21.531390"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (2.5ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)   (12.8ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateProducts (20161104164148)  (0.1ms) BEGIN  (7.4ms) CREATE TABLE "products" ("id" serial primary key, "name" character varying, "category" character varying, "shop_id" integer, "price" integer, "currency" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104164148"]]  (0.5ms) COMMIT Migrating to CreateShops (20161104182219)  (0.2ms) BEGIN  (1.8ms) CREATE TABLE "shops" ("id" serial primary key, "name" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.2ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104182219"]]  (0.5ms) COMMIT ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (1.8ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'products' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname   (1.3ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'shops' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:43:10.109687"], ["updated_at", "2016-11-06 16:43:10.109687"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["created_at", "2016-11-06 16:43:10.116519"], ["updated_at", "2016-11-06 16:43:10.116519"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:43:52.002220"], ["updated_at", "2016-11-06 16:43:52.002220"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 2], ["created_at", "2016-11-06 16:43:52.014463"], ["updated_at", "2016-11-06 16:43:52.014463"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:45:12.684500"], ["updated_at", "2016-11-06 16:45:12.684500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 3], ["created_at", "2016-11-06 16:45:12.696674"], ["updated_at", "2016-11-06 16:45:12.696674"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.4ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:46:06.907850"], ["updated_at", "2016-11-06 16:46:06.907850"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 4], ["created_at", "2016-11-06 16:46:06.920537"], ["updated_at", "2016-11-06 16:46:06.920537"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:46:50.750999"], ["updated_at", "2016-11-06 16:46:50.750999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:46:55.500763"], ["updated_at", "2016-11-06 16:46:55.500763"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000 Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000 ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:50:43.390624"], ["updated_at", "2016-11-06 16:50:43.390624"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 7], ["created_at", "2016-11-06 16:50:43.401837"], ["updated_at", "2016-11-06 16:50:43.401837"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:50:58.668032"], ["updated_at", "2016-11-06 16:50:58.668032"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 8], ["created_at", "2016-11-06 16:50:58.677164"], ["updated_at", "2016-11-06 16:50:58.677164"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:52:35.498663"], ["updated_at", "2016-11-06 16:52:35.498663"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:52:42.618480"], ["updated_at", "2016-11-06 16:52:42.618480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 9], ["created_at", "2016-11-06 16:52:42.623974"], ["updated_at", "2016-11-06 16:52:42.623974"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:56:24.297954"], ["updated_at", "2016-11-06 16:56:24.297954"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 10], ["created_at", "2016-11-06 16:56:24.311619"], ["updated_at", "2016-11-06 16:56:24.311619"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:57:31.742505"], ["updated_at", "2016-11-06 16:57:31.742505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 11], ["created_at", "2016-11-06 16:57:31.755743"], ["updated_at", "2016-11-06 16:57:31.755743"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 11], ["created_at", "2016-11-06 16:57:31.779117"], ["updated_at", "2016-11-06 16:57:31.779117"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 11], ["created_at", "2016-11-06 16:57:31.785318"], ["updated_at", "2016-11-06 16:57:31.785318"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 11], ["created_at", "2016-11-06 16:57:31.791273"], ["updated_at", "2016-11-06 16:57:31.791273"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:57:50.132485"], ["updated_at", "2016-11-06 16:57:50.132485"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 12], ["created_at", "2016-11-06 16:57:50.143691"], ["updated_at", "2016-11-06 16:57:50.143691"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 12], ["created_at", "2016-11-06 16:57:50.155967"], ["updated_at", "2016-11-06 16:57:50.155967"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 12], ["created_at", "2016-11-06 16:57:50.161940"], ["updated_at", "2016-11-06 16:57:50.161940"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 12], ["created_at", "2016-11-06 16:57:50.167677"], ["updated_at", "2016-11-06 16:57:50.167677"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:58:08.470554"], ["updated_at", "2016-11-06 16:58:08.470554"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 13], ["created_at", "2016-11-06 16:58:08.485017"], ["updated_at", "2016-11-06 16:58:08.485017"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 13], ["created_at", "2016-11-06 16:58:08.495889"], ["updated_at", "2016-11-06 16:58:08.495889"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 13], ["created_at", "2016-11-06 16:58:08.501580"], ["updated_at", "2016-11-06 16:58:08.501580"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 13], ["created_at", "2016-11-06 16:58:08.507291"], ["updated_at", "2016-11-06 16:58:08.507291"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 13  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:58:34.742807"], ["updated_at", "2016-11-06 16:58:34.742807"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 14], ["created_at", "2016-11-06 16:58:34.756352"], ["updated_at", "2016-11-06 16:58:34.756352"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 14], ["created_at", "2016-11-06 16:58:34.770717"], ["updated_at", "2016-11-06 16:58:34.770717"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 14], ["created_at", "2016-11-06 16:58:34.776126"], ["updated_at", "2016-11-06 16:58:34.776126"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 14], ["created_at", "2016-11-06 16:58:34.781448"], ["updated_at", "2016-11-06 16:58:34.781448"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:multi_match=>{:query=>nil, :type=>"phrase_prefix", :fields=>["name", "category"]}}}}, :sort=>[{:_uid=>{:order=>:asc}}]}  (0.4ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 16:59:32.972558"], ["updated_at", "2016-11-06 16:59:32.972558"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 15], ["created_at", "2016-11-06 16:59:32.987612"], ["updated_at", "2016-11-06 16:59:32.987612"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 15], ["created_at", "2016-11-06 16:59:32.998862"], ["updated_at", "2016-11-06 16:59:32.998862"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 15], ["created_at", "2016-11-06 16:59:33.004503"], ["updated_at", "2016-11-06 16:59:33.004503"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 15], ["created_at", "2016-11-06 16:59:33.009951"], ["updated_at", "2016-11-06 16:59:33.009951"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (26, 27, 28, 29) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (29, 28, 27, 26) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (26, 27, 28, 29) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (29, 28, 27, 26)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (1.0ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:02:46.485649"], ["updated_at", "2016-11-06 17:02:46.485649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 16], ["created_at", "2016-11-06 17:02:46.519628"], ["updated_at", "2016-11-06 17:02:46.519628"]]  (0.5ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 16], ["created_at", "2016-11-06 17:02:46.544735"], ["updated_at", "2016-11-06 17:02:46.544735"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 16], ["created_at", "2016-11-06 17:02:46.550372"], ["updated_at", "2016-11-06 17:02:46.550372"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 16], ["created_at", "2016-11-06 17:02:46.555838"], ["updated_at", "2016-11-06 17:02:46.555838"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (30, 31, 32, 33) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (33, 32, 31, 30) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (30, 31, 32, 33) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (33, 32, 31, 30) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }", :order=>:asc}}}]}  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:03:12.541260"], ["updated_at", "2016-11-06 17:03:12.541260"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 17], ["created_at", "2016-11-06 17:03:12.559665"], ["updated_at", "2016-11-06 17:03:12.559665"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 17], ["created_at", "2016-11-06 17:03:12.571350"], ["updated_at", "2016-11-06 17:03:12.571350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 17], ["created_at", "2016-11-06 17:03:12.577709"], ["updated_at", "2016-11-06 17:03:12.577709"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 17], ["created_at", "2016-11-06 17:03:12.583536"], ["updated_at", "2016-11-06 17:03:12.583536"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (34, 35, 36, 37) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (37, 36, 35, 34) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (34, 35, 36, 37) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (37, 36, 35, 34) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }", :order=>:asc}}}]}  (0.4ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.7ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:04:58.729733"], ["updated_at", "2016-11-06 17:04:58.729733"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "a"], ["price", 0], ["currency", "UYU"], ["shop_id", 18], ["created_at", "2016-11-06 17:04:58.764967"], ["updated_at", "2016-11-06 17:04:58.764967"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "b"], ["price", 1], ["currency", "UYU"], ["shop_id", 18], ["created_at", "2016-11-06 17:04:58.795025"], ["updated_at", "2016-11-06 17:04:58.795025"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "c"], ["price", 2], ["currency", "UYU"], ["shop_id", 18], ["created_at", "2016-11-06 17:04:58.803031"], ["updated_at", "2016-11-06 17:04:58.803031"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6) RETURNING "id" [["name", "d"], ["price", 3], ["currency", "UYU"], ["shop_id", 18], ["created_at", "2016-11-06 17:04:58.809309"], ["updated_at", "2016-11-06 17:04:58.809309"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (38, 39, 40, 41) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (41, 40, 39, 38) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (38, 39, 40, 41) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (41, 40, 39, 38) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (38, 39, 40, 41) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (41, 40, 39, 38)  (0.2ms) ROLLBACK  (14.2ms) CREATE TABLE "schema_migrations" ("version" character varying NOT NULL)   (12.7ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version") ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations" Migrating to CreateProducts (20161104164148)  (0.3ms) BEGIN  (9.8ms) CREATE TABLE "products" ("id" serial primary key, "name" character varying, "category" character varying, "shop_id" integer, "price" integer, "position" integer, "currency" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.6ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104164148"]]  (8.4ms) COMMIT Migrating to CreateShops (20161104182219)  (10.8ms) BEGIN  (14.3ms) CREATE TABLE "shops" ("id" serial primary key, "name" character varying, "created_at" timestamp NOT NULL, "updated_at" timestamp NOT NULL)  SQL (0.3ms) INSERT INTO "schema_migrations" ("version") VALUES ($1) [["version", "20161104182219"]]  (0.8ms) COMMIT ActiveRecord::SchemaMigration Load (0.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (2.7ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'products' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname   (1.5ms) SELECT t2.oid::regclass::text AS to_table, a1.attname AS column, a2.attname AS primary_key, c.conname AS name, c.confupdtype AS on_update, c.confdeltype AS on_delete FROM pg_constraint c JOIN pg_class t1 ON c.conrelid = t1.oid JOIN pg_class t2 ON c.confrelid = t2.oid JOIN pg_attribute a1 ON a1.attnum = c.conkey[1] AND a1.attrelid = t1.oid JOIN pg_attribute a2 ON a2.attnum = c.confkey[1] AND a2.attrelid = t2.oid JOIN pg_namespace t3 ON c.connamespace = t3.oid WHERE c.contype = 'f' AND t1.relname = 'shops' AND t3.nspname = ANY (current_schemas(false)) ORDER BY c.conname ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (1.0ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.6ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:08:16.837448"], ["updated_at", "2016-11-06 17:08:16.837448"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 1], ["created_at", "2016-11-06 17:08:16.876361"], ["updated_at", "2016-11-06 17:08:16.876361"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:08:36.253249"], ["updated_at", "2016-11-06 17:08:36.253249"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 2], ["created_at", "2016-11-06 17:08:36.297020"], ["updated_at", "2016-11-06 17:08:36.297020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "b"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 2], ["created_at", "2016-11-06 17:08:36.329327"], ["updated_at", "2016-11-06 17:08:36.329327"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "c"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 2], ["created_at", "2016-11-06 17:08:36.338177"], ["updated_at", "2016-11-06 17:08:36.338177"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "d"], ["position", 3], ["price", 30], ["currency", "UYU"], ["shop_id", 2], ["created_at", "2016-11-06 17:08:36.344395"], ["updated_at", "2016-11-06 17:08:36.344395"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (2, 3, 4, 5) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (5, 4, 3, 2) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (2, 3, 4, 5) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (5, 4, 3, 2) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (2, 3, 4, 5) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (5, 4, 3, 2)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:11:36.292668"], ["updated_at", "2016-11-06 17:11:36.292668"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 3], ["created_at", "2016-11-06 17:11:36.336956"], ["updated_at", "2016-11-06 17:11:36.336956"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "b"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 3], ["created_at", "2016-11-06 17:11:36.365001"], ["updated_at", "2016-11-06 17:11:36.365001"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "c"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 3], ["created_at", "2016-11-06 17:11:36.372159"], ["updated_at", "2016-11-06 17:11:36.372159"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "d"], ["position", 3], ["price", 30], ["currency", "UYU"], ["shop_id", 3], ["created_at", "2016-11-06 17:11:36.379752"], ["updated_at", "2016-11-06 17:11:36.379752"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:11:48.393807"], ["updated_at", "2016-11-06 17:11:48.393807"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 4], ["created_at", "2016-11-06 17:11:48.430307"], ["updated_at", "2016-11-06 17:11:48.430307"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (3.0ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "b"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 4], ["created_at", "2016-11-06 17:11:48.464547"], ["updated_at", "2016-11-06 17:11:48.464547"]]  (2.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "c"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 4], ["created_at", "2016-11-06 17:11:48.493406"], ["updated_at", "2016-11-06 17:11:48.493406"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "d"], ["position", 3], ["price", 30], ["currency", "UYU"], ["shop_id", 4], ["created_at", "2016-11-06 17:11:48.506263"], ["updated_at", "2016-11-06 17:11:48.506263"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (10, 11, 12, 13) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (13, 12, 11, 10)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:12:15.959699"], ["updated_at", "2016-11-06 17:12:15.959699"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 5], ["created_at", "2016-11-06 17:12:15.984644"], ["updated_at", "2016-11-06 17:12:15.984644"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "b"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 5], ["created_at", "2016-11-06 17:12:15.996278"], ["updated_at", "2016-11-06 17:12:15.996278"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "c"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 5], ["created_at", "2016-11-06 17:12:16.002404"], ["updated_at", "2016-11-06 17:12:16.002404"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "d"], ["position", 3], ["price", 30], ["currency", "UYU"], ["shop_id", 5], ["created_at", "2016-11-06 17:12:16.008223"], ["updated_at", "2016-11-06 17:12:16.008223"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (14, 15, 16, 17) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (17, 16, 15, 14) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (14, 15, 16, 17) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (17, 16, 15, 14) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (14, 15, 16, 17) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (17, 16, 15, 14) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:position=>{:order=>:asc}}]}  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (2.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:14:33.164196"], ["updated_at", "2016-11-06 17:14:33.164196"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 6], ["created_at", "2016-11-06 17:14:33.200899"], ["updated_at", "2016-11-06 17:14:33.200899"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "b"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 6], ["created_at", "2016-11-06 17:14:33.229351"], ["updated_at", "2016-11-06 17:14:33.229351"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "c"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 6], ["created_at", "2016-11-06 17:14:33.235650"], ["updated_at", "2016-11-06 17:14:33.235650"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "d"], ["position", 3], ["price", 30], ["currency", "UYU"], ["shop_id", 6], ["created_at", "2016-11-06 17:14:33.242165"], ["updated_at", "2016-11-06 17:14:33.242165"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (18, 19, 20, 21) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (21, 20, 19, 18) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (18, 19, 20, 21) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (21, 20, 19, 18) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (18, 19, 20, 21) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (21, 20, 19, 18) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[nil]}  (0.4ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (2.0ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:17:48.087075"], ["updated_at", "2016-11-06 17:17:48.087075"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 7], ["created_at", "2016-11-06 17:17:48.130869"], ["updated_at", "2016-11-06 17:17:48.130869"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "b"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 7], ["created_at", "2016-11-06 17:17:48.160810"], ["updated_at", "2016-11-06 17:17:48.160810"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "c"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 7], ["created_at", "2016-11-06 17:17:48.176480"], ["updated_at", "2016-11-06 17:17:48.176480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "d"], ["position", 3], ["price", 30], ["currency", "UYU"], ["shop_id", 7], ["created_at", "2016-11-06 17:17:48.184092"], ["updated_at", "2016-11-06 17:17:48.184092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (22, 23, 24, 25) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (25, 24, 23, 22) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (22, 23, 24, 25) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (25, 24, 23, 22) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (22, 23, 24, 25) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (25, 24, 23, 22) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (22, 23, 24, 25) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (22, 23, 24, 25)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:19:12.651424"], ["updated_at", "2016-11-06 17:19:12.651424"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "a"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 8], ["created_at", "2016-11-06 17:19:12.687756"], ["updated_at", "2016-11-06 17:19:12.687756"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "b"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 8], ["created_at", "2016-11-06 17:19:12.715921"], ["updated_at", "2016-11-06 17:19:12.715921"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "c"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 8], ["created_at", "2016-11-06 17:19:12.724101"], ["updated_at", "2016-11-06 17:19:12.724101"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "d"], ["position", 3], ["price", 30], ["currency", "UYU"], ["shop_id", 8], ["created_at", "2016-11-06 17:19:12.730246"], ["updated_at", "2016-11-06 17:19:12.730246"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (26, 27, 28, 29) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (29, 28, 27, 26) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (26, 27, 28, 29) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (29, 28, 27, 26) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (26, 27, 28, 29) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (29, 28, 27, 26) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (26, 27, 28, 29) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (26, 27, 28, 29)  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:57:14.536356"], ["updated_at", "2016-11-06 17:57:14.536356"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 9], ["created_at", "2016-11-06 17:57:14.579848"], ["updated_at", "2016-11-06 17:57:14.579848"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 9], ["created_at", "2016-11-06 17:57:14.610474"], ["updated_at", "2016-11-06 17:57:14.610474"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 9], ["created_at", "2016-11-06 17:57:14.620568"], ["updated_at", "2016-11-06 17:57:14.620568"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (30, 31, 32) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (32, 31, 30) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (30, 31, 32) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (32, 31, 30) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (30, 31, 32) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (32, 31, 30) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (30, 31, 32) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (30, 31, 32)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (5.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:57:51.256238"], ["updated_at", "2016-11-06 17:57:51.256238"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 10], ["created_at", "2016-11-06 17:57:51.298825"], ["updated_at", "2016-11-06 17:57:51.298825"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (3.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 10], ["created_at", "2016-11-06 17:57:51.329078"], ["updated_at", "2016-11-06 17:57:51.329078"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 10], ["created_at", "2016-11-06 17:57:51.335719"], ["updated_at", "2016-11-06 17:57:51.335719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (33, 34, 35) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (35, 34, 33) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (33, 34, 35) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (35, 34, 33) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (33, 34, 35) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (35, 34, 33) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (33, 34, 35) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (1.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (33, 34, 35)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 17:57:53.463015"], ["updated_at", "2016-11-06 17:57:53.463015"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 17:57:53.464645"], ["updated_at", "2016-11-06 17:57:53.464645"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 17:57:53.465893"], ["updated_at", "2016-11-06 17:57:53.465893"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 17:57:53.467050"], ["updated_at", "2016-11-06 17:57:53.467050"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 17:57:53.468215"], ["updated_at", "2016-11-06 17:57:53.468215"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 17:59:38.051231"], ["updated_at", "2016-11-06 17:59:38.051231"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 16], ["created_at", "2016-11-06 17:59:38.095463"], ["updated_at", "2016-11-06 17:59:38.095463"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 16], ["created_at", "2016-11-06 17:59:38.123605"], ["updated_at", "2016-11-06 17:59:38.123605"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 16], ["created_at", "2016-11-06 17:59:38.129836"], ["updated_at", "2016-11-06 17:59:38.129836"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (36, 37, 38) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (38, 37, 36) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (36, 37, 38) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (38, 37, 36) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (36, 37, 38) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (38, 37, 36) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (36, 37, 38) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (36, 37, 38)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 17:59:40.255706"], ["updated_at", "2016-11-06 17:59:40.255706"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 17:59:40.257400"], ["updated_at", "2016-11-06 17:59:40.257400"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 17:59:40.258726"], ["updated_at", "2016-11-06 17:59:40.258726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 17:59:40.260103"], ["updated_at", "2016-11-06 17:59:40.260103"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 17:59:40.261479"], ["updated_at", "2016-11-06 17:59:40.261479"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:01:49.604544"], ["updated_at", "2016-11-06 18:01:49.604544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 22], ["created_at", "2016-11-06 18:01:49.640787"], ["updated_at", "2016-11-06 18:01:49.640787"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 22], ["created_at", "2016-11-06 18:01:49.669587"], ["updated_at", "2016-11-06 18:01:49.669587"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 22], ["created_at", "2016-11-06 18:01:49.675846"], ["updated_at", "2016-11-06 18:01:49.675846"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (39, 40, 41) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (41, 40, 39) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (39, 40, 41) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (41, 40, 39) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (39, 40, 41) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (41, 40, 39) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (39, 40, 41) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (39, 40, 41)  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:01:51.810706"], ["updated_at", "2016-11-06 18:01:51.810706"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:01:51.812353"], ["updated_at", "2016-11-06 18:01:51.812353"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:01:51.813920"], ["updated_at", "2016-11-06 18:01:51.813920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:01:51.815383"], ["updated_at", "2016-11-06 18:01:51.815383"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:01:51.816855"], ["updated_at", "2016-11-06 18:01:51.816855"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:02:02.766376"], ["updated_at", "2016-11-06 18:02:02.766376"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:02:02.770700"], ["updated_at", "2016-11-06 18:02:02.770700"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:02:02.772162"], ["updated_at", "2016-11-06 18:02:02.772162"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:02:02.773628"], ["updated_at", "2016-11-06 18:02:02.773628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:02:02.775426"], ["updated_at", "2016-11-06 18:02:02.775426"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:02:02.846544"], ["updated_at", "2016-11-06 18:02:02.846544"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 33], ["created_at", "2016-11-06 18:02:02.880432"], ["updated_at", "2016-11-06 18:02:02.880432"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 33], ["created_at", "2016-11-06 18:02:02.907116"], ["updated_at", "2016-11-06 18:02:02.907116"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 33], ["created_at", "2016-11-06 18:02:02.913714"], ["updated_at", "2016-11-06 18:02:02.913714"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.7ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (42, 43, 44) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (2.7ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (44, 43, 42) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (42, 43, 44) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.9ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (44, 43, 42) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (42, 43, 44) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (44, 43, 42) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (42, 43, 44) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (42, 43, 44)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.5ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:02:25.541979"], ["updated_at", "2016-11-06 18:02:25.541979"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 34], ["created_at", "2016-11-06 18:02:25.567718"], ["updated_at", "2016-11-06 18:02:25.567718"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 34], ["created_at", "2016-11-06 18:02:25.580053"], ["updated_at", "2016-11-06 18:02:25.580053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 34], ["created_at", "2016-11-06 18:02:25.586549"], ["updated_at", "2016-11-06 18:02:25.586549"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (45, 46, 47) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (47, 46, 45) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (45, 46, 47) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (47, 46, 45) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (45, 46, 47) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (47, 46, 45) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (45, 46, 47) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (45, 46, 47)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:02:27.720766"], ["updated_at", "2016-11-06 18:02:27.720766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:02:27.722647"], ["updated_at", "2016-11-06 18:02:27.722647"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:02:27.724092"], ["updated_at", "2016-11-06 18:02:27.724092"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:02:27.725512"], ["updated_at", "2016-11-06 18:02:27.725512"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:02:27.726891"], ["updated_at", "2016-11-06 18:02:27.726891"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:03:22.613004"], ["updated_at", "2016-11-06 18:03:22.613004"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 40], ["created_at", "2016-11-06 18:03:22.637104"], ["updated_at", "2016-11-06 18:03:22.637104"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 40], ["created_at", "2016-11-06 18:03:22.648767"], ["updated_at", "2016-11-06 18:03:22.648767"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 40], ["created_at", "2016-11-06 18:03:22.655193"], ["updated_at", "2016-11-06 18:03:22.655193"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (48, 49, 50) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (50, 49, 48) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (48, 49, 50) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (50, 49, 48) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (48, 49, 50) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (50, 49, 48) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (48, 49, 50) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (48, 49, 50)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:03:24.775985"], ["updated_at", "2016-11-06 18:03:24.775985"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:03:24.777652"], ["updated_at", "2016-11-06 18:03:24.777652"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:03:24.778894"], ["updated_at", "2016-11-06 18:03:24.778894"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:03:24.779986"], ["updated_at", "2016-11-06 18:03:24.779986"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:03:24.781066"], ["updated_at", "2016-11-06 18:03:24.781066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:03:37.833901"], ["updated_at", "2016-11-06 18:03:37.833901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 46], ["created_at", "2016-11-06 18:03:37.857167"], ["updated_at", "2016-11-06 18:03:37.857167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 46], ["created_at", "2016-11-06 18:03:37.867678"], ["updated_at", "2016-11-06 18:03:37.867678"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 46], ["created_at", "2016-11-06 18:03:37.874063"], ["updated_at", "2016-11-06 18:03:37.874063"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (51, 52, 53) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (53, 52, 51) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (51, 52, 53) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (53, 52, 51) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (51, 52, 53) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (53, 52, 51) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (51, 52, 53) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (51, 52, 53)  (1.4ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:03:39.993568"], ["updated_at", "2016-11-06 18:03:39.993568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:03:39.995151"], ["updated_at", "2016-11-06 18:03:39.995151"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:03:39.996423"], ["updated_at", "2016-11-06 18:03:39.996423"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:03:39.997698"], ["updated_at", "2016-11-06 18:03:39.997698"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:03:39.999006"], ["updated_at", "2016-11-06 18:03:39.999006"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:04:03.282457"], ["updated_at", "2016-11-06 18:04:03.282457"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:04:03.296748"], ["updated_at", "2016-11-06 18:04:03.296748"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:04:03.303162"], ["updated_at", "2016-11-06 18:04:03.303162"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:04:03.308990"], ["updated_at", "2016-11-06 18:04:03.308990"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:04:03.313668"], ["updated_at", "2016-11-06 18:04:03.313668"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (52, 54)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:04:05.388212"], ["updated_at", "2016-11-06 18:04:05.388212"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 57], ["created_at", "2016-11-06 18:04:05.406800"], ["updated_at", "2016-11-06 18:04:05.406800"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 57], ["created_at", "2016-11-06 18:04:05.418652"], ["updated_at", "2016-11-06 18:04:05.418652"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 57], ["created_at", "2016-11-06 18:04:05.425303"], ["updated_at", "2016-11-06 18:04:05.425303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (54, 55, 56) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (56, 55, 54) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (54, 55, 56) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (56, 55, 54) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (54, 55, 56) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (56, 55, 54) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (54, 55, 56) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (54, 55, 56)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.9ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:04:56.209516"], ["updated_at", "2016-11-06 18:04:56.209516"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 58], ["created_at", "2016-11-06 18:04:56.233329"], ["updated_at", "2016-11-06 18:04:56.233329"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 58], ["created_at", "2016-11-06 18:04:56.243434"], ["updated_at", "2016-11-06 18:04:56.243434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 58], ["created_at", "2016-11-06 18:04:56.249690"], ["updated_at", "2016-11-06 18:04:56.249690"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (57, 58, 59) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (59, 58, 57) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (57, 58, 59) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (59, 58, 57) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (57, 58, 59) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (59, 58, 57) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (57, 58, 59) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (57, 58, 59)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:04:58.374549"], ["updated_at", "2016-11-06 18:04:58.374549"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:04:58.380513"], ["updated_at", "2016-11-06 18:04:58.380513"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:04:58.386996"], ["updated_at", "2016-11-06 18:04:58.386996"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:04:58.394365"], ["updated_at", "2016-11-06 18:04:58.394365"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:04:58.399893"], ["updated_at", "2016-11-06 18:04:58.399893"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (59, 60) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (61, 62) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 63  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:05:14.603716"], ["updated_at", "2016-11-06 18:05:14.603716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 64], ["created_at", "2016-11-06 18:05:14.625616"], ["updated_at", "2016-11-06 18:05:14.625616"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 64], ["created_at", "2016-11-06 18:05:14.635864"], ["updated_at", "2016-11-06 18:05:14.635864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 64], ["created_at", "2016-11-06 18:05:14.641731"], ["updated_at", "2016-11-06 18:05:14.641731"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (60, 61, 62) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (62, 61, 60) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (60, 61, 62) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (62, 61, 60) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (1.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (60, 61, 62) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (62, 61, 60) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (60, 61, 62) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (60, 61, 62)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:05:16.749166"], ["updated_at", "2016-11-06 18:05:16.749166"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:05:16.754600"], ["updated_at", "2016-11-06 18:05:16.754600"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:05:16.761561"], ["updated_at", "2016-11-06 18:05:16.761561"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:05:16.767172"], ["updated_at", "2016-11-06 18:05:16.767172"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:05:16.773957"], ["updated_at", "2016-11-06 18:05:16.773957"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (65, 66) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (67, 68) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 69 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (1.0ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.6ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:07:16.757580"], ["updated_at", "2016-11-06 18:07:16.757580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:07:16.766622"], ["updated_at", "2016-11-06 18:07:16.766622"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:07:16.774955"], ["updated_at", "2016-11-06 18:07:16.774955"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:07:16.780276"], ["updated_at", "2016-11-06 18:07:16.780276"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:07:16.785705"], ["updated_at", "2016-11-06 18:07:16.785705"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (70, 71) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (72, 73) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 74 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 74  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:07:18.874460"], ["updated_at", "2016-11-06 18:07:18.874460"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 75], ["created_at", "2016-11-06 18:07:18.893069"], ["updated_at", "2016-11-06 18:07:18.893069"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 75], ["created_at", "2016-11-06 18:07:18.903574"], ["updated_at", "2016-11-06 18:07:18.903574"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 75], ["created_at", "2016-11-06 18:07:18.910107"], ["updated_at", "2016-11-06 18:07:18.910107"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (63, 64, 65) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (65, 64, 63) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (63, 64, 65) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (65, 64, 63) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (63, 64, 65) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (65, 64, 63) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (63, 64, 65) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (63, 64, 65)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:07:34.082891"], ["updated_at", "2016-11-06 18:07:34.082891"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "1"], ["position", 0], ["price", 0], ["currency", "UYU"], ["shop_id", 76], ["created_at", "2016-11-06 18:07:34.104288"], ["updated_at", "2016-11-06 18:07:34.104288"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "2"], ["position", 1], ["price", 10], ["currency", "UYU"], ["shop_id", 76], ["created_at", "2016-11-06 18:07:34.114572"], ["updated_at", "2016-11-06 18:07:34.114572"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "position", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["name", "3"], ["position", 2], ["price", 20], ["currency", "UYU"], ["shop_id", 76], ["created_at", "2016-11-06 18:07:34.120649"], ["updated_at", "2016-11-06 18:07:34.120649"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (66, 67, 68) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (68, 67, 66) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (66, 67, 68) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (68, 67, 66) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (66, 67, 68) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (68, 67, 66) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (66, 67, 68) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (66, 67, 68)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:07:36.232985"], ["updated_at", "2016-11-06 18:07:36.232985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:07:36.239568"], ["updated_at", "2016-11-06 18:07:36.239568"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:07:36.245810"], ["updated_at", "2016-11-06 18:07:36.245810"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:07:36.252709"], ["updated_at", "2016-11-06 18:07:36.252709"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:07:36.259200"], ["updated_at", "2016-11-06 18:07:36.259200"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (77, 78) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (79, 80) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 81 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (79, 80) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 81 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:15:59.637144"], ["updated_at", "2016-11-06 18:15:59.637144"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:15:59.663818"], ["updated_at", "2016-11-06 18:15:59.663818"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:15:59.673585"], ["updated_at", "2016-11-06 18:15:59.673585"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (1.1ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "1"], ["created_at", "2016-11-06 18:15:59.749417"], ["updated_at", "2016-11-06 18:15:59.749417"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "2"], ["created_at", "2016-11-06 18:15:59.755497"], ["updated_at", "2016-11-06 18:15:59.755497"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "3"], ["created_at", "2016-11-06 18:15:59.763521"], ["updated_at", "2016-11-06 18:15:59.763521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "4"], ["created_at", "2016-11-06 18:15:59.770782"], ["updated_at", "2016-11-06 18:15:59.770782"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "5"], ["created_at", "2016-11-06 18:15:59.781123"], ["updated_at", "2016-11-06 18:15:59.781123"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (85, 86)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:16:01.856180"], ["updated_at", "2016-11-06 18:16:01.856180"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 10], ["currency", "UYU"], ["shop_id", 90], ["created_at", "2016-11-06 18:16:01.877119"], ["updated_at", "2016-11-06 18:16:01.877119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 20], ["currency", "UYU"], ["shop_id", 90], ["created_at", "2016-11-06 18:16:01.906082"], ["updated_at", "2016-11-06 18:16:01.906082"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 30], ["currency", "UYU"], ["shop_id", 90], ["created_at", "2016-11-06 18:16:01.911858"], ["updated_at", "2016-11-06 18:16:01.911858"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:16:56.267276"], ["updated_at", "2016-11-06 18:16:56.267276"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["currency", "UYU"], ["shop_id", 91], ["created_at", "2016-11-06 18:16:56.304804"], ["updated_at", "2016-11-06 18:16:56.304804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["currency", "UYU"], ["shop_id", 91], ["created_at", "2016-11-06 18:16:56.331943"], ["updated_at", "2016-11-06 18:16:56.331943"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["currency", "UYU"], ["shop_id", 91], ["created_at", "2016-11-06 18:16:56.337766"], ["updated_at", "2016-11-06 18:16:56.337766"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:16:58.450283"], ["updated_at", "2016-11-06 18:16:58.450283"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:16:58.456421"], ["updated_at", "2016-11-06 18:16:58.456421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:16:58.462471"], ["updated_at", "2016-11-06 18:16:58.462471"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:16:58.467794"], ["updated_at", "2016-11-06 18:16:58.467794"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:16:58.472943"], ["updated_at", "2016-11-06 18:16:58.472943"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>[{"name.raw"=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 2)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:17:00.552517"], ["updated_at", "2016-11-06 18:17:00.552517"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:17:00.558214"], ["updated_at", "2016-11-06 18:17:00.558214"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.5ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:17:00.565555"], ["updated_at", "2016-11-06 18:17:00.565555"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:21:19.627438"], ["updated_at", "2016-11-06 18:21:19.627438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["currency", "UYU"], ["shop_id", 92], ["created_at", "2016-11-06 18:21:19.648726"], ["updated_at", "2016-11-06 18:21:19.648726"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["currency", "UYU"], ["shop_id", 92], ["created_at", "2016-11-06 18:21:19.659200"], ["updated_at", "2016-11-06 18:21:19.659200"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["currency", "UYU"], ["shop_id", 92], ["created_at", "2016-11-06 18:21:19.668745"], ["updated_at", "2016-11-06 18:21:19.668745"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:21:21.777563"], ["updated_at", "2016-11-06 18:21:21.777563"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:21:21.783410"], ["updated_at", "2016-11-06 18:21:21.783410"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:21:21.789614"], ["updated_at", "2016-11-06 18:21:21.789614"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:21:21.795233"], ["updated_at", "2016-11-06 18:21:21.795233"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:21:21.800071"], ["updated_at", "2016-11-06 18:21:21.800071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (1, 2) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 4) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 5 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 4) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 5 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>[{:_uid=>{:order=>:asc}}]} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:21:23.895896"], ["updated_at", "2016-11-06 18:21:23.895896"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:21:23.902751"], ["updated_at", "2016-11-06 18:21:23.902751"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:21:23.909306"], ["updated_at", "2016-11-06 18:21:23.909306"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:22:46.828070"], ["updated_at", "2016-11-06 18:22:46.828070"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["currency", "UYU"], ["shop_id", 93], ["created_at", "2016-11-06 18:22:46.848453"], ["updated_at", "2016-11-06 18:22:46.848453"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["currency", "UYU"], ["shop_id", 93], ["created_at", "2016-11-06 18:22:46.859694"], ["updated_at", "2016-11-06 18:22:46.859694"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["currency", "UYU"], ["shop_id", 93], ["created_at", "2016-11-06 18:22:46.865190"], ["updated_at", "2016-11-06 18:22:46.865190"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (1.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (1.6ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:22:48.985534"], ["updated_at", "2016-11-06 18:22:48.985534"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:22:48.993171"], ["updated_at", "2016-11-06 18:22:48.993171"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:22:48.999157"], ["updated_at", "2016-11-06 18:22:48.999157"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:22:49.005365"], ["updated_at", "2016-11-06 18:22:49.005365"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:22:49.011361"], ["updated_at", "2016-11-06 18:22:49.011361"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 2)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (1.1ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:22:51.089132"], ["updated_at", "2016-11-06 18:22:51.089132"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:22:51.094698"], ["updated_at", "2016-11-06 18:22:51.094698"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:22:51.100856"], ["updated_at", "2016-11-06 18:22:51.100856"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (5.0ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (1.7ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:28:37.005319"], ["updated_at", "2016-11-06 18:28:37.005319"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["currency", "UYU"], ["shop_id", 94], ["created_at", "2016-11-06 18:28:37.043348"], ["updated_at", "2016-11-06 18:28:37.043348"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["currency", "UYU"], ["shop_id", 94], ["created_at", "2016-11-06 18:28:37.072459"], ["updated_at", "2016-11-06 18:28:37.072459"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["currency", "UYU"], ["shop_id", 94], ["created_at", "2016-11-06 18:28:37.079059"], ["updated_at", "2016-11-06 18:28:37.079059"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :option=>{}, :sort=>nil}  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:28:39.166782"], ["updated_at", "2016-11-06 18:28:39.166782"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:28:39.173349"], ["updated_at", "2016-11-06 18:28:39.173349"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:28:39.180752"], ["updated_at", "2016-11-06 18:28:39.180752"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:28:39.187849"], ["updated_at", "2016-11-06 18:28:39.187849"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:28:39.193396"], ["updated_at", "2016-11-06 18:28:39.193396"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (1.1ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.6ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:28:41.285538"], ["updated_at", "2016-11-06 18:28:41.285538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:28:41.292986"], ["updated_at", "2016-11-06 18:28:41.292986"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:28:41.299051"], ["updated_at", "2016-11-06 18:28:41.299051"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:29:03.642146"], ["updated_at", "2016-11-06 18:29:03.642146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:29:03.755813"], ["updated_at", "2016-11-06 18:29:03.755813"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:29:03.983055"], ["updated_at", "2016-11-06 18:29:03.983055"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:29:04.153423"], ["updated_at", "2016-11-06 18:29:04.153423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["currency", "UYU"], ["shop_id", 95], ["created_at", "2016-11-06 18:29:04.170503"], ["updated_at", "2016-11-06 18:29:04.170503"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["currency", "UYU"], ["shop_id", 95], ["created_at", "2016-11-06 18:29:04.180814"], ["updated_at", "2016-11-06 18:29:04.180814"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["currency", "UYU"], ["shop_id", 95], ["created_at", "2016-11-06 18:29:04.188301"], ["updated_at", "2016-11-06 18:29:04.188301"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :option=>{}, :sort=>nil}  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:29:06.270223"], ["updated_at", "2016-11-06 18:29:06.270223"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:29:06.276133"], ["updated_at", "2016-11-06 18:29:06.276133"]]  (1.1ms) RELEASE SAVEPOINT active_record_1  (1.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:29:06.284947"], ["updated_at", "2016-11-06 18:29:06.284947"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:29:06.291781"], ["updated_at", "2016-11-06 18:29:06.291781"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:29:06.297163"], ["updated_at", "2016-11-06 18:29:06.297163"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:29:23.964083"], ["updated_at", "2016-11-06 18:29:23.964083"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:29:23.972856"], ["updated_at", "2016-11-06 18:29:23.972856"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:29:23.979747"], ["updated_at", "2016-11-06 18:29:23.979747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:29:24.041234"], ["updated_at", "2016-11-06 18:29:24.041234"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (1.6ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["currency", "UYU"], ["shop_id", 96], ["created_at", "2016-11-06 18:29:24.059835"], ["updated_at", "2016-11-06 18:29:24.059835"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["currency", "UYU"], ["shop_id", 96], ["created_at", "2016-11-06 18:29:24.071727"], ["updated_at", "2016-11-06 18:29:24.071727"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["currency", "UYU"], ["shop_id", 96], ["created_at", "2016-11-06 18:29:24.077149"], ["updated_at", "2016-11-06 18:29:24.077149"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:29:26.184939"], ["updated_at", "2016-11-06 18:29:26.184939"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:29:26.190354"], ["updated_at", "2016-11-06 18:29:26.190354"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:29:26.195423"], ["updated_at", "2016-11-06 18:29:26.195423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:29:26.200595"], ["updated_at", "2016-11-06 18:29:26.200595"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:29:26.205747"], ["updated_at", "2016-11-06 18:29:26.205747"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:29:47.385304"], ["updated_at", "2016-11-06 18:29:47.385304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:29:47.392508"], ["updated_at", "2016-11-06 18:29:47.392508"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:29:47.397774"], ["updated_at", "2016-11-06 18:29:47.397774"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.4ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:29:47.453921"], ["updated_at", "2016-11-06 18:29:47.453921"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["currency", "UYU"], ["shop_id", 97], ["created_at", "2016-11-06 18:29:47.472295"], ["updated_at", "2016-11-06 18:29:47.472295"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (2.6ms) SAVEPOINT active_record_1 SQL (5.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["currency", "UYU"], ["shop_id", 97], ["created_at", "2016-11-06 18:29:47.486150"], ["updated_at", "2016-11-06 18:29:47.486150"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["currency", "UYU"], ["shop_id", 97], ["created_at", "2016-11-06 18:29:47.497835"], ["updated_at", "2016-11-06 18:29:47.497835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (1.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:29:49.604695"], ["updated_at", "2016-11-06 18:29:49.604695"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:29:49.610248"], ["updated_at", "2016-11-06 18:29:49.610248"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:29:49.615622"], ["updated_at", "2016-11-06 18:29:49.615622"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:29:49.621222"], ["updated_at", "2016-11-06 18:29:49.621222"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:29:49.626367"], ["updated_at", "2016-11-06 18:29:49.626367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:30:27.673042"], ["updated_at", "2016-11-06 18:30:27.673042"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:30:27.680480"], ["updated_at", "2016-11-06 18:30:27.680480"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:30:27.686054"], ["updated_at", "2016-11-06 18:30:27.686054"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:30:27.691391"], ["updated_at", "2016-11-06 18:30:27.691391"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:30:27.697265"], ["updated_at", "2016-11-06 18:30:27.697265"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.6ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:30:29.789968"], ["updated_at", "2016-11-06 18:30:29.789968"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:30:29.796519"], ["updated_at", "2016-11-06 18:30:29.796519"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:30:29.801764"], ["updated_at", "2016-11-06 18:30:29.801764"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:30:29.859321"], ["updated_at", "2016-11-06 18:30:29.859321"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 98], ["created_at", "2016-11-06 18:30:29.878940"], ["updated_at", "2016-11-06 18:30:29.878940"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 98], ["created_at", "2016-11-06 18:30:29.890920"], ["updated_at", "2016-11-06 18:30:29.890920"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 98], ["created_at", "2016-11-06 18:30:29.896400"], ["updated_at", "2016-11-06 18:30:29.896400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:31:33.152189"], ["updated_at", "2016-11-06 18:31:33.152189"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 99], ["created_at", "2016-11-06 18:31:33.171948"], ["updated_at", "2016-11-06 18:31:33.171948"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 99], ["created_at", "2016-11-06 18:31:33.185159"], ["updated_at", "2016-11-06 18:31:33.185159"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 99], ["created_at", "2016-11-06 18:31:33.191403"], ["updated_at", "2016-11-06 18:31:33.191403"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.5ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:31:35.287305"], ["updated_at", "2016-11-06 18:31:35.287305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:31:35.294065"], ["updated_at", "2016-11-06 18:31:35.294065"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:31:35.300121"], ["updated_at", "2016-11-06 18:31:35.300121"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:31:35.306120"], ["updated_at", "2016-11-06 18:31:35.306120"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:31:35.311912"], ["updated_at", "2016-11-06 18:31:35.311912"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:31:37.397099"], ["updated_at", "2016-11-06 18:31:37.397099"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:31:37.402596"], ["updated_at", "2016-11-06 18:31:37.402596"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:31:37.409217"], ["updated_at", "2016-11-06 18:31:37.409217"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:34:30.040406"], ["updated_at", "2016-11-06 18:34:30.040406"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 100], ["created_at", "2016-11-06 18:34:30.061304"], ["updated_at", "2016-11-06 18:34:30.061304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 100], ["created_at", "2016-11-06 18:34:30.072478"], ["updated_at", "2016-11-06 18:34:30.072478"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 100], ["created_at", "2016-11-06 18:34:30.078176"], ["updated_at", "2016-11-06 18:34:30.078176"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:34:32.179217"], ["updated_at", "2016-11-06 18:34:32.179217"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:34:32.184170"], ["updated_at", "2016-11-06 18:34:32.184170"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:34:32.189182"], ["updated_at", "2016-11-06 18:34:32.189182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>1, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:34:34.251645"], ["updated_at", "2016-11-06 18:34:34.251645"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:34:34.257700"], ["updated_at", "2016-11-06 18:34:34.257700"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:34:34.263941"], ["updated_at", "2016-11-06 18:34:34.263941"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:34:34.269551"], ["updated_at", "2016-11-06 18:34:34.269551"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:34:34.274741"], ["updated_at", "2016-11-06 18:34:34.274741"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:35:26.959069"], ["updated_at", "2016-11-06 18:35:26.959069"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:35:26.966531"], ["updated_at", "2016-11-06 18:35:26.966531"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:35:26.972397"], ["updated_at", "2016-11-06 18:35:26.972397"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:35:26.978067"], ["updated_at", "2016-11-06 18:35:26.978067"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:35:26.983842"], ["updated_at", "2016-11-06 18:35:26.983842"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:35:29.069738"], ["updated_at", "2016-11-06 18:35:29.069738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 101], ["created_at", "2016-11-06 18:35:29.089430"], ["updated_at", "2016-11-06 18:35:29.089430"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 101], ["created_at", "2016-11-06 18:35:29.100357"], ["updated_at", "2016-11-06 18:35:29.100357"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 101], ["created_at", "2016-11-06 18:35:29.106101"], ["updated_at", "2016-11-06 18:35:29.106101"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (5.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:35:31.211818"], ["updated_at", "2016-11-06 18:35:31.211818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:35:31.221184"], ["updated_at", "2016-11-06 18:35:31.221184"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:35:31.226834"], ["updated_at", "2016-11-06 18:35:31.226834"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.5ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:36:07.985945"], ["updated_at", "2016-11-06 18:36:07.985945"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:36:07.994167"], ["updated_at", "2016-11-06 18:36:07.994167"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:36:07.999789"], ["updated_at", "2016-11-06 18:36:07.999789"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:36:08.007310"], ["updated_at", "2016-11-06 18:36:08.007310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:36:08.013035"], ["updated_at", "2016-11-06 18:36:08.013035"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:36:10.101550"], ["updated_at", "2016-11-06 18:36:10.101550"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:36:10.107909"], ["updated_at", "2016-11-06 18:36:10.107909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:36:10.114162"], ["updated_at", "2016-11-06 18:36:10.114162"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (1, 3)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:36:12.178917"], ["updated_at", "2016-11-06 18:36:12.178917"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 102], ["created_at", "2016-11-06 18:36:12.197062"], ["updated_at", "2016-11-06 18:36:12.197062"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (2.6ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 102], ["created_at", "2016-11-06 18:36:12.212707"], ["updated_at", "2016-11-06 18:36:12.212707"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 102], ["created_at", "2016-11-06 18:36:12.219126"], ["updated_at", "2016-11-06 18:36:12.219126"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:37:26.575410"], ["updated_at", "2016-11-06 18:37:26.575410"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 103], ["created_at", "2016-11-06 18:37:26.598769"], ["updated_at", "2016-11-06 18:37:26.598769"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 103], ["created_at", "2016-11-06 18:37:26.608096"], ["updated_at", "2016-11-06 18:37:26.608096"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 103], ["created_at", "2016-11-06 18:37:26.613691"], ["updated_at", "2016-11-06 18:37:26.613691"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:37:28.717363"], ["updated_at", "2016-11-06 18:37:28.717363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:37:28.723373"], ["updated_at", "2016-11-06 18:37:28.723373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:37:28.729218"], ["updated_at", "2016-11-06 18:37:28.729218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:37:28.734787"], ["updated_at", "2016-11-06 18:37:28.734787"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:37:28.739917"], ["updated_at", "2016-11-06 18:37:28.739917"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:37:30.825667"], ["updated_at", "2016-11-06 18:37:30.825667"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:37:30.836824"], ["updated_at", "2016-11-06 18:37:30.836824"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:37:30.841788"], ["updated_at", "2016-11-06 18:37:30.841788"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:37:30.846759"], ["updated_at", "2016-11-06 18:37:30.846759"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:39:11.991031"], ["updated_at", "2016-11-06 18:39:11.991031"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 104], ["created_at", "2016-11-06 18:39:12.010637"], ["updated_at", "2016-11-06 18:39:12.010637"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 104], ["created_at", "2016-11-06 18:39:12.022594"], ["updated_at", "2016-11-06 18:39:12.022594"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 104], ["created_at", "2016-11-06 18:39:12.028603"], ["updated_at", "2016-11-06 18:39:12.028603"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:39:14.129054"], ["updated_at", "2016-11-06 18:39:14.129054"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:39:14.134363"], ["updated_at", "2016-11-06 18:39:14.134363"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:39:14.140333"], ["updated_at", "2016-11-06 18:39:14.140333"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:39:14.145816"], ["updated_at", "2016-11-06 18:39:14.145816"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:39:14.150457"], ["updated_at", "2016-11-06 18:39:14.150457"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:39:16.246012"], ["updated_at", "2016-11-06 18:39:16.246012"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:39:16.254889"], ["updated_at", "2016-11-06 18:39:16.254889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:39:16.260658"], ["updated_at", "2016-11-06 18:39:16.260658"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:39:16.265720"], ["updated_at", "2016-11-06 18:39:16.265720"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:40:26.524011"], ["updated_at", "2016-11-06 18:40:26.524011"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:40:26.532224"], ["updated_at", "2016-11-06 18:40:26.532224"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:40:26.537350"], ["updated_at", "2016-11-06 18:40:26.537350"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:40:26.542799"], ["updated_at", "2016-11-06 18:40:26.542799"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:40:26.548689"], ["updated_at", "2016-11-06 18:40:26.548689"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:40:28.603793"], ["updated_at", "2016-11-06 18:40:28.603793"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:40:28.608622"], ["updated_at", "2016-11-06 18:40:28.608622"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:40:28.614291"], ["updated_at", "2016-11-06 18:40:28.614291"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:40:28.619263"], ["updated_at", "2016-11-06 18:40:28.619263"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:40:30.671980"], ["updated_at", "2016-11-06 18:40:30.671980"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 105], ["created_at", "2016-11-06 18:40:30.690185"], ["updated_at", "2016-11-06 18:40:30.690185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 105], ["created_at", "2016-11-06 18:40:30.700740"], ["updated_at", "2016-11-06 18:40:30.700740"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 105], ["created_at", "2016-11-06 18:40:30.708882"], ["updated_at", "2016-11-06 18:40:30.708882"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:41:02.259808"], ["updated_at", "2016-11-06 18:41:02.259808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 106], ["created_at", "2016-11-06 18:41:02.306740"], ["updated_at", "2016-11-06 18:41:02.306740"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (2.6ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 106], ["created_at", "2016-11-06 18:41:02.335599"], ["updated_at", "2016-11-06 18:41:02.335599"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 106], ["created_at", "2016-11-06 18:41:02.342746"], ["updated_at", "2016-11-06 18:41:02.342746"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:41:04.448685"], ["updated_at", "2016-11-06 18:41:04.448685"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:41:04.454000"], ["updated_at", "2016-11-06 18:41:04.454000"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:41:04.459482"], ["updated_at", "2016-11-06 18:41:04.459482"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:41:04.464519"], ["updated_at", "2016-11-06 18:41:04.464519"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:41:04.469016"], ["updated_at", "2016-11-06 18:41:04.469016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:41:06.555970"], ["updated_at", "2016-11-06 18:41:06.555970"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:41:06.566343"], ["updated_at", "2016-11-06 18:41:06.566343"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:41:06.571495"], ["updated_at", "2016-11-06 18:41:06.571495"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:41:06.576556"], ["updated_at", "2016-11-06 18:41:06.576556"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (2.2ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (1.2ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:47:51.143512"], ["updated_at", "2016-11-06 18:47:51.143512"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 107], ["created_at", "2016-11-06 18:47:51.179814"], ["updated_at", "2016-11-06 18:47:51.179814"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 107], ["created_at", "2016-11-06 18:47:51.206728"], ["updated_at", "2016-11-06 18:47:51.206728"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 107], ["created_at", "2016-11-06 18:47:51.212856"], ["updated_at", "2016-11-06 18:47:51.212856"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (1.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:47:53.318699"], ["updated_at", "2016-11-06 18:47:53.318699"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:47:53.324269"], ["updated_at", "2016-11-06 18:47:53.324269"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:47:53.330081"], ["updated_at", "2016-11-06 18:47:53.330081"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:47:53.335340"], ["updated_at", "2016-11-06 18:47:53.335340"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:47:55.395351"], ["updated_at", "2016-11-06 18:47:55.395351"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:47:55.400434"], ["updated_at", "2016-11-06 18:47:55.400434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:47:55.406267"], ["updated_at", "2016-11-06 18:47:55.406267"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:47:55.411025"], ["updated_at", "2016-11-06 18:47:55.411025"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:47:55.415614"], ["updated_at", "2016-11-06 18:47:55.415614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:50:07.143908"], ["updated_at", "2016-11-06 18:50:07.143908"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 108], ["created_at", "2016-11-06 18:50:07.176582"], ["updated_at", "2016-11-06 18:50:07.176582"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 108], ["created_at", "2016-11-06 18:50:07.187193"], ["updated_at", "2016-11-06 18:50:07.187193"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 108], ["created_at", "2016-11-06 18:50:07.193287"], ["updated_at", "2016-11-06 18:50:07.193287"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:50:09.289413"], ["updated_at", "2016-11-06 18:50:09.289413"]]  (1.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:50:09.296212"], ["updated_at", "2016-11-06 18:50:09.296212"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:50:09.301322"], ["updated_at", "2016-11-06 18:50:09.301322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:50:09.306781"], ["updated_at", "2016-11-06 18:50:09.306781"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:50:11.374191"], ["updated_at", "2016-11-06 18:50:11.374191"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:50:11.379368"], ["updated_at", "2016-11-06 18:50:11.379368"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:50:11.384719"], ["updated_at", "2016-11-06 18:50:11.384719"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:50:11.389879"], ["updated_at", "2016-11-06 18:50:11.389879"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:50:11.395309"], ["updated_at", "2016-11-06 18:50:11.395309"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}}  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:50:32.904756"], ["updated_at", "2016-11-06 18:50:32.904756"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:50:32.912733"], ["updated_at", "2016-11-06 18:50:32.912733"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:50:32.918029"], ["updated_at", "2016-11-06 18:50:32.918029"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:50:32.924251"], ["updated_at", "2016-11-06 18:50:32.924251"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:50:32.930147"], ["updated_at", "2016-11-06 18:50:32.930147"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}}  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:50:34.999965"], ["updated_at", "2016-11-06 18:50:34.999965"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 109], ["created_at", "2016-11-06 18:50:35.017579"], ["updated_at", "2016-11-06 18:50:35.017579"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 109], ["created_at", "2016-11-06 18:50:35.030207"], ["updated_at", "2016-11-06 18:50:35.030207"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 109], ["created_at", "2016-11-06 18:50:35.036361"], ["updated_at", "2016-11-06 18:50:35.036361"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.8ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:50:37.174439"], ["updated_at", "2016-11-06 18:50:37.174439"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:50:37.180790"], ["updated_at", "2016-11-06 18:50:37.180790"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:50:37.189403"], ["updated_at", "2016-11-06 18:50:37.189403"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:50:37.195347"], ["updated_at", "2016-11-06 18:50:37.195347"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:52:36.654546"], ["updated_at", "2016-11-06 18:52:36.654546"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:52:36.662886"], ["updated_at", "2016-11-06 18:52:36.662886"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:52:36.674487"], ["updated_at", "2016-11-06 18:52:36.674487"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:52:36.681013"], ["updated_at", "2016-11-06 18:52:36.681013"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (1.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:52:38.747479"], ["updated_at", "2016-11-06 18:52:38.747479"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 110], ["created_at", "2016-11-06 18:52:38.764983"], ["updated_at", "2016-11-06 18:52:38.764983"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 110], ["created_at", "2016-11-06 18:52:38.776400"], ["updated_at", "2016-11-06 18:52:38.776400"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 110], ["created_at", "2016-11-06 18:52:38.782452"], ["updated_at", "2016-11-06 18:52:38.782452"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:52:40.886864"], ["updated_at", "2016-11-06 18:52:40.886864"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:52:40.892345"], ["updated_at", "2016-11-06 18:52:40.892345"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:52:40.897732"], ["updated_at", "2016-11-06 18:52:40.897732"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:52:40.903212"], ["updated_at", "2016-11-06 18:52:40.903212"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:52:40.908238"], ["updated_at", "2016-11-06 18:52:40.908238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:53:35.163816"], ["updated_at", "2016-11-06 18:53:35.163816"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 111], ["created_at", "2016-11-06 18:53:35.199725"], ["updated_at", "2016-11-06 18:53:35.199725"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 111], ["created_at", "2016-11-06 18:53:35.227676"], ["updated_at", "2016-11-06 18:53:35.227676"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 111], ["created_at", "2016-11-06 18:53:35.233256"], ["updated_at", "2016-11-06 18:53:35.233256"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (1.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:53:37.339975"], ["updated_at", "2016-11-06 18:53:37.339975"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:53:37.345234"], ["updated_at", "2016-11-06 18:53:37.345234"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:53:37.350852"], ["updated_at", "2016-11-06 18:53:37.350852"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:53:37.357388"], ["updated_at", "2016-11-06 18:53:37.357388"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:53:39.425535"], ["updated_at", "2016-11-06 18:53:39.425535"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:53:39.430316"], ["updated_at", "2016-11-06 18:53:39.430316"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:53:39.435594"], ["updated_at", "2016-11-06 18:53:39.435594"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:53:39.440396"], ["updated_at", "2016-11-06 18:53:39.440396"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:53:39.445985"], ["updated_at", "2016-11-06 18:53:39.445985"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}}  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:53:51.991170"], ["updated_at", "2016-11-06 18:53:51.991170"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 112], ["created_at", "2016-11-06 18:53:52.013474"], ["updated_at", "2016-11-06 18:53:52.013474"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 112], ["created_at", "2016-11-06 18:53:52.025491"], ["updated_at", "2016-11-06 18:53:52.025491"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 112], ["created_at", "2016-11-06 18:53:52.031797"], ["updated_at", "2016-11-06 18:53:52.031797"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:53:54.141317"], ["updated_at", "2016-11-06 18:53:54.141317"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:53:54.146499"], ["updated_at", "2016-11-06 18:53:54.146499"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:53:54.152367"], ["updated_at", "2016-11-06 18:53:54.152367"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:53:54.157589"], ["updated_at", "2016-11-06 18:53:54.157589"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:53:56.222891"], ["updated_at", "2016-11-06 18:53:56.222891"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:53:56.227464"], ["updated_at", "2016-11-06 18:53:56.227464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:53:56.232469"], ["updated_at", "2016-11-06 18:53:56.232469"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:53:56.237823"], ["updated_at", "2016-11-06 18:53:56.237823"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:53:56.243889"], ["updated_at", "2016-11-06 18:53:56.243889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}}  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:54:13.615416"], ["updated_at", "2016-11-06 18:54:13.615416"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:54:13.635998"], ["updated_at", "2016-11-06 18:54:13.635998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:54:13.646373"], ["updated_at", "2016-11-06 18:54:13.646373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:54:13.652005"], ["updated_at", "2016-11-06 18:54:13.652005"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:54:13.657072"], ["updated_at", "2016-11-06 18:54:13.657072"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (1.4ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (3.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:54:15.751053"], ["updated_at", "2016-11-06 18:54:15.751053"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:54:15.756238"], ["updated_at", "2016-11-06 18:54:15.756238"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:54:15.761598"], ["updated_at", "2016-11-06 18:54:15.761598"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:54:15.766676"], ["updated_at", "2016-11-06 18:54:15.766676"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:54:17.832374"], ["updated_at", "2016-11-06 18:54:17.832374"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 113], ["created_at", "2016-11-06 18:54:17.852848"], ["updated_at", "2016-11-06 18:54:17.852848"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 113], ["created_at", "2016-11-06 18:54:17.874232"], ["updated_at", "2016-11-06 18:54:17.874232"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 113], ["created_at", "2016-11-06 18:54:17.880034"], ["updated_at", "2016-11-06 18:54:17.880034"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (1.0ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (2.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:59:10.798137"], ["updated_at", "2016-11-06 18:59:10.798137"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 114], ["created_at", "2016-11-06 18:59:10.860617"], ["updated_at", "2016-11-06 18:59:10.860617"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 114], ["created_at", "2016-11-06 18:59:10.892638"], ["updated_at", "2016-11-06 18:59:10.892638"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 114], ["created_at", "2016-11-06 18:59:10.899095"], ["updated_at", "2016-11-06 18:59:10.899095"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:59:13.007064"], ["updated_at", "2016-11-06 18:59:13.007064"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:59:13.012853"], ["updated_at", "2016-11-06 18:59:13.012853"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:59:13.018865"], ["updated_at", "2016-11-06 18:59:13.018865"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:59:13.023998"], ["updated_at", "2016-11-06 18:59:13.023998"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:59:13.028810"], ["updated_at", "2016-11-06 18:59:13.028810"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}}  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:59:15.121823"], ["updated_at", "2016-11-06 18:59:15.121823"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:59:15.143591"], ["updated_at", "2016-11-06 18:59:15.143591"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:59:15.150001"], ["updated_at", "2016-11-06 18:59:15.150001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:59:15.157643"], ["updated_at", "2016-11-06 18:59:15.157643"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:59:35.659461"], ["updated_at", "2016-11-06 18:59:35.659461"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:59:35.680064"], ["updated_at", "2016-11-06 18:59:35.680064"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:59:35.690624"], ["updated_at", "2016-11-06 18:59:35.690624"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:59:35.695822"], ["updated_at", "2016-11-06 18:59:35.695822"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 18:59:35.700487"], ["updated_at", "2016-11-06 18:59:35.700487"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}}  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 18:59:37.782499"], ["updated_at", "2016-11-06 18:59:37.782499"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 115], ["created_at", "2016-11-06 18:59:37.804012"], ["updated_at", "2016-11-06 18:59:37.804012"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 115], ["created_at", "2016-11-06 18:59:37.830994"], ["updated_at", "2016-11-06 18:59:37.830994"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 115], ["created_at", "2016-11-06 18:59:37.837483"], ["updated_at", "2016-11-06 18:59:37.837483"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 18:59:39.941798"], ["updated_at", "2016-11-06 18:59:39.941798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 18:59:39.950655"], ["updated_at", "2016-11-06 18:59:39.950655"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 18:59:39.956014"], ["updated_at", "2016-11-06 18:59:39.956014"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 18:59:39.961074"], ["updated_at", "2016-11-06 18:59:39.961074"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (1.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-06 19:01:41.990418"], ["updated_at", "2016-11-06 19:01:41.990418"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 116], ["created_at", "2016-11-06 19:01:42.031127"], ["updated_at", "2016-11-06 19:01:42.031127"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 116], ["created_at", "2016-11-06 19:01:42.059387"], ["updated_at", "2016-11-06 19:01:42.059387"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 116], ["created_at", "2016-11-06 19:01:42.065463"], ["updated_at", "2016-11-06 19:01:42.065463"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_uid=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{"name.raw"=>{:order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:asc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>[{:_script=>{:type=>"number", :script=>{:inline=>"if (_source.currency == 'USD') { doc['price'].value } else if (_source.currency == 'UYU') { doc['price'].value * 30 }"}, :order=>:desc}}]} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) {:query=>{:filtered=>{:filter=>{:bool=>{:must=>[]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 19:01:44.166614"], ["updated_at", "2016-11-06 19:01:44.166614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 19:01:44.172499"], ["updated_at", "2016-11-06 19:01:44.172499"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 19:01:44.178510"], ["updated_at", "2016-11-06 19:01:44.178510"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 19:01:44.183960"], ["updated_at", "2016-11-06 19:01:44.183960"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-06 19:01:44.189016"], ["updated_at", "2016-11-06 19:01:44.189016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 {:query=>{:match_all=>{}}, :from=>2, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) {:query=>{:match_all=>{}}, :from=>4, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 {:query=>{:match_all=>{}}, :from=>6, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-06 19:01:46.276394"], ["updated_at", "2016-11-06 19:01:46.276394"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-06 19:01:46.281645"], ["updated_at", "2016-11-06 19:01:46.281645"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-06 19:01:46.288544"], ["updated_at", "2016-11-06 19:01:46.288544"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-06 19:01:46.293731"], ["updated_at", "2016-11-06 19:01:46.293731"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 {:query=>{:match_all=>{}}, :from=>0, :size=>2, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) {:query=>{:filtered=>{:filter=>{:bool=>{:must_not=>[{:term=>{:_id=>3}}]}}, :query=>{:match_all=>{}}}}, :sort=>{:_uid=>{:order=>"desc"}}} Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (28.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (27.5ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:23:32.614101"], ["updated_at", "2016-11-09 15:23:32.614101"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 15:23:33.009416"], ["updated_at", "2016-11-09 15:23:33.009416"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 15:23:33.035804"], ["updated_at", "2016-11-09 15:23:33.035804"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (1.7ms) SAVEPOINT active_record_1 SQL (5.7ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 15:23:33.045446"], ["updated_at", "2016-11-09 15:23:33.045446"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 15:23:33.058845"], ["updated_at", "2016-11-09 15:23:33.058845"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (6.7ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:23:35.200444"], ["updated_at", "2016-11-09 15:23:35.200444"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.9ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:23:35.223817"], ["updated_at", "2016-11-09 15:23:35.223817"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (19.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 117], ["created_at", "2016-11-09 15:23:35.249198"], ["updated_at", "2016-11-09 15:23:35.249198"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:24:34.164812"], ["updated_at", "2016-11-09 15:24:34.164812"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 118], ["created_at", "2016-11-09 15:24:34.187620"], ["updated_at", "2016-11-09 15:24:34.187620"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:24:34.195679"], ["updated_at", "2016-11-09 15:24:34.195679"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:24:34.204396"], ["updated_at", "2016-11-09 15:24:34.204396"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:29:58.752722"], ["updated_at", "2016-11-09 15:29:58.752722"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:29:58.882096"], ["updated_at", "2016-11-09 15:29:58.882096"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 119], ["created_at", "2016-11-09 15:29:58.900766"], ["updated_at", "2016-11-09 15:29:58.900766"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:29:58.907657"], ["updated_at", "2016-11-09 15:29:58.907657"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:33:49.010415"], ["updated_at", "2016-11-09 15:33:49.010415"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (4.7ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 120], ["created_at", "2016-11-09 15:33:49.020695"], ["updated_at", "2016-11-09 15:33:49.020695"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:33:49.177359"], ["updated_at", "2016-11-09 15:33:49.177359"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:33:49.183370"], ["updated_at", "2016-11-09 15:33:49.183370"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:33:49.188863"], ["updated_at", "2016-11-09 15:33:49.188863"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 121], ["created_at", "2016-11-09 15:33:49.209000"], ["updated_at", "2016-11-09 15:33:49.209000"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:45:28.555932"], ["updated_at", "2016-11-09 15:45:28.555932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:45:28.701258"], ["updated_at", "2016-11-09 15:45:28.701258"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:45:28.707601"], ["updated_at", "2016-11-09 15:45:28.707601"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:45:28.714293"], ["updated_at", "2016-11-09 15:45:28.714293"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 123], ["created_at", "2016-11-09 15:45:28.725330"], ["updated_at", "2016-11-09 15:45:28.725330"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.4ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:46:10.112304"], ["updated_at", "2016-11-09 15:46:10.112304"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:46:33.163836"], ["updated_at", "2016-11-09 15:46:33.163836"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:46:47.476147"], ["updated_at", "2016-11-09 15:46:47.476147"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:46:51.802061"], ["updated_at", "2016-11-09 15:46:51.802061"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 125], ["created_at", "2016-11-09 15:46:51.810567"], ["updated_at", "2016-11-09 15:46:51.810567"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (1.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (1.0ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:48:43.768127"], ["updated_at", "2016-11-09 15:48:43.768127"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 126], ["created_at", "2016-11-09 15:48:43.783363"], ["updated_at", "2016-11-09 15:48:43.783363"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:48:46.544865"], ["updated_at", "2016-11-09 15:48:46.544865"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (3.4ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:48:52.443613"], ["updated_at", "2016-11-09 15:48:52.443613"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:48:55.403077"], ["updated_at", "2016-11-09 15:48:55.403077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:49:00.945942"], ["updated_at", "2016-11-09 15:49:00.945942"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 128], ["created_at", "2016-11-09 15:49:00.955612"], ["updated_at", "2016-11-09 15:49:00.955612"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:49:11.678668"], ["updated_at", "2016-11-09 15:49:11.678668"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:49:11.696588"], ["updated_at", "2016-11-09 15:49:11.696588"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:49:11.724893"], ["updated_at", "2016-11-09 15:49:11.724893"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:49:35.736495"], ["updated_at", "2016-11-09 15:49:35.736495"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 130], ["created_at", "2016-11-09 15:49:35.746950"], ["updated_at", "2016-11-09 15:49:35.746950"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:50:18.618566"], ["updated_at", "2016-11-09 15:50:18.618566"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (2.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:51:30.198499"], ["updated_at", "2016-11-09 15:51:30.198499"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 131], ["created_at", "2016-11-09 15:51:30.208891"], ["updated_at", "2016-11-09 15:51:30.208891"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:51:30.313550"], ["updated_at", "2016-11-09 15:51:30.313550"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:51:30.392028"], ["updated_at", "2016-11-09 15:51:30.392028"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:51:30.482251"], ["updated_at", "2016-11-09 15:51:30.482251"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:53:12.332003"], ["updated_at", "2016-11-09 15:53:12.332003"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 133], ["created_at", "2016-11-09 15:53:12.345066"], ["updated_at", "2016-11-09 15:53:12.345066"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:53:12.495299"], ["updated_at", "2016-11-09 15:53:12.495299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.3ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:53:12.501553"], ["updated_at", "2016-11-09 15:53:12.501553"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:53:12.506691"], ["updated_at", "2016-11-09 15:53:12.506691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 15:59:23.548562"], ["updated_at", "2016-11-09 15:59:23.548562"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 135], ["created_at", "2016-11-09 15:59:23.558686"], ["updated_at", "2016-11-09 15:59:23.558686"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:59:23.709232"], ["updated_at", "2016-11-09 15:59:23.709232"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 15:59:23.717448"], ["updated_at", "2016-11-09 15:59:23.717448"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 15:59:23.724508"], ["updated_at", "2016-11-09 15:59:23.724508"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 15:59:23.732431"], ["updated_at", "2016-11-09 15:59:23.732431"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 15:59:23.737510"], ["updated_at", "2016-11-09 15:59:23.737510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (6.7ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 15:59:25.805952"], ["updated_at", "2016-11-09 15:59:25.805952"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 15:59:25.810962"], ["updated_at", "2016-11-09 15:59:25.810962"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 136], ["created_at", "2016-11-09 15:59:25.823588"], ["updated_at", "2016-11-09 15:59:25.823588"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 16:00:29.695461"], ["updated_at", "2016-11-09 16:00:29.695461"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 137], ["created_at", "2016-11-09 16:00:29.706169"], ["updated_at", "2016-11-09 16:00:29.706169"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 16:00:29.859303"], ["updated_at", "2016-11-09 16:00:29.859303"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 16:00:29.865541"], ["updated_at", "2016-11-09 16:00:29.865541"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 16:00:29.870986"], ["updated_at", "2016-11-09 16:00:29.870986"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 138], ["created_at", "2016-11-09 16:00:29.891371"], ["updated_at", "2016-11-09 16:00:29.891371"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 138], ["created_at", "2016-11-09 16:00:29.899777"], ["updated_at", "2016-11-09 16:00:29.899777"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 138], ["created_at", "2016-11-09 16:00:29.906909"], ["updated_at", "2016-11-09 16:00:29.906909"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3, 76, 78) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (78, 76, 3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3, 78, 76) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (78, 76, 3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (78, 76, 3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (78, 76, 3, 2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 16:05:15.532124"], ["updated_at", "2016-11-09 16:05:15.532124"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 16:05:15.662587"], ["updated_at", "2016-11-09 16:05:15.662587"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 139], ["created_at", "2016-11-09 16:05:15.681586"], ["updated_at", "2016-11-09 16:05:15.681586"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 16:05:15.689336"], ["updated_at", "2016-11-09 16:05:15.689336"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 16:05:15.727505"], ["updated_at", "2016-11-09 16:05:15.727505"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 140], ["created_at", "2016-11-09 16:05:15.729401"], ["updated_at", "2016-11-09 16:05:15.729401"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.6ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (78, 76, 3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (1.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:12:21.668134"], ["updated_at", "2016-11-09 17:12:21.668134"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (1.5ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 141], ["created_at", "2016-11-09 17:12:21.756795"], ["updated_at", "2016-11-09 17:12:21.756795"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:12:21.795435"], ["updated_at", "2016-11-09 17:12:21.795435"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:12:21.842347"], ["updated_at", "2016-11-09 17:12:21.842347"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:12:21.850350"], ["updated_at", "2016-11-09 17:12:21.850350"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:12:21.856379"], ["updated_at", "2016-11-09 17:12:21.856379"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:12:23.930879"], ["updated_at", "2016-11-09 17:12:23.930879"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:12:23.970695"], ["updated_at", "2016-11-09 17:12:23.970695"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:12:23.976841"], ["updated_at", "2016-11-09 17:12:23.976841"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:12:23.983102"], ["updated_at", "2016-11-09 17:12:23.983102"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:12:23.988661"], ["updated_at", "2016-11-09 17:12:23.988661"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:12:26.065286"], ["updated_at", "2016-11-09 17:12:26.065286"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 142], ["created_at", "2016-11-09 17:12:26.066867"], ["updated_at", "2016-11-09 17:12:26.066867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.8ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:13:07.403277"], ["updated_at", "2016-11-09 17:13:07.403277"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 143], ["created_at", "2016-11-09 17:13:07.459211"], ["updated_at", "2016-11-09 17:13:07.459211"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:13:14.309149"], ["updated_at", "2016-11-09 17:13:14.309149"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:13:14.351492"], ["updated_at", "2016-11-09 17:13:14.351492"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:13:14.358386"], ["updated_at", "2016-11-09 17:13:14.358386"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:13:14.364738"], ["updated_at", "2016-11-09 17:13:14.364738"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:13:16.405107"], ["updated_at", "2016-11-09 17:13:16.405107"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:13:16.444317"], ["updated_at", "2016-11-09 17:13:16.444317"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:13:16.452763"], ["updated_at", "2016-11-09 17:13:16.452763"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:13:16.461604"], ["updated_at", "2016-11-09 17:13:16.461604"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:13:16.468780"], ["updated_at", "2016-11-09 17:13:16.468780"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:13:18.553090"], ["updated_at", "2016-11-09 17:13:18.553090"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 144], ["created_at", "2016-11-09 17:13:18.554870"], ["updated_at", "2016-11-09 17:13:18.554870"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing -------------------------  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:13:29.372819"], ["updated_at", "2016-11-09 17:13:29.372819"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 145], ["created_at", "2016-11-09 17:13:29.382813"], ["updated_at", "2016-11-09 17:13:29.382813"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ----------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:14:14.726690"], ["updated_at", "2016-11-09 17:14:14.726690"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 146], ["created_at", "2016-11-09 17:14:14.779322"], ["updated_at", "2016-11-09 17:14:14.779322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination ---------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:16:01.354452"], ["updated_at", "2016-11-09 17:16:01.354452"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:16:01.391252"], ["updated_at", "2016-11-09 17:16:01.391252"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:16:01.400007"], ["updated_at", "2016-11-09 17:16:01.400007"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:16:01.408128"], ["updated_at", "2016-11-09 17:16:01.408128"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:16:01.419432"], ["updated_at", "2016-11-09 17:16:01.419432"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without ---------------------------------  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:16:03.490460"], ["updated_at", "2016-11-09 17:16:03.490460"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:16:03.526235"], ["updated_at", "2016-11-09 17:16:03.526235"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:16:03.532797"], ["updated_at", "2016-11-09 17:16:03.532797"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:16:03.539139"], ["updated_at", "2016-11-09 17:16:03.539139"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:16:16.211718"], ["updated_at", "2016-11-09 17:16:16.211718"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 147], ["created_at", "2016-11-09 17:16:16.223891"], ["updated_at", "2016-11-09 17:16:16.223891"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE 1=0  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:16:16.331237"], ["updated_at", "2016-11-09 17:16:16.331237"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:16:16.337682"], ["updated_at", "2016-11-09 17:16:16.337682"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:16:16.344595"], ["updated_at", "2016-11-09 17:16:16.344595"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:16:16.350582"], ["updated_at", "2016-11-09 17:16:16.350582"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:16:18.433270"], ["updated_at", "2016-11-09 17:16:18.433270"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 148], ["created_at", "2016-11-09 17:16:18.454606"], ["updated_at", "2016-11-09 17:16:18.454606"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 148], ["created_at", "2016-11-09 17:16:18.467524"], ["updated_at", "2016-11-09 17:16:18.467524"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 148], ["created_at", "2016-11-09 17:16:18.474619"], ["updated_at", "2016-11-09 17:16:18.474619"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.8ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:16:20.628850"], ["updated_at", "2016-11-09 17:16:20.628850"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:16:20.635989"], ["updated_at", "2016-11-09 17:16:20.635989"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:16:20.643774"], ["updated_at", "2016-11-09 17:16:20.643774"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:16:20.650703"], ["updated_at", "2016-11-09 17:16:20.650703"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:16:20.659034"], ["updated_at", "2016-11-09 17:16:20.659034"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:17:11.959260"], ["updated_at", "2016-11-09 17:17:11.959260"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:17:12.031550"], ["updated_at", "2016-11-09 17:17:12.031550"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (1.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:17:12.100466"], ["updated_at", "2016-11-09 17:17:12.100466"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:17:12.190411"], ["updated_at", "2016-11-09 17:17:12.190411"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 150], ["created_at", "2016-11-09 17:17:12.199995"], ["updated_at", "2016-11-09 17:17:12.199995"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.5ms) SELECT "products".* FROM "products" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:17:21.983475"], ["updated_at", "2016-11-09 17:17:21.983475"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:17:21.992218"], ["updated_at", "2016-11-09 17:17:21.992218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:17:21.998296"], ["updated_at", "2016-11-09 17:17:21.998296"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:17:22.004995"], ["updated_at", "2016-11-09 17:17:22.004995"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:17:24.084319"], ["updated_at", "2016-11-09 17:17:24.084319"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 151], ["created_at", "2016-11-09 17:17:24.104919"], ["updated_at", "2016-11-09 17:17:24.104919"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 151], ["created_at", "2016-11-09 17:17:24.122847"], ["updated_at", "2016-11-09 17:17:24.122847"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 151], ["created_at", "2016-11-09 17:17:24.131465"], ["updated_at", "2016-11-09 17:17:24.131465"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:17:26.265975"], ["updated_at", "2016-11-09 17:17:26.265975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:17:26.273154"], ["updated_at", "2016-11-09 17:17:26.273154"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:17:26.280562"], ["updated_at", "2016-11-09 17:17:26.280562"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:17:26.288832"], ["updated_at", "2016-11-09 17:17:26.288832"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:17:26.295532"], ["updated_at", "2016-11-09 17:17:26.295532"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:17:28.463821"], ["updated_at", "2016-11-09 17:17:28.463821"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 152], ["created_at", "2016-11-09 17:17:28.465627"], ["updated_at", "2016-11-09 17:17:28.465627"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:17:59.121095"], ["updated_at", "2016-11-09 17:17:59.121095"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:17:59.129538"], ["updated_at", "2016-11-09 17:17:59.129538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:17:59.135716"], ["updated_at", "2016-11-09 17:17:59.135716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:17:59.141230"], ["updated_at", "2016-11-09 17:17:59.141230"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:17:59.145818"], ["updated_at", "2016-11-09 17:17:59.145818"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:18:01.254690"], ["updated_at", "2016-11-09 17:18:01.254690"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 153], ["created_at", "2016-11-09 17:18:01.280884"], ["updated_at", "2016-11-09 17:18:01.280884"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 153], ["created_at", "2016-11-09 17:18:01.295690"], ["updated_at", "2016-11-09 17:18:01.295690"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 153], ["created_at", "2016-11-09 17:18:01.302650"], ["updated_at", "2016-11-09 17:18:01.302650"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (1.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:18:03.434074"], ["updated_at", "2016-11-09 17:18:03.434074"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:18:03.440726"], ["updated_at", "2016-11-09 17:18:03.440726"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:18:03.453020"], ["updated_at", "2016-11-09 17:18:03.453020"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:18:03.461510"], ["updated_at", "2016-11-09 17:18:03.461510"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:18:05.585867"], ["updated_at", "2016-11-09 17:18:05.585867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 154], ["created_at", "2016-11-09 17:18:05.587728"], ["updated_at", "2016-11-09 17:18:05.587728"]]  (0.4ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 86  (0.2ms) SAVEPOINT active_record_1 SQL (0.8ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 86]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.3ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.7ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:18:37.209683"], ["updated_at", "2016-11-09 17:18:37.209683"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 155], ["created_at", "2016-11-09 17:18:37.227235"], ["updated_at", "2016-11-09 17:18:37.227235"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 87  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 87]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 87  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:18:39.358677"], ["updated_at", "2016-11-09 17:18:39.358677"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 156], ["created_at", "2016-11-09 17:18:39.378780"], ["updated_at", "2016-11-09 17:18:39.378780"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 156], ["created_at", "2016-11-09 17:18:39.390666"], ["updated_at", "2016-11-09 17:18:39.390666"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 156], ["created_at", "2016-11-09 17:18:39.406383"], ["updated_at", "2016-11-09 17:18:39.406383"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:18:41.522936"], ["updated_at", "2016-11-09 17:18:41.522936"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:18:41.528828"], ["updated_at", "2016-11-09 17:18:41.528828"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:18:41.534832"], ["updated_at", "2016-11-09 17:18:41.534832"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:18:41.540394"], ["updated_at", "2016-11-09 17:18:41.540394"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:18:41.546421"], ["updated_at", "2016-11-09 17:18:41.546421"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (4.5ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:18:43.647322"], ["updated_at", "2016-11-09 17:18:43.647322"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:18:43.653518"], ["updated_at", "2016-11-09 17:18:43.653518"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:18:43.663952"], ["updated_at", "2016-11-09 17:18:43.663952"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:18:43.669782"], ["updated_at", "2016-11-09 17:18:43.669782"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:21:21.096306"], ["updated_at", "2016-11-09 17:21:21.096306"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 157], ["created_at", "2016-11-09 17:21:21.110022"], ["updated_at", "2016-11-09 17:21:21.110022"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 88  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 88]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE 1=0  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:21:23.227414"], ["updated_at", "2016-11-09 17:21:23.227414"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 158], ["created_at", "2016-11-09 17:21:23.248580"], ["updated_at", "2016-11-09 17:21:23.248580"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 158], ["created_at", "2016-11-09 17:21:23.259357"], ["updated_at", "2016-11-09 17:21:23.259357"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 158], ["created_at", "2016-11-09 17:21:23.266970"], ["updated_at", "2016-11-09 17:21:23.266970"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:21:25.358601"], ["updated_at", "2016-11-09 17:21:25.358601"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:21:25.363908"], ["updated_at", "2016-11-09 17:21:25.363908"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:21:25.369498"], ["updated_at", "2016-11-09 17:21:25.369498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:21:25.374373"], ["updated_at", "2016-11-09 17:21:25.374373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:21:25.378932"], ["updated_at", "2016-11-09 17:21:25.378932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:21:27.461877"], ["updated_at", "2016-11-09 17:21:27.461877"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:21:27.467477"], ["updated_at", "2016-11-09 17:21:27.467477"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:21:27.473165"], ["updated_at", "2016-11-09 17:21:27.473165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:21:27.478885"], ["updated_at", "2016-11-09 17:21:27.478885"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 17:25:04.337222"], ["updated_at", "2016-11-09 17:25:04.337222"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 159], ["created_at", "2016-11-09 17:25:04.348777"], ["updated_at", "2016-11-09 17:25:04.348777"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 89  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 89]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 89  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.3ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:25:06.476499"], ["updated_at", "2016-11-09 17:25:06.476499"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:25:06.482659"], ["updated_at", "2016-11-09 17:25:06.482659"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:25:06.488141"], ["updated_at", "2016-11-09 17:25:06.488141"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:25:06.494261"], ["updated_at", "2016-11-09 17:25:06.494261"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 17:25:06.499631"], ["updated_at", "2016-11-09 17:25:06.499631"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 17:25:08.591074"], ["updated_at", "2016-11-09 17:25:08.591074"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 160], ["created_at", "2016-11-09 17:25:08.611901"], ["updated_at", "2016-11-09 17:25:08.611901"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 160], ["created_at", "2016-11-09 17:25:08.624488"], ["updated_at", "2016-11-09 17:25:08.624488"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 160], ["created_at", "2016-11-09 17:25:08.631709"], ["updated_at", "2016-11-09 17:25:08.631709"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 17:25:10.742774"], ["updated_at", "2016-11-09 17:25:10.742774"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 17:25:10.752800"], ["updated_at", "2016-11-09 17:25:10.752800"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 17:25:10.759787"], ["updated_at", "2016-11-09 17:25:10.759787"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 17:25:10.770267"], ["updated_at", "2016-11-09 17:25:10.770267"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 19:50:46.784975"], ["updated_at", "2016-11-09 19:50:46.784975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 19:50:46.805382"], ["updated_at", "2016-11-09 19:50:46.805382"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 19:50:46.815933"], ["updated_at", "2016-11-09 19:50:46.815933"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 19:50:46.821250"], ["updated_at", "2016-11-09 19:50:46.821250"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 19:50:46.826075"], ["updated_at", "2016-11-09 19:50:46.826075"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 19:50:48.927973"], ["updated_at", "2016-11-09 19:50:48.927973"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 161], ["created_at", "2016-11-09 19:50:48.949265"], ["updated_at", "2016-11-09 19:50:48.949265"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 161], ["created_at", "2016-11-09 19:50:48.977242"], ["updated_at", "2016-11-09 19:50:48.977242"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 161], ["created_at", "2016-11-09 19:50:48.982911"], ["updated_at", "2016-11-09 19:50:48.982911"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 19:50:51.084284"], ["updated_at", "2016-11-09 19:50:51.084284"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 19:50:51.089188"], ["updated_at", "2016-11-09 19:50:51.089188"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 19:50:51.094204"], ["updated_at", "2016-11-09 19:50:51.094204"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 19:50:51.099249"], ["updated_at", "2016-11-09 19:50:51.099249"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 19:50:53.593909"], ["updated_at", "2016-11-09 19:50:53.593909"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 162], ["created_at", "2016-11-09 19:50:53.595876"], ["updated_at", "2016-11-09 19:50:53.595876"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 90  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 90]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 90  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 19:51:33.585208"], ["updated_at", "2016-11-09 19:51:33.585208"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 163], ["created_at", "2016-11-09 19:51:33.595784"], ["updated_at", "2016-11-09 19:51:33.595784"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 91  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 91]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 91  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 19:51:35.807187"], ["updated_at", "2016-11-09 19:51:35.807187"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 164], ["created_at", "2016-11-09 19:51:35.825311"], ["updated_at", "2016-11-09 19:51:35.825311"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 164], ["created_at", "2016-11-09 19:51:35.838784"], ["updated_at", "2016-11-09 19:51:35.838784"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 164], ["created_at", "2016-11-09 19:51:35.846718"], ["updated_at", "2016-11-09 19:51:35.846718"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 19:51:37.950621"], ["updated_at", "2016-11-09 19:51:37.950621"]]  (0.7ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 19:51:37.956875"], ["updated_at", "2016-11-09 19:51:37.956875"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 19:51:37.962704"], ["updated_at", "2016-11-09 19:51:37.962704"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 19:51:37.969264"], ["updated_at", "2016-11-09 19:51:37.969264"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 19:51:40.035719"], ["updated_at", "2016-11-09 19:51:40.035719"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 19:51:40.041200"], ["updated_at", "2016-11-09 19:51:40.041200"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 19:51:40.046450"], ["updated_at", "2016-11-09 19:51:40.046450"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 19:51:40.051119"], ["updated_at", "2016-11-09 19:51:40.051119"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 19:51:40.055641"], ["updated_at", "2016-11-09 19:51:40.055641"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.4ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 19:52:04.067066"], ["updated_at", "2016-11-09 19:52:04.067066"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 165], ["created_at", "2016-11-09 19:52:04.077978"], ["updated_at", "2016-11-09 19:52:04.077978"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 92  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 92]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 92  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 19:52:14.330521"], ["updated_at", "2016-11-09 19:52:14.330521"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 166], ["created_at", "2016-11-09 19:52:14.353498"], ["updated_at", "2016-11-09 19:52:14.353498"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 166], ["created_at", "2016-11-09 19:52:14.365160"], ["updated_at", "2016-11-09 19:52:14.365160"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 166], ["created_at", "2016-11-09 19:52:14.373515"], ["updated_at", "2016-11-09 19:52:14.373515"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 19:52:18.473890"], ["updated_at", "2016-11-09 19:52:18.473890"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 19:52:18.483334"], ["updated_at", "2016-11-09 19:52:18.483334"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 19:52:18.488212"], ["updated_at", "2016-11-09 19:52:18.488212"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 19:52:18.492560"], ["updated_at", "2016-11-09 19:52:18.492560"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 19:52:18.496720"], ["updated_at", "2016-11-09 19:52:18.496720"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 19:52:22.579944"], ["updated_at", "2016-11-09 19:52:22.579944"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 19:52:22.588739"], ["updated_at", "2016-11-09 19:52:22.588739"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 19:52:22.593706"], ["updated_at", "2016-11-09 19:52:22.593706"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 19:52:22.598290"], ["updated_at", "2016-11-09 19:52:22.598290"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000 ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:03:43.013652"], ["updated_at", "2016-11-09 20:03:43.013652"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 167], ["created_at", "2016-11-09 20:03:43.033596"], ["updated_at", "2016-11-09 20:03:43.033596"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 167], ["created_at", "2016-11-09 20:03:43.043165"], ["updated_at", "2016-11-09 20:03:43.043165"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 167], ["created_at", "2016-11-09 20:03:43.049214"], ["updated_at", "2016-11-09 20:03:43.049214"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:03:45.147280"], ["updated_at", "2016-11-09 20:03:45.147280"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:03:45.152612"], ["updated_at", "2016-11-09 20:03:45.152612"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:03:45.157691"], ["updated_at", "2016-11-09 20:03:45.157691"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:03:45.162392"], ["updated_at", "2016-11-09 20:03:45.162392"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 20:03:45.166916"], ["updated_at", "2016-11-09 20:03:45.166916"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:03:47.251897"], ["updated_at", "2016-11-09 20:03:47.251897"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:03:47.256916"], ["updated_at", "2016-11-09 20:03:47.256916"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:03:47.262209"], ["updated_at", "2016-11-09 20:03:47.262209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:03:47.267230"], ["updated_at", "2016-11-09 20:03:47.267230"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 20:03:49.484701"], ["updated_at", "2016-11-09 20:03:49.484701"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 168], ["created_at", "2016-11-09 20:03:49.487383"], ["updated_at", "2016-11-09 20:03:49.487383"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 93  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 93]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 93  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:23:29.512434"], ["updated_at", "2016-11-09 20:23:29.512434"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 169], ["created_at", "2016-11-09 20:23:29.532570"], ["updated_at", "2016-11-09 20:23:29.532570"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 169], ["created_at", "2016-11-09 20:23:29.543242"], ["updated_at", "2016-11-09 20:23:29.543242"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:25:03.974210"], ["updated_at", "2016-11-09 20:25:03.974210"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 170], ["created_at", "2016-11-09 20:25:03.989851"], ["updated_at", "2016-11-09 20:25:03.989851"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 170], ["created_at", "2016-11-09 20:25:03.998775"], ["updated_at", "2016-11-09 20:25:03.998775"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:25:33.326576"], ["updated_at", "2016-11-09 20:25:33.326576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 171], ["created_at", "2016-11-09 20:25:33.345244"], ["updated_at", "2016-11-09 20:25:33.345244"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:26:56.831739"], ["updated_at", "2016-11-09 20:26:56.831739"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 172], ["created_at", "2016-11-09 20:26:56.848628"], ["updated_at", "2016-11-09 20:26:56.848628"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 172], ["created_at", "2016-11-09 20:26:56.863917"], ["updated_at", "2016-11-09 20:26:56.863917"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:27:45.851781"], ["updated_at", "2016-11-09 20:27:45.851781"]]  (0.3ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 173], ["created_at", "2016-11-09 20:27:45.870533"], ["updated_at", "2016-11-09 20:27:45.870533"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 173], ["created_at", "2016-11-09 20:27:45.878638"], ["updated_at", "2016-11-09 20:27:45.878638"]]  (0.5ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:32:12.792308"], ["updated_at", "2016-11-09 20:32:12.792308"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 174], ["created_at", "2016-11-09 20:32:12.813842"], ["updated_at", "2016-11-09 20:32:12.813842"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 174], ["created_at", "2016-11-09 20:32:12.833694"], ["updated_at", "2016-11-09 20:32:12.833694"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:36:44.496591"], ["updated_at", "2016-11-09 20:36:44.496591"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 175], ["created_at", "2016-11-09 20:36:44.512250"], ["updated_at", "2016-11-09 20:36:44.512250"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 175], ["created_at", "2016-11-09 20:36:44.519569"], ["updated_at", "2016-11-09 20:36:44.519569"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.5ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:38:22.071607"], ["updated_at", "2016-11-09 20:38:22.071607"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 176], ["created_at", "2016-11-09 20:38:22.087719"], ["updated_at", "2016-11-09 20:38:22.087719"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 176], ["created_at", "2016-11-09 20:38:22.094211"], ["updated_at", "2016-11-09 20:38:22.094211"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:38:24.256293"], ["updated_at", "2016-11-09 20:38:24.256293"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:38:24.262247"], ["updated_at", "2016-11-09 20:38:24.262247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:38:24.267278"], ["updated_at", "2016-11-09 20:38:24.267278"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:38:24.273417"], ["updated_at", "2016-11-09 20:38:24.273417"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 20:38:24.278648"], ["updated_at", "2016-11-09 20:38:24.278648"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:38:26.373331"], ["updated_at", "2016-11-09 20:38:26.373331"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 177], ["created_at", "2016-11-09 20:38:26.379867"], ["updated_at", "2016-11-09 20:38:26.379867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 177], ["created_at", "2016-11-09 20:38:26.388230"], ["updated_at", "2016-11-09 20:38:26.388230"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 177], ["created_at", "2016-11-09 20:38:26.394798"], ["updated_at", "2016-11-09 20:38:26.394798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE 1=0  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:38:28.544145"], ["updated_at", "2016-11-09 20:38:28.544145"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:38:28.549197"], ["updated_at", "2016-11-09 20:38:28.549197"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:38:28.553999"], ["updated_at", "2016-11-09 20:38:28.553999"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:38:28.558576"], ["updated_at", "2016-11-09 20:38:28.558576"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 20:38:30.618476"], ["updated_at", "2016-11-09 20:38:30.618476"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 178], ["created_at", "2016-11-09 20:38:30.620438"], ["updated_at", "2016-11-09 20:38:30.620438"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 109  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 109]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 109  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.6ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.2ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (9.5ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 20:39:38.088926"], ["updated_at", "2016-11-09 20:39:38.088926"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 179], ["created_at", "2016-11-09 20:39:38.114039"], ["updated_at", "2016-11-09 20:39:38.114039"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 110  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 110]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 110  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:39:40.185450"], ["updated_at", "2016-11-09 20:39:40.185450"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 180], ["created_at", "2016-11-09 20:39:40.194214"], ["updated_at", "2016-11-09 20:39:40.194214"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 180], ["created_at", "2016-11-09 20:39:40.203342"], ["updated_at", "2016-11-09 20:39:40.203342"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 180], ["created_at", "2016-11-09 20:39:40.211254"], ["updated_at", "2016-11-09 20:39:40.211254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE 1=0  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:39:42.311893"], ["updated_at", "2016-11-09 20:39:42.311893"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:39:42.318213"], ["updated_at", "2016-11-09 20:39:42.318213"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:39:42.325074"], ["updated_at", "2016-11-09 20:39:42.325074"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:39:42.331055"], ["updated_at", "2016-11-09 20:39:42.331055"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 20:39:42.339009"], ["updated_at", "2016-11-09 20:39:42.339009"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:39:44.428822"], ["updated_at", "2016-11-09 20:39:44.428822"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:39:44.435185"], ["updated_at", "2016-11-09 20:39:44.435185"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:39:44.441065"], ["updated_at", "2016-11-09 20:39:44.441065"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:39:44.447877"], ["updated_at", "2016-11-09 20:39:44.447877"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:39:46.608098"], ["updated_at", "2016-11-09 20:39:46.608098"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 181], ["created_at", "2016-11-09 20:39:46.610016"], ["updated_at", "2016-11-09 20:39:46.610016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 181], ["created_at", "2016-11-09 20:39:46.617892"], ["updated_at", "2016-11-09 20:39:46.617892"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:44:47.819226"], ["updated_at", "2016-11-09 20:44:47.819226"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:44:47.826673"], ["updated_at", "2016-11-09 20:44:47.826673"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:44:47.831693"], ["updated_at", "2016-11-09 20:44:47.831693"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:44:47.836472"], ["updated_at", "2016-11-09 20:44:47.836472"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 20:44:47.847170"], ["updated_at", "2016-11-09 20:44:47.847170"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 20:44:49.923550"], ["updated_at", "2016-11-09 20:44:49.923550"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 20:44:49.928578"], ["updated_at", "2016-11-09 20:44:49.928578"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 20:44:49.933130"], ["updated_at", "2016-11-09 20:44:49.933130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 20:44:49.937888"], ["updated_at", "2016-11-09 20:44:49.937888"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:44:51.993074"], ["updated_at", "2016-11-09 20:44:51.993074"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 182], ["created_at", "2016-11-09 20:44:52.022450"], ["updated_at", "2016-11-09 20:44:52.022450"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 182], ["created_at", "2016-11-09 20:44:52.032170"], ["updated_at", "2016-11-09 20:44:52.032170"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 182], ["created_at", "2016-11-09 20:44:52.039702"], ["updated_at", "2016-11-09 20:44:52.039702"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.7ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 20:44:54.325796"], ["updated_at", "2016-11-09 20:44:54.325796"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 183], ["created_at", "2016-11-09 20:44:54.327549"], ["updated_at", "2016-11-09 20:44:54.327549"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 183], ["created_at", "2016-11-09 20:44:54.333774"], ["updated_at", "2016-11-09 20:44:54.333774"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 20:44:56.384150"], ["updated_at", "2016-11-09 20:44:56.384150"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 184], ["created_at", "2016-11-09 20:44:56.386496"], ["updated_at", "2016-11-09 20:44:56.386496"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 115  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 115]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 115  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:23:23.830071"], ["updated_at", "2016-11-09 21:23:23.830071"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:23:23.855123"], ["updated_at", "2016-11-09 21:23:23.855123"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:23:23.860212"], ["updated_at", "2016-11-09 21:23:23.860212"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:23:23.881703"], ["updated_at", "2016-11-09 21:23:23.881703"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:23:25.939190"], ["updated_at", "2016-11-09 21:23:25.939190"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("shop_id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["shop_id", 185], ["created_at", "2016-11-09 21:23:25.956151"], ["updated_at", "2016-11-09 21:23:25.956151"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:23:25.996867"], ["updated_at", "2016-11-09 21:23:25.996867"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:23:26.001697"], ["updated_at", "2016-11-09 21:23:26.001697"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:23:26.006198"], ["updated_at", "2016-11-09 21:23:26.006198"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:23:26.010839"], ["updated_at", "2016-11-09 21:23:26.010839"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:23:26.015480"], ["updated_at", "2016-11-09 21:23:26.015480"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:23:28.081313"], ["updated_at", "2016-11-09 21:23:28.081313"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 186], ["created_at", "2016-11-09 21:23:28.092028"], ["updated_at", "2016-11-09 21:23:28.092028"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 186], ["created_at", "2016-11-09 21:23:28.098355"], ["updated_at", "2016-11-09 21:23:28.098355"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 186], ["created_at", "2016-11-09 21:23:28.104279"], ["updated_at", "2016-11-09 21:23:28.104279"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:24:06.572016"], ["updated_at", "2016-11-09 21:24:06.572016"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 187], ["created_at", "2016-11-09 21:24:06.587619"], ["updated_at", "2016-11-09 21:24:06.587619"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:24:08.636263"], ["updated_at", "2016-11-09 21:24:08.636263"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 188], ["created_at", "2016-11-09 21:24:08.642484"], ["updated_at", "2016-11-09 21:24:08.642484"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 188], ["created_at", "2016-11-09 21:24:08.651240"], ["updated_at", "2016-11-09 21:24:08.651240"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 188], ["created_at", "2016-11-09 21:24:08.657333"], ["updated_at", "2016-11-09 21:24:08.657333"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (4.7ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.5ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:24:10.749402"], ["updated_at", "2016-11-09 21:24:10.749402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:24:10.755019"], ["updated_at", "2016-11-09 21:24:10.755019"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:24:10.760396"], ["updated_at", "2016-11-09 21:24:10.760396"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:24:10.765247"], ["updated_at", "2016-11-09 21:24:10.765247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:24:12.821980"], ["updated_at", "2016-11-09 21:24:12.821980"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:24:12.826983"], ["updated_at", "2016-11-09 21:24:12.826983"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:24:12.831584"], ["updated_at", "2016-11-09 21:24:12.831584"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:24:12.836314"], ["updated_at", "2016-11-09 21:24:12.836314"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:24:12.840839"], ["updated_at", "2016-11-09 21:24:12.840839"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:24:34.062282"], ["updated_at", "2016-11-09 21:24:34.062282"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:24:34.069863"], ["updated_at", "2016-11-09 21:24:34.069863"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:24:34.074653"], ["updated_at", "2016-11-09 21:24:34.074653"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:24:34.079452"], ["updated_at", "2016-11-09 21:24:34.079452"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:24:34.086020"], ["updated_at", "2016-11-09 21:24:34.086020"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4)  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:24:36.144530"], ["updated_at", "2016-11-09 21:24:36.144530"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:24:36.149976"], ["updated_at", "2016-11-09 21:24:36.149976"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:24:36.155027"], ["updated_at", "2016-11-09 21:24:36.155027"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:24:36.160005"], ["updated_at", "2016-11-09 21:24:36.160005"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:24:38.217459"], ["updated_at", "2016-11-09 21:24:38.217459"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 189], ["created_at", "2016-11-09 21:24:38.233254"], ["updated_at", "2016-11-09 21:24:38.233254"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 118  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:24:40.301744"], ["updated_at", "2016-11-09 21:24:40.301744"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 190], ["created_at", "2016-11-09 21:24:40.308040"], ["updated_at", "2016-11-09 21:24:40.308040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 190], ["created_at", "2016-11-09 21:24:40.314281"], ["updated_at", "2016-11-09 21:24:40.314281"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 190], ["created_at", "2016-11-09 21:24:40.319586"], ["updated_at", "2016-11-09 21:24:40.319586"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:27:41.233903"], ["updated_at", "2016-11-09 21:27:41.233903"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 191], ["created_at", "2016-11-09 21:27:41.253422"], ["updated_at", "2016-11-09 21:27:41.253422"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 191], ["created_at", "2016-11-09 21:27:41.260871"], ["updated_at", "2016-11-09 21:27:41.260871"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 191], ["created_at", "2016-11-09 21:27:41.266229"], ["updated_at", "2016-11-09 21:27:41.266229"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:27:43.346400"], ["updated_at", "2016-11-09 21:27:43.346400"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:27:43.351768"], ["updated_at", "2016-11-09 21:27:43.351768"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:27:43.360494"], ["updated_at", "2016-11-09 21:27:43.360494"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:27:43.365371"], ["updated_at", "2016-11-09 21:27:43.365371"]]  (0.3ms) RELEASE SAVEPOINT active_record_1 Shop Load (1.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:27:51.875070"], ["updated_at", "2016-11-09 21:27:51.875070"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 192], ["created_at", "2016-11-09 21:27:51.878182"], ["updated_at", "2016-11-09 21:27:51.878182"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 119  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:27:53.946922"], ["updated_at", "2016-11-09 21:27:53.946922"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:27:53.951294"], ["updated_at", "2016-11-09 21:27:53.951294"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:27:53.955781"], ["updated_at", "2016-11-09 21:27:53.955781"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:27:53.960349"], ["updated_at", "2016-11-09 21:27:53.960349"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:27:53.964331"], ["updated_at", "2016-11-09 21:27:53.964331"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:29:26.365769"], ["updated_at", "2016-11-09 21:29:26.365769"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:29:26.372380"], ["updated_at", "2016-11-09 21:29:26.372380"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:29:26.377058"], ["updated_at", "2016-11-09 21:29:26.377058"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:29:26.381781"], ["updated_at", "2016-11-09 21:29:26.381781"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:29:26.386654"], ["updated_at", "2016-11-09 21:29:26.386654"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:30:40.206342"], ["updated_at", "2016-11-09 21:30:40.206342"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 193], ["created_at", "2016-11-09 21:30:40.226151"], ["updated_at", "2016-11-09 21:30:40.226151"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 193], ["created_at", "2016-11-09 21:30:40.233417"], ["updated_at", "2016-11-09 21:30:40.233417"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 193], ["created_at", "2016-11-09 21:30:40.239062"], ["updated_at", "2016-11-09 21:30:40.239062"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:30:42.318446"], ["updated_at", "2016-11-09 21:30:42.318446"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 194], ["created_at", "2016-11-09 21:30:42.320692"], ["updated_at", "2016-11-09 21:30:42.320692"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 120  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:30:44.384531"], ["updated_at", "2016-11-09 21:30:44.384531"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:30:44.390631"], ["updated_at", "2016-11-09 21:30:44.390631"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:30:44.395317"], ["updated_at", "2016-11-09 21:30:44.395317"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:30:44.399693"], ["updated_at", "2016-11-09 21:30:44.399693"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:30:44.404437"], ["updated_at", "2016-11-09 21:30:44.404437"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:30:46.478402"], ["updated_at", "2016-11-09 21:30:46.478402"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:30:46.483422"], ["updated_at", "2016-11-09 21:30:46.483422"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:30:46.488005"], ["updated_at", "2016-11-09 21:30:46.488005"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:30:46.493001"], ["updated_at", "2016-11-09 21:30:46.493001"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:31:21.745800"], ["updated_at", "2016-11-09 21:31:21.745800"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 195], ["created_at", "2016-11-09 21:31:21.760113"], ["updated_at", "2016-11-09 21:31:21.760113"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:31:23.810335"], ["updated_at", "2016-11-09 21:31:23.810335"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 196], ["created_at", "2016-11-09 21:31:23.816243"], ["updated_at", "2016-11-09 21:31:23.816243"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 196], ["created_at", "2016-11-09 21:31:23.822239"], ["updated_at", "2016-11-09 21:31:23.822239"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 196], ["created_at", "2016-11-09 21:31:23.827618"], ["updated_at", "2016-11-09 21:31:23.827618"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:31:25.915712"], ["updated_at", "2016-11-09 21:31:25.915712"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:31:25.921231"], ["updated_at", "2016-11-09 21:31:25.921231"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:31:25.927064"], ["updated_at", "2016-11-09 21:31:25.927064"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:31:25.931566"], ["updated_at", "2016-11-09 21:31:25.931566"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:31:25.935846"], ["updated_at", "2016-11-09 21:31:25.935846"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.5ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:31:28.015002"], ["updated_at", "2016-11-09 21:31:28.015002"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:31:28.020299"], ["updated_at", "2016-11-09 21:31:28.020299"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:31:28.025787"], ["updated_at", "2016-11-09 21:31:28.025787"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:31:28.030641"], ["updated_at", "2016-11-09 21:31:28.030641"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.8ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:37:09.084116"], ["updated_at", "2016-11-09 21:37:09.084116"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:37:09.090873"], ["updated_at", "2016-11-09 21:37:09.090873"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:37:09.095560"], ["updated_at", "2016-11-09 21:37:09.095560"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:37:09.100277"], ["updated_at", "2016-11-09 21:37:09.100277"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:37:09.105044"], ["updated_at", "2016-11-09 21:37:09.105044"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:37:11.158015"], ["updated_at", "2016-11-09 21:37:11.158015"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 197], ["created_at", "2016-11-09 21:37:11.171812"], ["updated_at", "2016-11-09 21:37:11.171812"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 122  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:37:13.231938"], ["updated_at", "2016-11-09 21:37:13.231938"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 198], ["created_at", "2016-11-09 21:37:13.236938"], ["updated_at", "2016-11-09 21:37:13.236938"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 198], ["created_at", "2016-11-09 21:37:13.242663"], ["updated_at", "2016-11-09 21:37:13.242663"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 198], ["created_at", "2016-11-09 21:37:13.247809"], ["updated_at", "2016-11-09 21:37:13.247809"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:37:15.301474"], ["updated_at", "2016-11-09 21:37:15.301474"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:37:15.306165"], ["updated_at", "2016-11-09 21:37:15.306165"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:37:15.310427"], ["updated_at", "2016-11-09 21:37:15.310427"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:37:15.315221"], ["updated_at", "2016-11-09 21:37:15.315221"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:37:55.253833"], ["updated_at", "2016-11-09 21:37:55.253833"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:37:55.260282"], ["updated_at", "2016-11-09 21:37:55.260282"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:37:55.264879"], ["updated_at", "2016-11-09 21:37:55.264879"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:37:55.270299"], ["updated_at", "2016-11-09 21:37:55.270299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:37:57.328209"], ["updated_at", "2016-11-09 21:37:57.328209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 199], ["created_at", "2016-11-09 21:37:57.341781"], ["updated_at", "2016-11-09 21:37:57.341781"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 123  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:37:59.399900"], ["updated_at", "2016-11-09 21:37:59.399900"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 200], ["created_at", "2016-11-09 21:37:59.405159"], ["updated_at", "2016-11-09 21:37:59.405159"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 200], ["created_at", "2016-11-09 21:37:59.411141"], ["updated_at", "2016-11-09 21:37:59.411141"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 200], ["created_at", "2016-11-09 21:37:59.416442"], ["updated_at", "2016-11-09 21:37:59.416442"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:38:01.499711"], ["updated_at", "2016-11-09 21:38:01.499711"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:38:01.505039"], ["updated_at", "2016-11-09 21:38:01.505039"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:38:01.509448"], ["updated_at", "2016-11-09 21:38:01.509448"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:38:01.513789"], ["updated_at", "2016-11-09 21:38:01.513789"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:38:01.518826"], ["updated_at", "2016-11-09 21:38:01.518826"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:42:20.983479"], ["updated_at", "2016-11-09 21:42:20.983479"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 201], ["created_at", "2016-11-09 21:42:21.003229"], ["updated_at", "2016-11-09 21:42:21.003229"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 --------------------------- SearchTest: test_pagination --------------------------- --------------------------------- SearchTest: test_with_and_without --------------------------------- ---------------------- SearchTest: test_order ---------------------- ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:43:22.546892"], ["updated_at", "2016-11-09 21:43:22.546892"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 203], ["created_at", "2016-11-09 21:43:22.565753"], ["updated_at", "2016-11-09 21:43:22.565753"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.5ms) SELECT "products".* FROM "products" WHERE "products"."id" = 125 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (203)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:43:24.642123"], ["updated_at", "2016-11-09 21:43:24.642123"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:43:24.647391"], ["updated_at", "2016-11-09 21:43:24.647391"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:43:24.651538"], ["updated_at", "2016-11-09 21:43:24.651538"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:43:24.655856"], ["updated_at", "2016-11-09 21:43:24.655856"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:43:26.713184"], ["updated_at", "2016-11-09 21:43:26.713184"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 204], ["created_at", "2016-11-09 21:43:26.719117"], ["updated_at", "2016-11-09 21:43:26.719117"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 204], ["created_at", "2016-11-09 21:43:26.725870"], ["updated_at", "2016-11-09 21:43:26.725870"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 204], ["created_at", "2016-11-09 21:43:26.731595"], ["updated_at", "2016-11-09 21:43:26.731595"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.1ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:43:28.822794"], ["updated_at", "2016-11-09 21:43:28.822794"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:43:28.827973"], ["updated_at", "2016-11-09 21:43:28.827973"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:43:28.833580"], ["updated_at", "2016-11-09 21:43:28.833580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:43:28.838981"], ["updated_at", "2016-11-09 21:43:28.838981"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:43:28.844040"], ["updated_at", "2016-11-09 21:43:28.844040"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.7ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:43:35.163630"], ["updated_at", "2016-11-09 21:43:35.163630"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 205], ["created_at", "2016-11-09 21:43:35.179299"], ["updated_at", "2016-11-09 21:43:35.179299"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 126 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (205)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:43:37.239619"], ["updated_at", "2016-11-09 21:43:37.239619"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:43:37.244950"], ["updated_at", "2016-11-09 21:43:37.244950"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:43:37.249975"], ["updated_at", "2016-11-09 21:43:37.249975"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:43:37.255078"], ["updated_at", "2016-11-09 21:43:37.255078"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:43:39.312214"], ["updated_at", "2016-11-09 21:43:39.312214"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 206], ["created_at", "2016-11-09 21:43:39.317740"], ["updated_at", "2016-11-09 21:43:39.317740"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 206], ["created_at", "2016-11-09 21:43:39.324502"], ["updated_at", "2016-11-09 21:43:39.324502"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 206], ["created_at", "2016-11-09 21:43:39.330135"], ["updated_at", "2016-11-09 21:43:39.330135"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.1ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:43:41.420926"], ["updated_at", "2016-11-09 21:43:41.420926"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:43:41.426452"], ["updated_at", "2016-11-09 21:43:41.426452"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:43:41.431778"], ["updated_at", "2016-11-09 21:43:41.431778"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:43:41.436297"], ["updated_at", "2016-11-09 21:43:41.436297"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:43:41.440606"], ["updated_at", "2016-11-09 21:43:41.440606"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:43:54.708103"], ["updated_at", "2016-11-09 21:43:54.708103"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:43:54.714812"], ["updated_at", "2016-11-09 21:43:54.714812"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:43:54.718971"], ["updated_at", "2016-11-09 21:43:54.718971"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:43:54.723194"], ["updated_at", "2016-11-09 21:43:54.723194"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:43:56.773565"], ["updated_at", "2016-11-09 21:43:56.773565"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 207], ["created_at", "2016-11-09 21:43:56.787334"], ["updated_at", "2016-11-09 21:43:56.787334"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 127  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 21:43:58.835373"], ["updated_at", "2016-11-09 21:43:58.835373"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 208], ["created_at", "2016-11-09 21:43:58.840961"], ["updated_at", "2016-11-09 21:43:58.840961"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 208], ["created_at", "2016-11-09 21:43:58.846981"], ["updated_at", "2016-11-09 21:43:58.846981"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 208], ["created_at", "2016-11-09 21:43:58.852310"], ["updated_at", "2016-11-09 21:43:58.852310"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 21:44:00.937593"], ["updated_at", "2016-11-09 21:44:00.937593"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 21:44:00.943104"], ["updated_at", "2016-11-09 21:44:00.943104"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 21:44:00.948035"], ["updated_at", "2016-11-09 21:44:00.948035"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 21:44:00.952988"], ["updated_at", "2016-11-09 21:44:00.952988"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 21:44:00.957932"], ["updated_at", "2016-11-09 21:44:00.957932"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index -------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ---------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 22:05:02.177117"], ["updated_at", "2016-11-09 22:05:02.177117"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 209], ["created_at", "2016-11-09 22:05:02.194032"], ["updated_at", "2016-11-09 22:05:02.194032"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 128  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 128]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 128  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search -------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:05:04.470270"], ["updated_at", "2016-11-09 22:05:04.470270"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 210], ["created_at", "2016-11-09 22:05:04.473146"], ["updated_at", "2016-11-09 22:05:04.473146"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 210], ["created_at", "2016-11-09 22:05:04.480485"], ["updated_at", "2016-11-09 22:05:04.480485"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_exist ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:05:06.663798"], ["updated_at", "2016-11-09 22:05:06.663798"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 211], ["created_at", "2016-11-09 22:05:06.671012"], ["updated_at", "2016-11-09 22:05:06.671012"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 211], ["created_at", "2016-11-09 22:05:06.680614"], ["updated_at", "2016-11-09 22:05:06.680614"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 211], ["created_at", "2016-11-09 22:05:06.687423"], ["updated_at", "2016-11-09 22:05:06.687423"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.8ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:05:08.775030"], ["updated_at", "2016-11-09 22:05:08.775030"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:05:08.781024"], ["updated_at", "2016-11-09 22:05:08.781024"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:05:08.786378"], ["updated_at", "2016-11-09 22:05:08.786378"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:05:08.792227"], ["updated_at", "2016-11-09 22:05:08.792227"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 22:05:08.797179"], ["updated_at", "2016-11-09 22:05:08.797179"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:05:10.885432"], ["updated_at", "2016-11-09 22:05:10.885432"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:05:10.890099"], ["updated_at", "2016-11-09 22:05:10.890099"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:05:10.895026"], ["updated_at", "2016-11-09 22:05:10.895026"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:05:10.900429"], ["updated_at", "2016-11-09 22:05:10.900429"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.1ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:05:12.950130"], ["updated_at", "2016-11-09 22:05:12.950130"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 212], ["created_at", "2016-11-09 22:05:12.952452"], ["updated_at", "2016-11-09 22:05:12.952452"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 131 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (212)  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 22:10:05.729236"], ["updated_at", "2016-11-09 22:10:05.729236"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 213], ["created_at", "2016-11-09 22:10:05.742827"], ["updated_at", "2016-11-09 22:10:05.742827"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (132, 131)  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 132]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (132, 131)  (0.4ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:10:07.851145"], ["updated_at", "2016-11-09 22:10:07.851145"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 214], ["created_at", "2016-11-09 22:10:07.857305"], ["updated_at", "2016-11-09 22:10:07.857305"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 214], ["created_at", "2016-11-09 22:10:07.863209"], ["updated_at", "2016-11-09 22:10:07.863209"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 214], ["created_at", "2016-11-09 22:10:07.875169"], ["updated_at", "2016-11-09 22:10:07.875169"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:10:09.953245"], ["updated_at", "2016-11-09 22:10:09.953245"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:10:09.957888"], ["updated_at", "2016-11-09 22:10:09.957888"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:10:09.962195"], ["updated_at", "2016-11-09 22:10:09.962195"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:10:09.966247"], ["updated_at", "2016-11-09 22:10:09.966247"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 22:10:09.970661"], ["updated_at", "2016-11-09 22:10:09.970661"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:10:12.045716"], ["updated_at", "2016-11-09 22:10:12.045716"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 215], ["created_at", "2016-11-09 22:10:12.048511"], ["updated_at", "2016-11-09 22:10:12.048511"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 133 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (215)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:10:14.104193"], ["updated_at", "2016-11-09 22:10:14.104193"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:10:14.109628"], ["updated_at", "2016-11-09 22:10:14.109628"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:10:14.115143"], ["updated_at", "2016-11-09 22:10:14.115143"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:10:14.120243"], ["updated_at", "2016-11-09 22:10:14.120243"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:10:16.178807"], ["updated_at", "2016-11-09 22:10:16.178807"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 216], ["created_at", "2016-11-09 22:10:16.181719"], ["updated_at", "2016-11-09 22:10:16.181719"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 216], ["created_at", "2016-11-09 22:10:16.188493"], ["updated_at", "2016-11-09 22:10:16.188493"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN ----------------------- IndicesTest: test_exist ----------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.4ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ----------------------- IndicesTest: test_exist ----------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:12:33.981042"], ["updated_at", "2016-11-09 22:12:33.981042"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 217], ["created_at", "2016-11-09 22:12:33.996647"], ["updated_at", "2016-11-09 22:12:33.996647"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 217], ["created_at", "2016-11-09 22:12:34.003206"], ["updated_at", "2016-11-09 22:12:34.003206"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.3ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:12:36.091746"], ["updated_at", "2016-11-09 22:12:36.091746"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:12:36.096931"], ["updated_at", "2016-11-09 22:12:36.096931"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:12:36.102060"], ["updated_at", "2016-11-09 22:12:36.102060"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:12:36.106835"], ["updated_at", "2016-11-09 22:12:36.106835"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 22:12:36.111500"], ["updated_at", "2016-11-09 22:12:36.111500"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:12:38.209921"], ["updated_at", "2016-11-09 22:12:38.209921"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:12:38.215086"], ["updated_at", "2016-11-09 22:12:38.215086"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:12:38.218874"], ["updated_at", "2016-11-09 22:12:38.218874"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:12:38.223355"], ["updated_at", "2016-11-09 22:12:38.223355"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:12:40.277889"], ["updated_at", "2016-11-09 22:12:40.277889"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 218], ["created_at", "2016-11-09 22:12:40.280179"], ["updated_at", "2016-11-09 22:12:40.280179"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 138 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (218)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:12:42.336779"], ["updated_at", "2016-11-09 22:12:42.336779"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 219], ["created_at", "2016-11-09 22:12:42.342580"], ["updated_at", "2016-11-09 22:12:42.342580"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 219], ["created_at", "2016-11-09 22:12:42.349464"], ["updated_at", "2016-11-09 22:12:42.349464"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 219], ["created_at", "2016-11-09 22:12:42.355167"], ["updated_at", "2016-11-09 22:12:42.355167"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.3ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 22:12:44.461134"], ["updated_at", "2016-11-09 22:12:44.461134"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 220], ["created_at", "2016-11-09 22:12:44.464613"], ["updated_at", "2016-11-09 22:12:44.464613"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 139  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 139]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 139  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:15:45.886989"], ["updated_at", "2016-11-09 22:15:45.886989"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 221], ["created_at", "2016-11-09 22:15:45.901026"], ["updated_at", "2016-11-09 22:15:45.901026"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 140 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (221)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:15:47.956717"], ["updated_at", "2016-11-09 22:15:47.956717"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:15:47.962477"], ["updated_at", "2016-11-09 22:15:47.962477"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:15:47.968154"], ["updated_at", "2016-11-09 22:15:47.968154"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:15:47.973541"], ["updated_at", "2016-11-09 22:15:47.973541"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:15:50.022371"], ["updated_at", "2016-11-09 22:15:50.022371"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:15:50.026876"], ["updated_at", "2016-11-09 22:15:50.026876"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:15:50.031218"], ["updated_at", "2016-11-09 22:15:50.031218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:15:50.035270"], ["updated_at", "2016-11-09 22:15:50.035270"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 22:15:50.039997"], ["updated_at", "2016-11-09 22:15:50.039997"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.4ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:15:52.108596"], ["updated_at", "2016-11-09 22:15:52.108596"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 222], ["created_at", "2016-11-09 22:15:52.113930"], ["updated_at", "2016-11-09 22:15:52.113930"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 222], ["created_at", "2016-11-09 22:15:52.120204"], ["updated_at", "2016-11-09 22:15:52.120204"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 222], ["created_at", "2016-11-09 22:15:52.125422"], ["updated_at", "2016-11-09 22:15:52.125422"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_exist ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:15:54.306768"], ["updated_at", "2016-11-09 22:15:54.306768"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 223], ["created_at", "2016-11-09 22:15:54.308905"], ["updated_at", "2016-11-09 22:15:54.308905"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 223], ["created_at", "2016-11-09 22:15:54.314873"], ["updated_at", "2016-11-09 22:15:54.314873"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.1ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build ---------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild -----------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 22:15:56.433937"], ["updated_at", "2016-11-09 22:15:56.433937"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 224], ["created_at", "2016-11-09 22:15:56.437458"], ["updated_at", "2016-11-09 22:15:56.437458"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 143  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 143]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 143  (0.3ms) ROLLBACK ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.2ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:20:25.801350"], ["updated_at", "2016-11-09 22:20:25.801350"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 225], ["created_at", "2016-11-09 22:20:25.816610"], ["updated_at", "2016-11-09 22:20:25.816610"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 144 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (225)  (0.3ms) ROLLBACK  (0.2ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:20:27.873915"], ["updated_at", "2016-11-09 22:20:27.873915"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 226], ["created_at", "2016-11-09 22:20:27.879879"], ["updated_at", "2016-11-09 22:20:27.879879"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 226], ["created_at", "2016-11-09 22:20:27.887359"], ["updated_at", "2016-11-09 22:20:27.887359"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 226], ["created_at", "2016-11-09 22:20:27.893130"], ["updated_at", "2016-11-09 22:20:27.893130"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:20:29.966854"], ["updated_at", "2016-11-09 22:20:29.966854"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:20:29.971996"], ["updated_at", "2016-11-09 22:20:29.971996"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:20:29.976697"], ["updated_at", "2016-11-09 22:20:29.976697"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:20:29.980917"], ["updated_at", "2016-11-09 22:20:29.980917"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-09 22:20:32.039110"], ["updated_at", "2016-11-09 22:20:32.039110"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-09 22:20:32.044171"], ["updated_at", "2016-11-09 22:20:32.044171"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-09 22:20:32.048866"], ["updated_at", "2016-11-09 22:20:32.048866"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-09 22:20:32.059489"], ["updated_at", "2016-11-09 22:20:32.059489"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-09 22:20:32.063570"], ["updated_at", "2016-11-09 22:20:32.063570"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-09 22:20:34.134808"], ["updated_at", "2016-11-09 22:20:34.134808"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 227], ["created_at", "2016-11-09 22:20:34.137266"], ["updated_at", "2016-11-09 22:20:34.137266"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 145  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 145]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 145  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- IndicesTest: test_exist ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-09 22:20:36.249872"], ["updated_at", "2016-11-09 22:20:36.249872"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 228], ["created_at", "2016-11-09 22:20:36.252038"], ["updated_at", "2016-11-09 22:20:36.252038"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 228], ["created_at", "2016-11-09 22:20:36.257932"], ["updated_at", "2016-11-09 22:20:36.257932"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.2ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.2ms) ROLLBACK  (0.2ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000 Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK ActiveRecord::SchemaMigration Load (6.4ms) SELECT "schema_migrations".* FROM "schema_migrations" ActiveRecord::SchemaMigration Load (0.3ms) SELECT "schema_migrations".* FROM "schema_migrations"  (0.3ms) BEGIN ----------------------- IndicesTest: test_exist ----------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- IndicesTest: test_suggest ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-17 23:39:34.018295"], ["updated_at", "2016-11-17 23:39:34.018295"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.4ms) SAVEPOINT active_record_1 SQL (0.4ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Les Paul"], ["shop_id", 229], ["created_at", "2016-11-17 23:39:34.039284"], ["updated_at", "2016-11-17 23:39:34.039284"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Stratocaster"], ["shop_id", 229], ["created_at", "2016-11-17 23:39:34.091636"], ["updated_at", "2016-11-17 23:39:34.091636"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- IndicesTest: test_find ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.2ms) BEGIN --------------------------- IndicesTest: test_namespace --------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------- TasksTest: test_build --------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) ROLLBACK  (0.1ms) BEGIN ----------------------- TasksTest: test_rebuild ----------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.4ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000 Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- RecordTest: test_indexing ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("name", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["name", "Anderstons"], ["created_at", "2016-11-17 23:39:36.518574"], ["updated_at", "2016-11-17 23:39:36.518574"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "category", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5) RETURNING "id" [["name", "Les Paul"], ["category", "Gibson"], ["shop_id", 230], ["created_at", "2016-11-17 23:39:36.521137"], ["updated_at", "2016-11-17 23:39:36.521137"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" = 150  (0.1ms) SAVEPOINT active_record_1 SQL (0.1ms) DELETE FROM "products" WHERE "products"."id" = $1 [["id", 150]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------- SearchTest: test_order ---------------------- Product Load (0.4ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-17 23:39:38.636146"], ["updated_at", "2016-11-17 23:39:38.636146"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 1], ["name", "1"], ["price", 1], ["position", 1], ["currency", "UYU"], ["shop_id", 231], ["created_at", "2016-11-17 23:39:38.642371"], ["updated_at", "2016-11-17 23:39:38.642371"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 2], ["name", "2"], ["price", 2], ["position", 2], ["currency", "UYU"], ["shop_id", 231], ["created_at", "2016-11-17 23:39:38.649979"], ["updated_at", "2016-11-17 23:39:38.649979"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "products" ("id", "name", "price", "position", "currency", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4, $5, $6, $7, $8) RETURNING "id" [["id", 3], ["name", "3"], ["price", 3], ["position", 3], ["currency", "UYU"], ["shop_id", 231], ["created_at", "2016-11-17 23:39:38.656275"], ["updated_at", "2016-11-17 23:39:38.656275"]]  (0.2ms) RELEASE SAVEPOINT active_record_1 Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.7ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.4ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (1, 2, 3) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1) Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" IN (3, 2, 1)  (0.2ms) ROLLBACK  (0.1ms) BEGIN --------------------------------- SearchTest: test_with_and_without --------------------------------- Product Load (0.5ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-17 23:39:40.770767"], ["updated_at", "2016-11-17 23:39:40.770767"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-17 23:39:40.776858"], ["updated_at", "2016-11-17 23:39:40.776858"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.3ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-17 23:39:40.783881"], ["updated_at", "2016-11-17 23:39:40.783881"]]  (0.2ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-17 23:39:40.789700"], ["updated_at", "2016-11-17 23:39:40.789700"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (4, 3) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (2, 1)  (0.3ms) ROLLBACK  (0.1ms) BEGIN --------------------------- SearchTest: test_pagination --------------------------- Product Load (0.6ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.3ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 1], ["created_at", "2016-11-17 23:39:42.852058"], ["updated_at", "2016-11-17 23:39:42.852058"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.3ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 2], ["created_at", "2016-11-17 23:39:42.858664"], ["updated_at", "2016-11-17 23:39:42.858664"]]  (0.4ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 3], ["created_at", "2016-11-17 23:39:42.869172"], ["updated_at", "2016-11-17 23:39:42.869172"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.2ms) SAVEPOINT active_record_1 SQL (0.6ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 4], ["created_at", "2016-11-17 23:39:42.874901"], ["updated_at", "2016-11-17 23:39:42.874901"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("id", "created_at", "updated_at") VALUES ($1, $2, $3) RETURNING "id" [["id", 5], ["created_at", "2016-11-17 23:39:42.879859"], ["updated_at", "2016-11-17 23:39:42.879859"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (5, 4) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (3, 2) Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" = 1 Shop Load (0.2ms) SELECT "shops".* FROM "shops" WHERE 1=0  (0.2ms) ROLLBACK  (0.1ms) BEGIN ------------------------- SearchTest: test_includes ------------------------- Product Load (0.3ms) SELECT "products".* FROM "products" ORDER BY "products"."id" ASC LIMIT 1000 Shop Load (0.3ms) SELECT "shops".* FROM "shops" ORDER BY "shops"."id" ASC LIMIT 1000  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "shops" ("created_at", "updated_at") VALUES ($1, $2) RETURNING "id" [["created_at", "2016-11-17 23:39:44.977218"], ["updated_at", "2016-11-17 23:39:44.977218"]]  (0.1ms) RELEASE SAVEPOINT active_record_1  (0.1ms) SAVEPOINT active_record_1 SQL (0.2ms) INSERT INTO "products" ("name", "shop_id", "created_at", "updated_at") VALUES ($1, $2, $3, $4) RETURNING "id" [["name", "Test"], ["shop_id", 232], ["created_at", "2016-11-17 23:39:44.979077"], ["updated_at", "2016-11-17 23:39:44.979077"]]  (0.1ms) RELEASE SAVEPOINT active_record_1 Product Load (0.3ms) SELECT "products".* FROM "products" WHERE "products"."id" = 151 Shop Load (0.3ms) SELECT "shops".* FROM "shops" WHERE "shops"."id" IN (232)  (0.2ms) ROLLBACK  (0.1ms) BEGIN -------------------- DslTest: test_search --------------------  (0.2ms) ROLLBACK  (0.1ms) BEGIN ---------------------------- GeneratorsTest: test_install ----------------------------  (0.1ms) ROLLBACK  (0.1ms) BEGIN -------------------------- GeneratorsTest: test_index --------------------------  (0.2ms) ROLLBACK