has_public_id 1.1.9 → 1.2.0

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: 8ed3b174e36382079a0edc21faa8f954380b9571
4
- data.tar.gz: 1e68251b834bf833d34e98345a9b99cae556105b
3
+ metadata.gz: f1bfdbb495ebd35dbba710e54a1257df584866df
4
+ data.tar.gz: d3d051f8b14977452ea29855986d5c4cfcf45e3b
5
5
  SHA512:
6
- metadata.gz: 25a52539506e0c8a47069fd637f64343960b3260a9f8877471c5790c9b3138e9042bed80bb2afbc06361ada906c06c5dab827a0e190c5a77d2acafa34618e4e6
7
- data.tar.gz: 329dd6020f87a2be2019e89b742c55ddbd6113b7f6bfd180f4065267cece183e24d2968972464bb7505c3b446581808c0657aafdb205a4248c5ce174cd29f541
6
+ metadata.gz: 3f41e94856864dc1d828892b7c17da23dbe1dc888d97acf0f36c95bd6a686033e7281f7a43cd35f3332ecdb6678916885e6d7eeb6e28a4673e2f6f95763360e1
7
+ data.tar.gz: 7b44432e54df200836978eb51aa1ab48247c94b71e46974c7727fec43b1ce3a8f6939299008595169f37137e6a48732ddbc2b4e2796d6414201cb668d3e9f0bf
@@ -38,7 +38,8 @@ module HasPublicId
38
38
  end
39
39
 
40
40
  def find_by_public_id!(public_id)
41
- where(self.public_id_attr => public_id).first!
41
+ where(self.public_id_attr => public_id).first or
42
+ raise ::ActiveRecord::RecordNotFound.new("Couldn't find #{self.name} with #{public_id}")
42
43
  end
43
44
 
44
45
  def new_public_id
@@ -1,3 +1,3 @@
1
1
  module HasPublicId
2
- VERSION = "1.1.9"
2
+ VERSION = "1.2.0"
3
3
  end
Binary file
@@ -164,3 +164,321 @@ AdminTest: test_identifier_initializes_from_parent
164
164
  AdminTest: test_inherited_class_has_public_id_attr
165
165
  --------------------------------------------------
166
166
   (0.0ms) rollback transaction
167
+ ActiveRecord::SchemaMigration Load (2.2ms) SELECT "schema_migrations".* FROM "schema_migrations"
168
+  (3.4ms) CREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "ident" varchar, "created_at" datetime, "updated_at" datetime) 
169
+  (2.9ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL)
170
+  (0.1ms) select sqlite_version(*)
171
+  (7.1ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
172
+  (0.2ms) SELECT version FROM "schema_migrations"
173
+  (3.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20140109180823')
174
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
175
+  (0.1ms) begin transaction
176
+ ---------------------------
177
+ HasPublicIdTest: test_Mixin
178
+ ---------------------------
179
+  (0.0ms) rollback transaction
180
+  (0.0ms) begin transaction
181
+ -------------------------------------------
182
+ HasPublicId::UtilTest: test_char_set.length
183
+ -------------------------------------------
184
+  (0.0ms) rollback transaction
185
+  (0.0ms) begin transaction
186
+ --------------------------------------------------
187
+ HasPublicId::UtilTest: test_generate_random_suffix
188
+ --------------------------------------------------
189
+  (0.1ms) rollback transaction
190
+  (0.1ms) begin transaction
191
+ ----------------------------------------------------------
192
+ HasPublicId::UtilTest: test_generate_random_suffix(length)
193
+ ----------------------------------------------------------
194
+  (0.1ms) rollback transaction
195
+  (0.1ms) begin transaction
196
+ ------------------------------------------------------------
197
+ HasPublicId::UtilTest: test_new_public_id(with_blank_prefix)
198
+ ------------------------------------------------------------
199
+  (0.1ms) rollback transaction
200
+  (0.1ms) begin transaction
201
+ ------------------------------------------------------------
202
+ HasPublicId::UtilTest: test_new_public_id(with_false_prefix)
203
+ ------------------------------------------------------------
204
+  (0.1ms) rollback transaction
205
+  (0.1ms) begin transaction
206
+ ---------------------------------------------------------
207
+ HasPublicId::UtilTest: test_new_public_id(with_join_with)
208
+ ---------------------------------------------------------
209
+  (0.0ms) rollback transaction
210
+  (0.1ms) begin transaction
211
+ ----------------------------------------------------------
212
+ HasPublicId::UtilTest: test_new_public_id(with_nil_prefix)
213
+ ----------------------------------------------------------
214
+  (0.1ms) rollback transaction
215
+  (0.1ms) begin transaction
216
+ ------------------------------------------------------
217
+ HasPublicId::UtilTest: test_new_public_id(with_prefix)
218
+ ------------------------------------------------------
219
+  (0.0ms) rollback transaction
220
+  (0.1ms) begin transaction
221
+ Fixture Delete (0.7ms) DELETE FROM "users"
222
+ Fixture Insert (0.3ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Sammy', NULL, '2016-02-05 21:33:27', '2016-02-05 21:33:27', 980190962)
223
+ Fixture Insert (0.2ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Joe', NULL, '2016-02-05 21:33:27', '2016-02-05 21:33:27', 298486374)
224
+ Fixture Insert (0.1ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Susan', NULL, '2016-02-05 21:33:27', '2016-02-05 21:33:27', 113629430)
225
+  (3.0ms) commit transaction
226
+  (0.1ms) begin transaction
227
+ ----------------------------------------
228
+ AdminTest: test_identifier_doesnt_change
229
+ ----------------------------------------
230
+  (0.1ms) SAVEPOINT active_record_1
231
+ SQL (0.8ms) INSERT INTO "users" ("ident", "created_at", "updated_at") VALUES (?, ?, ?) [["ident", "user-MXz6H95kNbFp"], ["created_at", "2016-02-05 21:33:27.154883"], ["updated_at", "2016-02-05 21:33:27.154883"]]
232
+  (0.1ms) RELEASE SAVEPOINT active_record_1
233
+ Admin Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
234
+  (0.1ms) SAVEPOINT active_record_1
235
+  (0.2ms) RELEASE SAVEPOINT active_record_1
236
+ Admin Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
237
+  (2.7ms) rollback transaction
238
+  (0.1ms) begin transaction
239
+ --------------------------------------------------
240
+ AdminTest: test_identifier_initializes_from_parent
241
+ --------------------------------------------------
242
+  (0.1ms) rollback transaction
243
+  (0.1ms) begin transaction
244
+ --------------------------------------------------
245
+ AdminTest: test_inherited_class_has_public_id_attr
246
+ --------------------------------------------------
247
+  (0.0ms) rollback transaction
248
+  (0.1ms) begin transaction
249
+ Fixture Delete (0.3ms) DELETE FROM "users"
250
+ Fixture Insert (0.2ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Sammy', NULL, '2016-02-05 21:33:27', '2016-02-05 21:33:27', 980190962)
251
+ Fixture Insert (0.3ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Joe', NULL, '2016-02-05 21:33:27', '2016-02-05 21:33:27', 298486374)
252
+ Fixture Insert (0.1ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Susan', NULL, '2016-02-05 21:33:27', '2016-02-05 21:33:27', 113629430)
253
+  (2.9ms) commit transaction
254
+  (0.1ms) begin transaction
255
+ --------------------------------
256
+ UserTest: test_find_by_public_id
257
+ --------------------------------
258
+  (0.1ms) SAVEPOINT active_record_1
259
+ SQL (0.4ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["name", "joey"], ["ident", "user-HqCHNgEUBpoP"], ["created_at", "2016-02-05 21:33:27.195234"], ["updated_at", "2016-02-05 21:33:27.195234"]]
260
+  (0.1ms) RELEASE SAVEPOINT active_record_1
261
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "user-HqCHNgEUBpoP"]]
262
+ User Load (0.0ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "bad_key"]]
263
+  (2.3ms) rollback transaction
264
+  (0.1ms) begin transaction
265
+ ---------------------------------
266
+ UserTest: test_find_by_public_id!
267
+ ---------------------------------
268
+  (0.1ms) SAVEPOINT active_record_1
269
+ SQL (0.9ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["name", "joey"], ["ident", "user-0CU1pcnM1wDu"], ["created_at", "2016-02-05 21:33:27.202109"], ["updated_at", "2016-02-05 21:33:27.202109"]]
270
+  (0.2ms) RELEASE SAVEPOINT active_record_1
271
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "user-0CU1pcnM1wDu"]]
272
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "bad_key"]]
273
+  (2.5ms) rollback transaction
274
+  (0.1ms) begin transaction
275
+ ---------------------------------------
276
+ UserTest: test_identifier_doesnt_change
277
+ ---------------------------------------
278
+  (0.1ms) SAVEPOINT active_record_1
279
+ SQL (0.3ms) INSERT INTO "users" ("ident", "created_at", "updated_at") VALUES (?, ?, ?) [["ident", "user-dIgWNS6L7PCc"], ["created_at", "2016-02-05 21:33:27.214495"], ["updated_at", "2016-02-05 21:33:27.214495"]]
280
+  (0.0ms) RELEASE SAVEPOINT active_record_1
281
+ User Load (0.0ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
282
+  (0.0ms) SAVEPOINT active_record_1
283
+  (0.1ms) RELEASE SAVEPOINT active_record_1
284
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
285
+  (2.5ms) rollback transaction
286
+  (0.0ms) begin transaction
287
+ -------------------------------------
288
+ UserTest: test_identifier_initializes
289
+ -------------------------------------
290
+  (0.1ms) rollback transaction
291
+  (0.0ms) begin transaction
292
+ -------------------------------------
293
+ UserTest: test_initialize_public_ids!
294
+ -------------------------------------
295
+  (0.2ms) SELECT COUNT(*) FROM "users" WHERE "users"."ident" IS NULL
296
+ User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."ident" IS NULL ORDER BY "users"."id" ASC LIMIT 1000
297
+  (0.1ms) SAVEPOINT active_record_1
298
+ SQL (0.7ms) UPDATE "users" SET "ident" = ?, "updated_at" = ? WHERE "users"."id" = ? [["ident", "user-hFFnwEbGAmOG"], ["updated_at", "2016-02-05 21:33:27.227392"], ["id", 113629430]]
299
+  (0.2ms) RELEASE SAVEPOINT active_record_1
300
+  (0.2ms) SAVEPOINT active_record_1
301
+ SQL (1.6ms) UPDATE "users" SET "ident" = ?, "updated_at" = ? WHERE "users"."id" = ? [["ident", "user-E1ZcXFxYXPKa"], ["updated_at", "2016-02-05 21:33:27.236238"], ["id", 298486374]]
302
+  (0.1ms) RELEASE SAVEPOINT active_record_1
303
+  (0.1ms) SAVEPOINT active_record_1
304
+ SQL (0.1ms) UPDATE "users" SET "ident" = ?, "updated_at" = ? WHERE "users"."id" = ? [["ident", "user-fMO5DfGm5uqa"], ["updated_at", "2016-02-05 21:33:27.240549"], ["id", 980190962]]
305
+  (0.1ms) RELEASE SAVEPOINT active_record_1
306
+  (0.1ms) SELECT COUNT(*) FROM "users" WHERE "users"."ident" IS NULL
307
+  (2.4ms) rollback transaction
308
+  (0.1ms) begin transaction
309
+ ----------------------------
310
+ UserTest: test_new_public_id
311
+ ----------------------------
312
+  (0.0ms) rollback transaction
313
+  (0.0ms) begin transaction
314
+ ------------------------------------------
315
+ UserTest: test_to_param_matches_identifier
316
+ ------------------------------------------
317
+  (0.0ms) rollback transaction
318
+  (0.0ms) begin transaction
319
+ -------------------------------
320
+ UserTest: test_use_group-by_sql
321
+ -------------------------------
322
+ User Load (0.1ms) SELECT name, count(name) as count FROM "users" GROUP BY "users"."name"
323
+ User Load (0.1ms) SELECT "users".* FROM "users"
324
+ User Load (0.1ms) SELECT "users".* FROM "users"
325
+  (0.0ms) rollback transaction
326
+ ActiveRecord::SchemaMigration Load (2.3ms) SELECT "schema_migrations".* FROM "schema_migrations"
327
+  (3.5ms) CREATE TABLE "users" ("id" INTEGER PRIMARY KEY AUTOINCREMENT NOT NULL, "name" varchar, "ident" varchar, "created_at" datetime, "updated_at" datetime) 
328
+  (2.5ms) CREATE TABLE "schema_migrations" ("version" varchar NOT NULL)
329
+  (0.1ms) select sqlite_version(*)
330
+  (3.9ms) CREATE UNIQUE INDEX "unique_schema_migrations" ON "schema_migrations" ("version")
331
+  (0.2ms) SELECT version FROM "schema_migrations"
332
+  (3.4ms) INSERT INTO "schema_migrations" (version) VALUES ('20140109180823')
333
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
334
+  (0.3ms) begin transaction
335
+ -------------------------------------------
336
+ HasPublicId::UtilTest: test_char_set.length
337
+ -------------------------------------------
338
+  (0.2ms) rollback transaction
339
+  (0.1ms) begin transaction
340
+ --------------------------------------------------
341
+ HasPublicId::UtilTest: test_generate_random_suffix
342
+ --------------------------------------------------
343
+  (0.1ms) rollback transaction
344
+  (0.0ms) begin transaction
345
+ ----------------------------------------------------------
346
+ HasPublicId::UtilTest: test_generate_random_suffix(length)
347
+ ----------------------------------------------------------
348
+  (0.0ms) rollback transaction
349
+  (0.0ms) begin transaction
350
+ ------------------------------------------------------------
351
+ HasPublicId::UtilTest: test_new_public_id(with_blank_prefix)
352
+ ------------------------------------------------------------
353
+  (0.1ms) rollback transaction
354
+  (0.1ms) begin transaction
355
+ ------------------------------------------------------------
356
+ HasPublicId::UtilTest: test_new_public_id(with_false_prefix)
357
+ ------------------------------------------------------------
358
+  (0.0ms) rollback transaction
359
+  (0.0ms) begin transaction
360
+ ---------------------------------------------------------
361
+ HasPublicId::UtilTest: test_new_public_id(with_join_with)
362
+ ---------------------------------------------------------
363
+  (0.0ms) rollback transaction
364
+  (0.0ms) begin transaction
365
+ ----------------------------------------------------------
366
+ HasPublicId::UtilTest: test_new_public_id(with_nil_prefix)
367
+ ----------------------------------------------------------
368
+  (0.0ms) rollback transaction
369
+  (0.0ms) begin transaction
370
+ ------------------------------------------------------
371
+ HasPublicId::UtilTest: test_new_public_id(with_prefix)
372
+ ------------------------------------------------------
373
+  (0.0ms) rollback transaction
374
+  (0.1ms) begin transaction
375
+ Fixture Delete (0.4ms) DELETE FROM "users"
376
+ Fixture Insert (0.3ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Sammy', NULL, '2016-02-05 21:35:05', '2016-02-05 21:35:05', 980190962)
377
+ Fixture Insert (0.1ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Joe', NULL, '2016-02-05 21:35:05', '2016-02-05 21:35:05', 298486374)
378
+ Fixture Insert (0.1ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Susan', NULL, '2016-02-05 21:35:05', '2016-02-05 21:35:05', 113629430)
379
+  (2.7ms) commit transaction
380
+  (0.1ms) begin transaction
381
+ ----------------------------------------
382
+ AdminTest: test_identifier_doesnt_change
383
+ ----------------------------------------
384
+  (0.1ms) SAVEPOINT active_record_1
385
+ SQL (0.5ms) INSERT INTO "users" ("ident", "created_at", "updated_at") VALUES (?, ?, ?) [["ident", "user-8yHqN5gUQ8Ra"], ["created_at", "2016-02-05 21:35:05.326839"], ["updated_at", "2016-02-05 21:35:05.326839"]]
386
+  (0.0ms) RELEASE SAVEPOINT active_record_1
387
+ Admin Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
388
+  (0.1ms) SAVEPOINT active_record_1
389
+  (0.1ms) RELEASE SAVEPOINT active_record_1
390
+ Admin Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
391
+  (2.6ms) rollback transaction
392
+  (0.1ms) begin transaction
393
+ --------------------------------------------------
394
+ AdminTest: test_identifier_initializes_from_parent
395
+ --------------------------------------------------
396
+  (0.1ms) rollback transaction
397
+  (0.1ms) begin transaction
398
+ --------------------------------------------------
399
+ AdminTest: test_inherited_class_has_public_id_attr
400
+ --------------------------------------------------
401
+  (0.1ms) rollback transaction
402
+  (0.1ms) begin transaction
403
+ ---------------------------
404
+ HasPublicIdTest: test_Mixin
405
+ ---------------------------
406
+  (0.1ms) rollback transaction
407
+  (0.1ms) begin transaction
408
+ Fixture Delete (0.4ms) DELETE FROM "users"
409
+ Fixture Insert (0.2ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Sammy', NULL, '2016-02-05 21:35:05', '2016-02-05 21:35:05', 980190962)
410
+ Fixture Insert (0.1ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Joe', NULL, '2016-02-05 21:35:05', '2016-02-05 21:35:05', 298486374)
411
+ Fixture Insert (0.1ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at", "id") VALUES ('Susan', NULL, '2016-02-05 21:35:05', '2016-02-05 21:35:05', 113629430)
412
+  (5.5ms) commit transaction
413
+  (0.1ms) begin transaction
414
+ --------------------------------
415
+ UserTest: test_find_by_public_id
416
+ --------------------------------
417
+  (0.1ms) SAVEPOINT active_record_1
418
+ SQL (0.4ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["name", "joey"], ["ident", "user-09fvydt2coTM"], ["created_at", "2016-02-05 21:35:05.369491"], ["updated_at", "2016-02-05 21:35:05.369491"]]
419
+  (0.1ms) RELEASE SAVEPOINT active_record_1
420
+ User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "user-09fvydt2coTM"]]
421
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "bad_key"]]
422
+  (2.4ms) rollback transaction
423
+  (0.2ms) begin transaction
424
+ ---------------------------------
425
+ UserTest: test_find_by_public_id!
426
+ ---------------------------------
427
+  (0.1ms) SAVEPOINT active_record_1
428
+ SQL (0.4ms) INSERT INTO "users" ("name", "ident", "created_at", "updated_at") VALUES (?, ?, ?, ?) [["name", "joey"], ["ident", "user-lgjyVNmYKczE"], ["created_at", "2016-02-05 21:35:05.378736"], ["updated_at", "2016-02-05 21:35:05.378736"]]
429
+  (0.1ms) RELEASE SAVEPOINT active_record_1
430
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "user-lgjyVNmYKczE"]]
431
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."ident" = ? ORDER BY "users"."id" ASC LIMIT 1 [["ident", "bad_key"]]
432
+  (2.4ms) rollback transaction
433
+  (0.1ms) begin transaction
434
+ ---------------------------------------
435
+ UserTest: test_identifier_doesnt_change
436
+ ---------------------------------------
437
+  (0.1ms) SAVEPOINT active_record_1
438
+ SQL (0.5ms) INSERT INTO "users" ("ident", "created_at", "updated_at") VALUES (?, ?, ?) [["ident", "user-o7DzcKyoy2SJ"], ["created_at", "2016-02-05 21:35:05.386432"], ["updated_at", "2016-02-05 21:35:05.386432"]]
439
+  (0.1ms) RELEASE SAVEPOINT active_record_1
440
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
441
+  (0.1ms) SAVEPOINT active_record_1
442
+  (0.1ms) RELEASE SAVEPOINT active_record_1
443
+ User Load (0.2ms) SELECT "users".* FROM "users" WHERE "users"."id" = ? LIMIT 1 [["id", 980190963]]
444
+  (2.4ms) rollback transaction
445
+  (0.1ms) begin transaction
446
+ -------------------------------------
447
+ UserTest: test_identifier_initializes
448
+ -------------------------------------
449
+  (0.1ms) rollback transaction
450
+  (0.1ms) begin transaction
451
+ -------------------------------------
452
+ UserTest: test_initialize_public_ids!
453
+ -------------------------------------
454
+  (0.2ms) SELECT COUNT(*) FROM "users" WHERE "users"."ident" IS NULL
455
+ User Load (0.1ms) SELECT "users".* FROM "users" WHERE "users"."ident" IS NULL ORDER BY "users"."id" ASC LIMIT 1000
456
+  (0.0ms) SAVEPOINT active_record_1
457
+ SQL (0.3ms) UPDATE "users" SET "ident" = ?, "updated_at" = ? WHERE "users"."id" = ? [["ident", "user-ASgink06Op7A"], ["updated_at", "2016-02-05 21:35:05.400636"], ["id", 113629430]]
458
+  (0.0ms) RELEASE SAVEPOINT active_record_1
459
+  (0.0ms) SAVEPOINT active_record_1
460
+ SQL (0.9ms) UPDATE "users" SET "ident" = ?, "updated_at" = ? WHERE "users"."id" = ? [["ident", "user-3hWkIM6uwPk7"], ["updated_at", "2016-02-05 21:35:05.402726"], ["id", 298486374]]
461
+  (0.0ms) RELEASE SAVEPOINT active_record_1
462
+  (0.1ms) SAVEPOINT active_record_1
463
+ SQL (0.1ms) UPDATE "users" SET "ident" = ?, "updated_at" = ? WHERE "users"."id" = ? [["ident", "user-tpFhvulmBOGj"], ["updated_at", "2016-02-05 21:35:05.404728"], ["id", 980190962]]
464
+  (0.1ms) RELEASE SAVEPOINT active_record_1
465
+  (0.1ms) SELECT COUNT(*) FROM "users" WHERE "users"."ident" IS NULL
466
+  (2.2ms) rollback transaction
467
+  (0.1ms) begin transaction
468
+ ----------------------------
469
+ UserTest: test_new_public_id
470
+ ----------------------------
471
+  (0.0ms) rollback transaction
472
+  (0.1ms) begin transaction
473
+ ------------------------------------------
474
+ UserTest: test_to_param_matches_identifier
475
+ ------------------------------------------
476
+  (0.0ms) rollback transaction
477
+  (0.1ms) begin transaction
478
+ -------------------------------
479
+ UserTest: test_use_group-by_sql
480
+ -------------------------------
481
+ User Load (0.2ms) SELECT name, count(name) as count FROM "users" GROUP BY "users"."name"
482
+ User Load (0.1ms) SELECT "users".* FROM "users"
483
+ User Load (0.1ms) SELECT "users".* FROM "users"
484
+  (0.1ms) rollback transaction
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: has_public_id
3
3
  version: !ruby/object:Gem::Version
4
- version: 1.1.9
4
+ version: 1.2.0
5
5
  platform: ruby
6
6
  authors:
7
7
  - Graham Melcher
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2015-11-05 00:00:00.000000000 Z
11
+ date: 2016-02-05 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: rails