rails-identity 0.0.2 → 0.0.3

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA1:
3
- metadata.gz: ce9db6a25ca17bc1709b61a51eaa0949f051b9a2
4
- data.tar.gz: 050453d2f3041f4a8522dfe9341115bb830f290d
3
+ metadata.gz: 32464eb2ea5af2d70c44b54013751299787fa8b8
4
+ data.tar.gz: d41c3c527c27cc35ffe295f5a15c5935ebef9157
5
5
  SHA512:
6
- metadata.gz: 7ca641bfe5167953bc0a13f11338670041e63818527b6699522b2418cce3970e4bdc231cbf592767f3774ddc434ae5acb641aa33469d321be1aff6b75fcb39c5
7
- data.tar.gz: 17a2658fb12fe7fde5a9e425a4f01780f6dc2384f076d095253f6dffc0535e35c15a10379b1690f295000e8d5ff659aba0795ac8d1768c2072fcd06a575f65a9
6
+ metadata.gz: 9d33d8da565f1d8eaf6b48c4d774625a43b36dc3dd61a131f8d3be94daf3df6c9d104b61c591018b2daef122d247cfaa0cdc8e5a4b9734eef09e2b96116539bb
7
+ data.tar.gz: 90ed9bb4e5f7e6ee0bd3be5360d5edff29673db407323281f8cb024a12ad241a4e95e0b01d020fe917c9446c84cf93db5ecb6896099bde67b65966d37131c016
@@ -5,8 +5,9 @@ module RailsIdentity
5
5
  # App MUST monkey patch this constant
6
6
  MAILER_EMAIL = "no-reply@rails-identity.com"
7
7
 
8
- # To be able to break cache when backwards compatibility breaks
9
- CACHE_PREFIX = "rails-identity-#{RailsIdentity::VERSION}"
8
+ # To be able to break cache when backwards compatibility breaks. Update it
9
+ # only when compatibility breaks
10
+ CACHE_PREFIX = "rails-identity-0.0.2"
10
11
 
11
12
  # Fixed set of roles.
12
13
  module Roles
@@ -1,3 +1,3 @@
1
1
  module RailsIdentity
2
- VERSION = "0.0.2"
2
+ VERSION = "0.0.3"
3
3
  end
Binary file
@@ -314510,3 +314510,2166 @@ Completed 200 OK in 5ms (Views: 0.5ms | ActiveRecord: 0.2ms)
314510
314510
  RailsIdentityTest: test_truth
314511
314511
  -----------------------------
314512
314512
   (0.0ms) rollback transaction
314513
+ ActiveRecord::SchemaMigration Load (0.1ms) SELECT "schema_migrations".* FROM "schema_migrations"
314514
+  (0.1ms) begin transaction
314515
+ Fixture Delete (0.3ms) DELETE FROM "rails_identity_sessions"
314516
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_sessions" ("uuid", "user_uuid", "token", "secret", "created_at", "updated_at") VALUES ('1', '1', 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODI1OTh9.YvNWLOUjIcboemArmVUEMwnUAA2M4V6Pvu9pu4CqZWM', 'secret', '2016-04-15 14:56:38', '2016-04-15 14:56:38')
314517
+ Fixture Insert (0.0ms) INSERT INTO "rails_identity_sessions" ("uuid", "user_uuid", "token", "secret", "created_at", "updated_at") VALUES ('2', '2', 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIyIiwidXNlcl91dWlkIjoiMiIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODI1OTh9.-z4jwnwyec8FGRStAct6zE2-Ubvd8bLUp0Fr7yQMzCk', 'secret', '2016-04-15 14:56:38', '2016-04-15 14:56:38')
314518
+ Fixture Insert (0.0ms) INSERT INTO "rails_identity_sessions" ("uuid", "user_uuid", "token", "secret", "created_at", "updated_at") VALUES ('session_admin_one', 'admin_one', 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzgyNTk4fQ.ZpO7vPlzclkLCx7XsqTn14RLuZOY_YBakjZkuzOWl38', 'secret', '2016-04-15 14:56:38', '2016-04-15 14:56:38')
314519
+ Fixture Delete (0.1ms) DELETE FROM "rails_identity_users"
314520
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_users" ("uuid", "username", "password_digest", "role", "verified", "created_at", "updated_at") VALUES ('1', 'one@example.com', '$2a$10$UT9kLJgnpKDqx01fT.hHVOw3pht54VOaTr3aAAAjmHXX9Z6aIC9H6', 10, 't', '2016-04-15 14:56:38', '2016-04-15 14:56:38')
314521
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_users" ("uuid", "username", "password_digest", "role", "verified", "created_at", "updated_at") VALUES ('2', 'two@example.com', '$2a$10$uPZ8L6iZ2nZCC0fdcFCH/ePnWSKK7Ld7HADMlcjbCJDVVqJSYZdqG', 10, 't', '2016-04-15 14:56:38', '2016-04-15 14:56:38')
314522
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_users" ("uuid", "username", "password_digest", "role", "verified", "created_at", "updated_at") VALUES ('admin_one', 'admin_one@example.com', '$2a$10$.cn5akevMitc3cOdnj4BvO1rxMhwsbFYjV5fK2A0G6eG/F3YJ1g9y', 100, 't', '2016-04-15 14:56:38', '2016-04-15 14:56:38')
314523
+  (1.5ms) commit transaction
314524
+  (0.1ms) begin transaction
314525
+ ----------------------------------------------------------
314526
+ RailsIdentity::UserTest: test_user_can_issue_a_reset_token
314527
+ ----------------------------------------------------------
314528
+  (0.1ms) SAVEPOINT active_record_1
314529
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314530
+ SQL (0.3ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$Hvnncv9BoEUBote/dd6EBubjQwxGg9eDkq0Gs/MOXJZc1b3WlKtby"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjQxZDNjYjYwLTAzMWEtMTFlNi04MDg2LTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczMjE5OCwiZXhwIjoxNDYwNzM1Nzk4fQ.ckUIkfhwZ5zDDHPadu3QFwWcLwIOfyiF6wqmtngaR0Y"], ["role", 10], ["created_at", "2016-04-15 14:56:39.030460"], ["updated_at", "2016-04-15 14:56:39.030460"], ["uuid", "41db5bf0-031a-11e6-8086-6c4008a6fa2a"]]
314531
+  (0.0ms) RELEASE SAVEPOINT active_record_1
314532
+  (0.0ms) SAVEPOINT active_record_1
314533
+ SQL (0.3ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "41db5bf0-031a-11e6-8086-6c4008a6fa2a"], ["uuid", "41db9e4e-031a-11e6-8086-6c4008a6fa2a"], ["secret", "444bbdd0-bc29-4cab-bdce-3dc2ad588248"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiI0MWRiNWJmMC0wMzFhLTExZTYtODA4Ni02YzQwMDhhNmZhMmEiLCJzZXNzaW9uX3V1aWQiOiI0MWRiOWU0ZS0wMzFhLTExZTYtODA4Ni02YzQwMDhhNmZhMmEiLCJyb2xlIjoxMCwiaWF0IjoxNDYwNzMyMTk5LCJleHAiOjE0NjA3MzU3OTl9.NiU1nnSvLtq1aIWJ55zDoagHRdmvPbZgTXhUDEGqNJU"], ["created_at", "2016-04-15 14:56:39.033157"], ["updated_at", "2016-04-15 14:56:39.033157"]]
314534
+  (0.0ms) RELEASE SAVEPOINT active_record_1
314535
+  (0.6ms) rollback transaction
314536
+  (0.0ms) begin transaction
314537
+ ------------------------------------------------------------------
314538
+ RailsIdentity::UserTest: test_user_is_not_valid_without_a_username
314539
+ ------------------------------------------------------------------
314540
+  (0.0ms) SAVEPOINT active_record_1
314541
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" IS NULL AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314542
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
314543
+  (0.0ms) rollback transaction
314544
+  (0.1ms) begin transaction
314545
+ ----------------------------------------------------------------------
314546
+ RailsIdentity::UserTest: test_user_is_valid_with_username_and_password
314547
+ ----------------------------------------------------------------------
314548
+  (0.0ms) SAVEPOINT active_record_1
314549
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314550
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$s/L0P0dUWAkhGdYqWjUVKeyo5A2f79gJ/tN3yLdfsU9ic./HbKBwW"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjQxZGQ3OGMyLTAzMWEtMTFlNi04MDg2LTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczMjE5OSwiZXhwIjoxNDYwNzM1Nzk5fQ.D8W9GTOnaUOyu1IwO89HjLpMk0DUINthdhO2YoYqLbE"], ["role", 10], ["created_at", "2016-04-15 14:56:39.045898"], ["updated_at", "2016-04-15 14:56:39.045898"], ["uuid", "41ddb3b4-031a-11e6-8086-6c4008a6fa2a"]]
314551
+  (0.1ms) RELEASE SAVEPOINT active_record_1
314552
+  (0.6ms) rollback transaction
314553
+  (0.1ms) begin transaction
314554
+ ---------------------------------------------------------------------------
314555
+ RailsIdentity::UserTest: test_user_is_not_valid_if_username_is_malformatted
314556
+ ---------------------------------------------------------------------------
314557
+  (0.0ms) SAVEPOINT active_record_1
314558
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314559
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
314560
+  (0.1ms) rollback transaction
314561
+  (0.0ms) begin transaction
314562
+ -----------------------------------------------------------------
314563
+ RailsIdentity::UserTest: test_user_can_issue_a_verification_token
314564
+ -----------------------------------------------------------------
314565
+  (0.0ms) SAVEPOINT active_record_1
314566
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314567
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$Nq1a.PB.xyU3CnDknOUHWeQ03Uk7bGJ6CaGXYGWX3AXvmQFNWZhtm"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjQxZGYyZjhjLTAzMWEtMTFlNi04MDg2LTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczMjE5OSwiZXhwIjoxNDYwNzM1Nzk5fQ.sgQfgg0Xos1UVKuU94CUBEZVHH75WwDWtC3qovP5X14"], ["role", 10], ["created_at", "2016-04-15 14:56:39.057034"], ["updated_at", "2016-04-15 14:56:39.057034"], ["uuid", "41df672c-031a-11e6-8086-6c4008a6fa2a"]]
314568
+  (0.0ms) RELEASE SAVEPOINT active_record_1
314569
+  (0.0ms) SAVEPOINT active_record_1
314570
+ SQL (0.3ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "41df672c-031a-11e6-8086-6c4008a6fa2a"], ["uuid", "41df9e68-031a-11e6-8086-6c4008a6fa2a"], ["secret", "6ec41ff3-db67-42b3-8b81-68bcf2209504"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiI0MWRmNjcyYy0wMzFhLTExZTYtODA4Ni02YzQwMDhhNmZhMmEiLCJzZXNzaW9uX3V1aWQiOiI0MWRmOWU2OC0wMzFhLTExZTYtODA4Ni02YzQwMDhhNmZhMmEiLCJyb2xlIjoxMCwiaWF0IjoxNDYwNzMyMTk5LCJleHAiOjE0NjA3MzU3OTl9.bQBNFEwRm_Slu0Ig9qeXqevOD1ZIdMKmTxS1Rzk0O6w"], ["created_at", "2016-04-15 14:56:39.059273"], ["updated_at", "2016-04-15 14:56:39.059273"]]
314571
+  (0.0ms) RELEASE SAVEPOINT active_record_1
314572
+  (0.6ms) rollback transaction
314573
+  (0.1ms) begin transaction
314574
+ ------------------------------------------------------------------
314575
+ RailsIdentity::UserTest: test_user_is_not_valid_without_a_password
314576
+ ------------------------------------------------------------------
314577
+  (0.0ms) SAVEPOINT active_record_1
314578
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314579
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
314580
+  (0.0ms) rollback transaction
314581
+  (0.1ms) begin transaction
314582
+ ---------------------------------------------------------------
314583
+ RailsIdentity::UserTest: test_user_has_a_role_of_100_by_default
314584
+ ---------------------------------------------------------------
314585
+  (0.0ms) SAVEPOINT active_record_1
314586
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'new@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314587
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "new@example.com"], ["password_digest", "$2a$04$vb9vRBRL8O2A2cE903SfFu7RCyH8gxkGscR0GZShuVebRKbw5olmi"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjQxZTBhYzQwLTAzMWEtMTFlNi04MDg2LTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczMjE5OSwiZXhwIjoxNDYwNzM1Nzk5fQ.LL9EVtUPwvmqIBoShzSIV2t6bOboLpkBUPEXzYvPpC0"], ["role", 10], ["created_at", "2016-04-15 14:56:39.066452"], ["updated_at", "2016-04-15 14:56:39.066452"], ["uuid", "41e0d5b2-031a-11e6-8086-6c4008a6fa2a"]]
314588
+  (0.0ms) RELEASE SAVEPOINT active_record_1
314589
+  (0.4ms) rollback transaction
314590
+  (0.0ms) begin transaction
314591
+ --------------------------------------------------------------------------
314592
+ RailsIdentity::UserTest: test_user_is_not_valid_if_username_already_exists
314593
+ --------------------------------------------------------------------------
314594
+  (0.1ms) SAVEPOINT active_record_1
314595
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
314596
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
314597
+  (0.0ms) rollback transaction
314598
+  (0.0ms) begin transaction
314599
+ ------------------------------------------------------------
314600
+ RailsIdentity::UsersControllerTest: test_show_a_current_user
314601
+ ------------------------------------------------------------
314602
+  (0.1ms) rollback transaction
314603
+  (0.0ms) begin transaction
314604
+ ------------------------------------------------------------
314605
+ RailsIdentity::UsersControllerTest: test_update_current_user
314606
+ ------------------------------------------------------------
314607
+  (0.0ms) rollback transaction
314608
+  (0.1ms) begin transaction
314609
+ ----------------------------------------------------
314610
+ RailsIdentity::UsersControllerTest: test_show_a_user
314611
+ ----------------------------------------------------
314612
+  (0.0ms) rollback transaction
314613
+  (0.1ms) begin transaction
314614
+ ---------------------------------------------------------------------
314615
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_ill-formed
314616
+ ---------------------------------------------------------------------
314617
+  (0.0ms) rollback transaction
314618
+  (0.1ms) begin transaction
314619
+ -------------------------------------------------------------------------
314620
+ RailsIdentity::UsersControllerTest: test_update_(issue)_a_new_reset_token
314621
+ -------------------------------------------------------------------------
314622
+  (0.0ms) rollback transaction
314623
+  (0.0ms) begin transaction
314624
+ -----------------------------------------------------------------------------------------------------------
314625
+ RailsIdentity::UsersControllerTest: test_cannot_update_(reissue)_a_verification_token_with_invalid_username
314626
+ -----------------------------------------------------------------------------------------------------------
314627
+  (0.0ms) rollback transaction
314628
+  (0.0ms) begin transaction
314629
+ ------------------------------------------------------------------------------------
314630
+ RailsIdentity::UsersControllerTest: test_cannot_update_password_with_non-reset_token
314631
+ ------------------------------------------------------------------------------------
314632
+  (0.0ms) rollback transaction
314633
+  (0.1ms) begin transaction
314634
+ ------------------------------------------------------
314635
+ RailsIdentity::UsersControllerTest: test_update_a_user
314636
+ ------------------------------------------------------
314637
+  (0.0ms) rollback transaction
314638
+  (0.1ms) begin transaction
314639
+ ---------------------------------------------------------------------------------------------
314640
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_well-formed_but_non-existing_token
314641
+ ---------------------------------------------------------------------------------------------
314642
+  (0.0ms) rollback transaction
314643
+  (0.1ms) begin transaction
314644
+ ---------------------------------------------------------------
314645
+ RailsIdentity::UsersControllerTest: test_public_can_see_options
314646
+ ---------------------------------------------------------------
314647
+  (0.0ms) rollback transaction
314648
+  (0.1ms) begin transaction
314649
+ --------------------------------------------------------------------------------
314650
+ RailsIdentity::UsersControllerTest: test_cannot_create_a_user_without_a_password
314651
+ --------------------------------------------------------------------------------
314652
+  (0.0ms) rollback transaction
314653
+  (0.1ms) begin transaction
314654
+ -------------------------------------------------------------------------------------------------
314655
+ RailsIdentity::UsersControllerTest: test_cannot_update_(issue)_a_new_reset_token_without_username
314656
+ -------------------------------------------------------------------------------------------------
314657
+  (0.0ms) rollback transaction
314658
+  (0.1ms) begin transaction
314659
+ ------------------------------------------------------------------
314660
+ RailsIdentity::UsersControllerTest: test_public_cannot_show_a_user
314661
+ ------------------------------------------------------------------
314662
+  (0.0ms) rollback transaction
314663
+  (0.0ms) begin transaction
314664
+ ----------------------------------------------------------------------------------------
314665
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_well-formed_but_bogus_payload
314666
+ ----------------------------------------------------------------------------------------
314667
+  (0.0ms) rollback transaction
314668
+  (0.1ms) begin transaction
314669
+ ------------------------------------------------------------------------------------
314670
+ RailsIdentity::UsersControllerTest: test_cannot_update_password_with_a_invalid_token
314671
+ ------------------------------------------------------------------------------------
314672
+  (0.0ms) rollback transaction
314673
+  (0.0ms) begin transaction
314674
+ -------------------------------------------------------------------
314675
+ RailsIdentity::UsersControllerTest: test_cannot_update_another_user
314676
+ -------------------------------------------------------------------
314677
+  (0.0ms) rollback transaction
314678
+  (0.1ms) begin transaction
314679
+ --------------------------------------------------------------------
314680
+ RailsIdentity::UsersControllerTest: test_cannot_update_invalid_email
314681
+ --------------------------------------------------------------------
314682
+  (0.0ms) rollback transaction
314683
+  (0.1ms) begin transaction
314684
+ ------------------------------------------------------------------------------
314685
+ RailsIdentity::UsersControllerTest: test_update_(reissue)_a_verification_token
314686
+ ------------------------------------------------------------------------------
314687
+  (0.0ms) rollback transaction
314688
+  (0.1ms) begin transaction
314689
+ ------------------------------------------------------
314690
+ RailsIdentity::UsersControllerTest: test_delete_a_user
314691
+ ------------------------------------------------------
314692
+  (0.0ms) rollback transaction
314693
+  (0.1ms) begin transaction
314694
+ -----------------------------------------------------------------
314695
+ RailsIdentity::UsersControllerTest: test_admin_can_list_all_users
314696
+ -----------------------------------------------------------------
314697
+  (0.0ms) rollback transaction
314698
+  (0.1ms) begin transaction
314699
+ -----------------------------------------------------------------------
314700
+ RailsIdentity::UsersControllerTest: test_cannot_show_a_nonexisting_user
314701
+ -----------------------------------------------------------------------
314702
+  (0.0ms) rollback transaction
314703
+  (0.0ms) begin transaction
314704
+ --------------------------------------------------------------------------
314705
+ RailsIdentity::UsersControllerTest: test_update_password_using_reset_token
314706
+ --------------------------------------------------------------------------
314707
+  (0.0ms) rollback transaction
314708
+  (0.0ms) begin transaction
314709
+ ------------------------------------------------------------------
314710
+ RailsIdentity::UsersControllerTest: test_admin_can_show_other_user
314711
+ ------------------------------------------------------------------
314712
+  (0.0ms) rollback transaction
314713
+  (0.0ms) begin transaction
314714
+ ------------------------------------------------------------------------------------------------------
314715
+ RailsIdentity::UsersControllerTest: test_cannot_update_(issue)_a_new_reset_token_with_invalid_username
314716
+ ------------------------------------------------------------------------------------------------------
314717
+  (0.0ms) rollback transaction
314718
+  (0.1ms) begin transaction
314719
+ ---------------------------------------------------------------------------------------------
314720
+ RailsIdentity::UsersControllerTest: test_update_a_user_with_a_new_password_using_old_password
314721
+ ---------------------------------------------------------------------------------------------
314722
+  (0.0ms) rollback transaction
314723
+  (0.1ms) begin transaction
314724
+ ---------------------------------------------------------------
314725
+ RailsIdentity::UsersControllerTest: test_cannot_show_other_user
314726
+ ---------------------------------------------------------------
314727
+  (0.0ms) rollback transaction
314728
+  (0.1ms) begin transaction
314729
+ ---------------------------------------------------------------------------
314730
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_no_token_payload
314731
+ ---------------------------------------------------------------------------
314732
+  (0.0ms) rollback transaction
314733
+  (0.0ms) begin transaction
314734
+ -------------------------------------------------------------------------
314735
+ RailsIdentity::UsersControllerTest: test_user_cannot_create_an_admin_user
314736
+ -------------------------------------------------------------------------
314737
+  (0.0ms) rollback transaction
314738
+  (0.0ms) begin transaction
314739
+ --------------------------------------------------------------------
314740
+ RailsIdentity::UsersControllerTest: test_non-admin_cannot_list_users
314741
+ --------------------------------------------------------------------
314742
+  (0.0ms) rollback transaction
314743
+  (0.0ms) begin transaction
314744
+ --------------------------------------------------------------------
314745
+ RailsIdentity::UsersControllerTest: test_admin_can_delete_other_user
314746
+ --------------------------------------------------------------------
314747
+  (0.0ms) rollback transaction
314748
+  (0.0ms) begin transaction
314749
+ ------------------------------------------------------
314750
+ RailsIdentity::UsersControllerTest: test_create_a_user
314751
+ ------------------------------------------------------
314752
+  (0.0ms) rollback transaction
314753
+  (0.0ms) begin transaction
314754
+ -------------------------------------------------------------------
314755
+ RailsIdentity::UsersControllerTest: test_cannot_delete_another_user
314756
+ -------------------------------------------------------------------
314757
+  (0.0ms) rollback transaction
314758
+  (0.1ms) begin transaction
314759
+ ------------------------------------------------------------------------------------------------------------
314760
+ RailsIdentity::UsersControllerTest: test_cannot_update_(reissue)_a_verification_reset_token_without_username
314761
+ ------------------------------------------------------------------------------------------------------------
314762
+  (0.0ms) rollback transaction
314763
+  (0.0ms) begin transaction
314764
+ ------------------------------------------------------------------------------
314765
+ RailsIdentity::UsersControllerTest: test_cannot_create_a_user_without_username
314766
+ ------------------------------------------------------------------------------
314767
+  (0.0ms) rollback transaction
314768
+  (0.1ms) begin transaction
314769
+ ------------------------------------------------------------
314770
+ RailsIdentity::UsersControllerTest: test_delete_current_user
314771
+ ------------------------------------------------------------
314772
+  (0.0ms) rollback transaction
314773
+  (0.0ms) begin transaction
314774
+ -----------------------------------------------------------------------
314775
+ RailsIdentity::UsersControllerTest: test_admin_can_create_an_admin_user
314776
+ -----------------------------------------------------------------------
314777
+  (0.0ms) rollback transaction
314778
+  (0.0ms) begin transaction
314779
+ -----------------------------
314780
+ RailsIdentityTest: test_truth
314781
+ -----------------------------
314782
+  (0.0ms) rollback transaction
314783
+  (0.0ms) begin transaction
314784
+ --------------------------------------------------------------------------
314785
+ RailsIdentity::SessionTest: test_session_has_token_and_secret_when_created
314786
+ --------------------------------------------------------------------------
314787
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
314788
+  (0.1ms) rollback transaction
314789
+  (0.1ms) begin transaction
314790
+ -----------------------------------------------
314791
+ RailsIdentity::SessionTest: test_save_a_session
314792
+ -----------------------------------------------
314793
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
314794
+  (0.0ms) SAVEPOINT active_record_1
314795
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "41efdf12-031a-11e6-8086-6c4008a6fa2a"], ["secret", "b0066ef2-03be-4f34-8c78-6f6dbdcf234a"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiNDFlZmRmMTItMDMxYS0xMWU2LTgwODYtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczMjE5OSwiZXhwIjoxNDYxOTQxNzk5fQ.qMQbIQlknf373ZkWNjXdSk7_a0ohNa1MXYBZ-VyrEz4"], ["created_at", "2016-04-15 14:56:39.165788"], ["updated_at", "2016-04-15 14:56:39.165788"]]
314796
+  (0.0ms) RELEASE SAVEPOINT active_record_1
314797
+  (0.4ms) rollback transaction
314798
+  (0.1ms) begin transaction
314799
+ ---------------------------------------------------------------------
314800
+ RailsIdentity::SessionTest: test_cannot_save_a_session_without_a_user
314801
+ ---------------------------------------------------------------------
314802
+  (0.0ms) rollback transaction
314803
+  (0.0ms) begin transaction
314804
+ ------------------------------------------------------------
314805
+ RailsIdentity::SessionsControllerTest: test_create_a_session
314806
+ ------------------------------------------------------------
314807
+  (0.1ms) rollback transaction
314808
+  (0.0ms) begin transaction
314809
+ --------------------------------------------------------------------------------
314810
+ RailsIdentity::SessionsControllerTest: test_cannot_delete_a_non-existent_session
314811
+ --------------------------------------------------------------------------------
314812
+  (0.0ms) rollback transaction
314813
+  (0.0ms) begin transaction
314814
+ ----------------------------------------------------------------------------------------------
314815
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_with_non-existent_username
314816
+ ----------------------------------------------------------------------------------------------
314817
+  (0.0ms) rollback transaction
314818
+  (0.0ms) begin transaction
314819
+ ---------------------------------------------------------------------------------------------------
314820
+ RailsIdentity::SessionsControllerTest: test_user_can_list_all_his_sessions_using_user_id_in_routing
314821
+ ---------------------------------------------------------------------------------------------------
314822
+  (0.0ms) rollback transaction
314823
+  (0.0ms) begin transaction
314824
+ -----------------------------------------------------------------------
314825
+ RailsIdentity::SessionsControllerTest: test_public_cannot_list_sessions
314826
+ -----------------------------------------------------------------------
314827
+  (0.0ms) rollback transaction
314828
+  (0.0ms) begin transaction
314829
+ --------------------------------------------------------------------------
314830
+ RailsIdentity::SessionsControllerTest: test_user_can_list_all_his_sessions
314831
+ --------------------------------------------------------------------------
314832
+  (0.0ms) rollback transaction
314833
+  (0.1ms) begin transaction
314834
+ -------------------------------------------------------------------------
314835
+ RailsIdentity::SessionsControllerTest: test_cannot_delete_other's_session
314836
+ -------------------------------------------------------------------------
314837
+  (0.0ms) rollback transaction
314838
+  (0.1ms) begin transaction
314839
+ -------------------------------------------------------------------------
314840
+ RailsIdentity::SessionsControllerTest: test_public_cannot_create_sessions
314841
+ -------------------------------------------------------------------------
314842
+  (0.0ms) rollback transaction
314843
+  (0.1ms) begin transaction
314844
+ ----------------------------------------------------------------------
314845
+ RailsIdentity::SessionsControllerTest: test_public_cannot_show_session
314846
+ ----------------------------------------------------------------------
314847
+  (0.0ms) rollback transaction
314848
+  (0.0ms) begin transaction
314849
+ -----------------------------------------------------------------------
314850
+ RailsIdentity::SessionsControllerTest: test_cannot_show_other's_session
314851
+ -----------------------------------------------------------------------
314852
+  (0.0ms) rollback transaction
314853
+  (0.0ms) begin transaction
314854
+ ------------------------------------------------------------------
314855
+ RailsIdentity::SessionsControllerTest: test_public_can_see_options
314856
+ ------------------------------------------------------------------
314857
+  (0.0ms) rollback transaction
314858
+  (0.0ms) begin transaction
314859
+ -----------------------------------------------------------------------------
314860
+ RailsIdentity::SessionsControllerTest: test_cannot_show_a_nonexisting_session
314861
+ -----------------------------------------------------------------------------
314862
+  (0.0ms) rollback transaction
314863
+  (0.0ms) begin transaction
314864
+ ----------------------------------------------------------------------------
314865
+ RailsIdentity::SessionsControllerTest: test_admin_can_delete_other's_session
314866
+ ----------------------------------------------------------------------------
314867
+  (0.0ms) rollback transaction
314868
+  (0.0ms) begin transaction
314869
+ ------------------------------------------------------------------------------------
314870
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_without_username
314871
+ ------------------------------------------------------------------------------------
314872
+  (0.0ms) rollback transaction
314873
+  (0.0ms) begin transaction
314874
+ ------------------------------------------------------------------
314875
+ RailsIdentity::SessionsControllerTest: test_show_a_current_session
314876
+ ------------------------------------------------------------------
314877
+  (0.0ms) rollback transaction
314878
+  (0.0ms) begin transaction
314879
+ --------------------------------------------------------------------
314880
+ RailsIdentity::SessionsControllerTest: test_delete_a_current_session
314881
+ --------------------------------------------------------------------
314882
+  (0.0ms) rollback transaction
314883
+  (0.0ms) begin transaction
314884
+ --------------------------------------------------------------------------
314885
+ RailsIdentity::SessionsControllerTest: test_admin_can_show_other's_session
314886
+ --------------------------------------------------------------------------
314887
+  (0.0ms) rollback transaction
314888
+  (0.0ms) begin transaction
314889
+ -----------------------------------------------------------------------------------
314890
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_if_not_verified
314891
+ -----------------------------------------------------------------------------------
314892
+  (0.0ms) rollback transaction
314893
+  (0.0ms) begin transaction
314894
+ -----------------------------------------------------------------------------------------
314895
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_with_a_wrong_password
314896
+ -----------------------------------------------------------------------------------------
314897
+  (0.0ms) rollback transaction
314898
+  (0.0ms) begin transaction
314899
+ ----------------------------------------------------------------------------
314900
+ RailsIdentity::SessionsControllerTest: test_user_cannot_list_expired_session
314901
+ ----------------------------------------------------------------------------
314902
+  (0.0ms) rollback transaction
314903
+  (0.0ms) begin transaction
314904
+ --------------------------------------------------------------------------------------
314905
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_without_a_password
314906
+ --------------------------------------------------------------------------------------
314907
+  (0.0ms) rollback transaction
314908
+  (0.0ms) begin transaction
314909
+ ------------------------------------------------------------
314910
+ RailsIdentity::SessionsControllerTest: test_delete_a_session
314911
+ ------------------------------------------------------------
314912
+  (0.0ms) rollback transaction
314913
+  (0.0ms) begin transaction
314914
+ -----------------------------------------------------------------------------
314915
+ RailsIdentity::SessionsControllerTest: test_user_cannot_list_other's_sessions
314916
+ -----------------------------------------------------------------------------
314917
+  (0.0ms) rollback transaction
314918
+  (0.0ms) begin transaction
314919
+ -----------------------------------------------------------------------
314920
+ RailsIdentity::SessionsControllerTest: test_cannot_show_expired_session
314921
+ -----------------------------------------------------------------------
314922
+  (0.0ms) rollback transaction
314923
+  (0.0ms) begin transaction
314924
+ ----------------------------------------------------------
314925
+ RailsIdentity::SessionsControllerTest: test_show_a_session
314926
+ ----------------------------------------------------------
314927
+  (0.0ms) rollback transaction
314928
+ ActiveRecord::SchemaMigration Load (0.5ms) SELECT "schema_migrations".* FROM "schema_migrations"
314929
+  (0.1ms) begin transaction
314930
+ Fixture Delete (0.7ms) DELETE FROM "rails_identity_sessions"
314931
+ Fixture Insert (0.4ms) INSERT INTO "rails_identity_sessions" ("uuid", "user_uuid", "token", "secret", "created_at", "updated_at") VALUES ('1', '1', 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM', 'secret', '2016-04-15 16:31:45', '2016-04-15 16:31:45')
314932
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_sessions" ("uuid", "user_uuid", "token", "secret", "created_at", "updated_at") VALUES ('2', '2', 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIyIiwidXNlcl91dWlkIjoiMiIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.NSozunjxErOKiBzW9RZ63AiQJHNA-MObBMvrkW9fB-4', 'secret', '2016-04-15 16:31:45', '2016-04-15 16:31:45')
314933
+ Fixture Insert (0.0ms) INSERT INTO "rails_identity_sessions" ("uuid", "user_uuid", "token", "secret", "created_at", "updated_at") VALUES ('session_admin_one', 'admin_one', 'eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzg4MzA1fQ.AHk7rkxYSQg_zGjx1B2puIZtrxRkHmgFTaF68DsUfpI', 'secret', '2016-04-15 16:31:45', '2016-04-15 16:31:45')
314934
+ Fixture Delete (0.6ms) DELETE FROM "rails_identity_users"
314935
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_users" ("uuid", "username", "password_digest", "role", "verified", "created_at", "updated_at") VALUES ('1', 'one@example.com', '$2a$10$l.F8Kxd9XHc299kd39.FV.UL1UeQpUp.mxUtXd9xCCROe.gaCA60.', 10, 't', '2016-04-15 16:31:45', '2016-04-15 16:31:45')
314936
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_users" ("uuid", "username", "password_digest", "role", "verified", "created_at", "updated_at") VALUES ('2', 'two@example.com', '$2a$10$KwpwALSMXhJZXgaoBvdT1.Kzz1nX9fHNOKDnZwIIUDR/vXh5YbBJy', 10, 't', '2016-04-15 16:31:45', '2016-04-15 16:31:45')
314937
+ Fixture Insert (0.1ms) INSERT INTO "rails_identity_users" ("uuid", "username", "password_digest", "role", "verified", "created_at", "updated_at") VALUES ('admin_one', 'admin_one@example.com', '$2a$10$DCBrm15WHv3Z8ppBoj8bpOmI0BLq7vqxXvxAceqgTMOocSNIF/HLG', 100, 't', '2016-04-15 16:31:45', '2016-04-15 16:31:45')
314938
+  (0.8ms) commit transaction
314939
+  (0.0ms) begin transaction
314940
+ -----------------------------
314941
+ RailsIdentityTest: test_truth
314942
+ -----------------------------
314943
+  (0.0ms) rollback transaction
314944
+  (0.0ms) begin transaction
314945
+ -----------------------------------------------------------------
314946
+ RailsIdentity::UsersControllerTest: test_admin_can_list_all_users
314947
+ -----------------------------------------------------------------
314948
+ RailsIdentity::Session Load (0.3ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
314949
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
314950
+ Processing by RailsIdentity::UsersController#index as HTML
314951
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzg4MzA1fQ.AHk7rkxYSQg_zGjx1B2puIZtrxRkHmgFTaF68DsUfpI"}
314952
+ Requires an admin token
314953
+ Token well formatted for user admin_one,
314954
+ session session_admin_one
314955
+ Cache miss. Try database.
314956
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
314957
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
314958
+ Token well formatted and verified. Set cache.
314959
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
314960
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL
314961
+ Completed 200 OK in 20ms (Views: 1.3ms | ActiveRecord: 0.4ms)
314962
+  (0.0ms) SELECT COUNT(*) FROM "rails_identity_sessions"
314963
+  (0.0ms) rollback transaction
314964
+  (0.1ms) begin transaction
314965
+ --------------------------------------------------------------------
314966
+ RailsIdentity::UsersControllerTest: test_non-admin_cannot_list_users
314967
+ --------------------------------------------------------------------
314968
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
314969
+ Processing by RailsIdentity::UsersController#index as HTML
314970
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM"}
314971
+ Requires an admin token
314972
+ Token well formatted for user 1,
314973
+ session 1
314974
+ Cache miss. Try database.
314975
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
314976
+ Well-formed but invalid user token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM
314977
+ Completed 401 Unauthorized in 2ms (Views: 0.2ms | ActiveRecord: 0.1ms)
314978
+  (0.1ms) rollback transaction
314979
+  (0.0ms) begin transaction
314980
+ -----------------------------------------------------------------------------------------------------------
314981
+ RailsIdentity::UsersControllerTest: test_cannot_update_(reissue)_a_verification_token_with_invalid_username
314982
+ -----------------------------------------------------------------------------------------------------------
314983
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
314984
+ Processing by RailsIdentity::UsersController#update as HTML
314985
+ Parameters: {"issue_verification_token"=>true, "username"=>"doesnotexist@example.com", "id"=>"current"}
314986
+ Accepts a token
314987
+ Token decode error: Nil JSON web token
314988
+ Suppressing error: Invalid token:
314989
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "doesnotexist@example.com"]]
314990
+ RailsIdentity::Errors::ObjectNotFoundError
314991
+ Completed 404 Not Found in 2ms (Views: 0.2ms | ActiveRecord: 0.1ms)
314992
+  (0.1ms) rollback transaction
314993
+  (0.0ms) begin transaction
314994
+ ------------------------------------------------------------------------------------
314995
+ RailsIdentity::UsersControllerTest: test_cannot_update_password_with_non-reset_token
314996
+ ------------------------------------------------------------------------------------
314997
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
314998
+ Processing by RailsIdentity::UsersController#update as HTML
314999
+ Parameters: {"password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
315000
+ Accepts a token
315001
+ Token well formatted for user 1,
315002
+ session 1
315003
+ Cache miss. Try database.
315004
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315005
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315006
+ Token well formatted and verified. Set cache.
315007
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315008
+ Attempting to get RailsIdentity::User 1
315009
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315010
+ Checking to see if authorized to access object
315011
+ RailsIdentity::Errors::UnauthorizedError
315012
+ Completed 401 Unauthorized in 5ms (Views: 0.3ms | ActiveRecord: 0.2ms)
315013
+  (0.1ms) rollback transaction
315014
+  (0.1ms) begin transaction
315015
+ ----------------------------------------------------
315016
+ RailsIdentity::UsersControllerTest: test_show_a_user
315017
+ ----------------------------------------------------
315018
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315019
+ Processing by RailsIdentity::UsersController#show as HTML
315020
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
315021
+ Requires a token
315022
+ Token well formatted for user 1,
315023
+ session 1
315024
+ Cache miss. Try database.
315025
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315026
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315027
+ Token well formatted and verified. Set cache.
315028
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315029
+ Attempting to get RailsIdentity::User 1
315030
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315031
+ Checking to see if authorized to access object
315032
+ Completed 200 OK in 5ms (Views: 0.6ms | ActiveRecord: 0.2ms)
315033
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315034
+  (0.0ms) rollback transaction
315035
+  (0.0ms) begin transaction
315036
+ ------------------------------------------------------------------
315037
+ RailsIdentity::UsersControllerTest: test_public_cannot_show_a_user
315038
+ ------------------------------------------------------------------
315039
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315040
+ Processing by RailsIdentity::UsersController#show as HTML
315041
+ Parameters: {"id"=>"1"}
315042
+ Requires a token
315043
+ Token decode error: Nil JSON web token
315044
+ Invalid token:
315045
+ Completed 401 Unauthorized in 0ms (Views: 0.2ms | ActiveRecord: 0.0ms)
315046
+  (0.1ms) rollback transaction
315047
+  (0.0ms) begin transaction
315048
+ --------------------------------------------------------------------------------
315049
+ RailsIdentity::UsersControllerTest: test_cannot_create_a_user_without_a_password
315050
+ --------------------------------------------------------------------------------
315051
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315052
+ Processing by RailsIdentity::UsersController#create as HTML
315053
+ Parameters: {"username"=>"foo@example.com"}
315054
+ Accepts a token
315055
+ Token decode error: Nil JSON web token
315056
+ Suppressing error: Invalid token:
315057
+  (0.1ms) SAVEPOINT active_record_1
315058
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
315059
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
315060
+ Completed 400 Bad Request in 36ms (Views: 0.3ms | ActiveRecord: 0.3ms)
315061
+  (0.1ms) rollback transaction
315062
+  (0.0ms) begin transaction
315063
+ -------------------------------------------------------------------
315064
+ RailsIdentity::UsersControllerTest: test_cannot_update_another_user
315065
+ -------------------------------------------------------------------
315066
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315067
+ Processing by RailsIdentity::UsersController#update as HTML
315068
+ Parameters: {"username"=>"foo@example.com", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"2"}
315069
+ Accepts a token
315070
+ Token well formatted for user 1,
315071
+ session 1
315072
+ Cache miss. Try database.
315073
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315074
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315075
+ Token well formatted and verified. Set cache.
315076
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315077
+ Attempting to get RailsIdentity::User 2
315078
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "2"]]
315079
+ Checking to see if authorized to access object
315080
+ RailsIdentity::Errors::UnauthorizedError
315081
+ Completed 401 Unauthorized in 5ms (Views: 0.2ms | ActiveRecord: 0.2ms)
315082
+  (0.1ms) rollback transaction
315083
+  (0.0ms) begin transaction
315084
+ --------------------------------------------------------------------
315085
+ RailsIdentity::UsersControllerTest: test_admin_can_delete_other_user
315086
+ --------------------------------------------------------------------
315087
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315088
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
315089
+ Processing by RailsIdentity::UsersController#destroy as HTML
315090
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzg4MzA1fQ.AHk7rkxYSQg_zGjx1B2puIZtrxRkHmgFTaF68DsUfpI", "id"=>"1"}
315091
+ Requires a token
315092
+ Token well formatted for user admin_one,
315093
+ session session_admin_one
315094
+ Cache miss. Try database.
315095
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
315096
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
315097
+ Token well formatted and verified. Set cache.
315098
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
315099
+ Attempting to get RailsIdentity::User 1
315100
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315101
+ Checking to see if authorized to access object
315102
+  (0.1ms) SAVEPOINT active_record_1
315103
+ SQL (0.2ms) UPDATE "rails_identity_users" SET "deleted_at" = '2016-04-15 16:31:46.195292' WHERE "rails_identity_users"."uuid" = ? [["uuid", "1"]]
315104
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315105
+ Rendered text template (0.0ms)
315106
+ Completed 204 No Content in 10ms (Views: 4.4ms | ActiveRecord: 0.5ms)
315107
+  (0.4ms) rollback transaction
315108
+  (0.0ms) begin transaction
315109
+ -------------------------------------------------------------------------------------------------
315110
+ RailsIdentity::UsersControllerTest: test_cannot_update_(issue)_a_new_reset_token_without_username
315111
+ -------------------------------------------------------------------------------------------------
315112
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315113
+ Processing by RailsIdentity::UsersController#update as HTML
315114
+ Parameters: {"issue_reset_token"=>true, "id"=>"current"}
315115
+ Accepts a token
315116
+ Token decode error: Nil JSON web token
315117
+ Suppressing error: Invalid token:
315118
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" IS NULL LIMIT 1
315119
+ RailsIdentity::Errors::ObjectNotFoundError
315120
+ Completed 404 Not Found in 1ms (Views: 0.2ms | ActiveRecord: 0.1ms)
315121
+  (0.1ms) rollback transaction
315122
+  (0.1ms) begin transaction
315123
+ ------------------------------------------------------------
315124
+ RailsIdentity::UsersControllerTest: test_delete_current_user
315125
+ ------------------------------------------------------------
315126
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315127
+ Processing by RailsIdentity::UsersController#destroy as HTML
315128
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"current"}
315129
+ Requires a token
315130
+ Token well formatted for user 1,
315131
+ session 1
315132
+ Cache miss. Try database.
315133
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315134
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315135
+ Token well formatted and verified. Set cache.
315136
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315137
+ Attempting to get RailsIdentity::User 1
315138
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315139
+ Checking to see if authorized to access object
315140
+  (0.0ms) SAVEPOINT active_record_1
315141
+ SQL (0.2ms) UPDATE "rails_identity_users" SET "deleted_at" = '2016-04-15 16:31:46.215407' WHERE "rails_identity_users"."uuid" = ? [["uuid", "1"]]
315142
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315143
+ Rendered text template (0.0ms)
315144
+ Completed 204 No Content in 6ms (Views: 0.4ms | ActiveRecord: 0.4ms)
315145
+  (0.4ms) rollback transaction
315146
+  (0.1ms) begin transaction
315147
+ ---------------------------------------------------------------
315148
+ RailsIdentity::UsersControllerTest: test_cannot_show_other_user
315149
+ ---------------------------------------------------------------
315150
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315151
+ Processing by RailsIdentity::UsersController#show as HTML
315152
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"2"}
315153
+ Requires a token
315154
+ Token well formatted for user 1,
315155
+ session 1
315156
+ Cache miss. Try database.
315157
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315158
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315159
+ Token well formatted and verified. Set cache.
315160
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315161
+ Attempting to get RailsIdentity::User 2
315162
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "2"]]
315163
+ Checking to see if authorized to access object
315164
+ RailsIdentity::Errors::UnauthorizedError
315165
+ Completed 401 Unauthorized in 7ms (Views: 0.2ms | ActiveRecord: 0.2ms)
315166
+  (0.1ms) rollback transaction
315167
+  (0.0ms) begin transaction
315168
+ -----------------------------------------------------------------------
315169
+ RailsIdentity::UsersControllerTest: test_admin_can_create_an_admin_user
315170
+ -----------------------------------------------------------------------
315171
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315172
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
315173
+ Processing by RailsIdentity::UsersController#create as HTML
315174
+ Parameters: {"username"=>"foo@example.com", "password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]", "role"=>"100", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzg4MzA1fQ.AHk7rkxYSQg_zGjx1B2puIZtrxRkHmgFTaF68DsUfpI"}
315175
+ Accepts a token
315176
+ Token well formatted for user admin_one,
315177
+ session session_admin_one
315178
+ Cache miss. Try database.
315179
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
315180
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
315181
+ Token well formatted and verified. Set cache.
315182
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
315183
+ Unpermitted parameter: token
315184
+  (0.1ms) SAVEPOINT active_record_1
315185
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
315186
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "role", "verification_token", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$v7sieY7Oob8yrTLwvWqi6.LkIwnBq/OaSGgLDgyFfnwoZoeMEC3M2"], ["role", 100], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiOWU3MGRhLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOjEwMCwiaWF0IjoxNDYwNzM3OTA2LCJleHAiOjE0NjA3NDE1MDZ9.Dp8GpDa5cQawueJ4MFlBmA1fQWoSp0e-Hy_5cprMtsg"], ["created_at", "2016-04-15 16:31:46.241993"], ["updated_at", "2016-04-15 16:31:46.241993"], ["uuid", "8b9ebaea-0327-11e6-ba3a-6c4008a6fa2a"]]
315187
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315188
+ [ActiveJob] RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "8b9ebaea-0327-11e6-ba3a-6c4008a6fa2a"]]
315189
+ [ActiveJob] [ActionMailer::DeliveryJob] [a9728ca6-e0a7-4f20-a131-e5f306b3783e] Performing ActionMailer::DeliveryJob from Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/8b9ebaea-0327-11e6-ba3a-6c4008a6fa2a
315190
+ [ActiveJob] [ActionMailer::DeliveryJob] [a9728ca6-e0a7-4f20-a131-e5f306b3783e] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.html.erb within layouts/mailer (1.5ms)
315191
+ [ActiveJob] [ActionMailer::DeliveryJob] [a9728ca6-e0a7-4f20-a131-e5f306b3783e] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.text.erb within layouts/mailer (0.5ms)
315192
+ [ActiveJob] [ActionMailer::DeliveryJob] [a9728ca6-e0a7-4f20-a131-e5f306b3783e]
315193
+ RailsIdentity::UserMailer#email_verification: processed outbound mail in 215.2ms
315194
+ [ActiveJob] [ActionMailer::DeliveryJob] [a9728ca6-e0a7-4f20-a131-e5f306b3783e]
315195
+ Sent mail to foo@example.com (6.0ms)
315196
+ [ActiveJob] [ActionMailer::DeliveryJob] [a9728ca6-e0a7-4f20-a131-e5f306b3783e] Date: Fri, 15 Apr 2016 11:31:46 -0500
315197
+ From: no-reply@rails-identity.com
315198
+ To: foo@example.com
315199
+ Message-ID: <571117727dde2_129323fd344c5246435a7@galt.local.mail>
315200
+ Subject: [rails-identity] Email Confirmation
315201
+ Mime-Version: 1.0
315202
+ Content-Type: multipart/alternative;
315203
+ boundary="--==_mimepart_571117727cce6_129323fd344c5246434c4";
315204
+ charset=UTF-8
315205
+ Content-Transfer-Encoding: 7bit
315206
+
315207
+
315208
+ ----==_mimepart_571117727cce6_129323fd344c5246434c4
315209
+ Content-Type: text/plain;
315210
+ charset=UTF-8
315211
+ Content-Transfer-Encoding: 7bit
315212
+
315213
+ Dear foo@example.com,
315214
+
315215
+ Please confirm your account with rails-identity by making a PATCH request
315216
+ on the current user with a provided verification token. For example,
315217
+
315218
+ http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiOWU3MGRhLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOjEwMCwiaWF0IjoxNDYwNzM3OTA2LCJleHAiOjE0NjA3NDE1MDZ9.Dp8GpDa5cQawueJ4MFlBmA1fQWoSp0e-Hy_5cprMtsg verified=true
315219
+
315220
+ will confirm the account. Here is the verification token:
315221
+
315222
+ eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiOWU3MGRhLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOjEwMCwiaWF0IjoxNDYwNzM3OTA2LCJleHAiOjE0NjA3NDE1MDZ9.Dp8GpDa5cQawueJ4MFlBmA1fQWoSp0e-Hy_5cprMtsg
315223
+
315224
+ Thank you for using rails-identity,
315225
+ rails-identity
315226
+
315227
+
315228
+ ----==_mimepart_571117727cce6_129323fd344c5246434c4
315229
+ Content-Type: text/html;
315230
+ charset=UTF-8
315231
+ Content-Transfer-Encoding: 7bit
315232
+
315233
+ <html>
315234
+ <body>
315235
+ <p>Dear foo@example.com,</p>
315236
+
315237
+ <p>Please confirm your account with rails-identity by making a PATCH request
315238
+ on the current user with a provided verification token. For example,
315239
+ <pre>http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiOWU3MGRhLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOjEwMCwiaWF0IjoxNDYwNzM3OTA2LCJleHAiOjE0NjA3NDE1MDZ9.Dp8GpDa5cQawueJ4MFlBmA1fQWoSp0e-Hy_5cprMtsg
315240
+ verified=true</pre> will confirm the account. Here is the verification
315241
+ token:</p>
315242
+
315243
+ <pre>eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiOWU3MGRhLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOjEwMCwiaWF0IjoxNDYwNzM3OTA2LCJleHAiOjE0NjA3NDE1MDZ9.Dp8GpDa5cQawueJ4MFlBmA1fQWoSp0e-Hy_5cprMtsg</pre>
315244
+
315245
+ <p>Thank you for using rails-identity</p>
315246
+ <p><b>rails-identity</b></p>
315247
+
315248
+ </body>
315249
+ </html>
315250
+
315251
+ ----==_mimepart_571117727cce6_129323fd344c5246434c4--
315252
+
315253
+ [ActiveJob] [ActionMailer::DeliveryJob] [a9728ca6-e0a7-4f20-a131-e5f306b3783e] Performed ActionMailer::DeliveryJob from Inline(mailers) in 221.95ms
315254
+ [ActiveJob] Enqueued ActionMailer::DeliveryJob (Job ID: a9728ca6-e0a7-4f20-a131-e5f306b3783e) to Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/8b9ebaea-0327-11e6-ba3a-6c4008a6fa2a
315255
+ Completed 201 Created in 285ms (Views: 0.5ms | ActiveRecord: 0.6ms)
315256
+  (0.6ms) rollback transaction
315257
+  (0.0ms) begin transaction
315258
+ ------------------------------------------------------------------------------------
315259
+ RailsIdentity::UsersControllerTest: test_cannot_update_password_with_a_invalid_token
315260
+ ------------------------------------------------------------------------------------
315261
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315262
+ Processing by RailsIdentity::UsersController#update as HTML
315263
+ Parameters: {"old_password"=>"[FILTERED]", "password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
315264
+ Accepts a token
315265
+ Token well formatted for user 1,
315266
+ session 1
315267
+ Cache miss. Try database.
315268
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315269
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315270
+ Token well formatted and verified. Set cache.
315271
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315272
+ Attempting to get RailsIdentity::User 1
315273
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315274
+ Checking to see if authorized to access object
315275
+ RailsIdentity::Errors::UnauthorizedError
315276
+ Completed 401 Unauthorized in 76ms (Views: 0.2ms | ActiveRecord: 0.2ms)
315277
+  (0.1ms) rollback transaction
315278
+  (0.0ms) begin transaction
315279
+ ---------------------------------------------------------------------
315280
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_ill-formed
315281
+ ---------------------------------------------------------------------
315282
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315283
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315284
+ Processing by RailsIdentity::UsersController#show as HTML
315285
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzM3OTY2fQ.6PDZLjyDoS6mm-3SmhSGL5W__FgvsZ2cW-fSLMGWtnI", "id"=>"1"}
315286
+ Requires a token
315287
+ User UUID or session UUID is nil
315288
+ Invalid token payload content: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzM3OTY2fQ.6PDZLjyDoS6mm-3SmhSGL5W__FgvsZ2cW-fSLMGWtnI
315289
+ Completed 401 Unauthorized in 1ms (Views: 0.2ms | ActiveRecord: 0.0ms)
315290
+  (0.1ms) rollback transaction
315291
+  (0.0ms) begin transaction
315292
+ ------------------------------------------------------
315293
+ RailsIdentity::UsersControllerTest: test_update_a_user
315294
+ ------------------------------------------------------
315295
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315296
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315297
+ Processing by RailsIdentity::UsersController#update as HTML
315298
+ Parameters: {"username"=>"foo@example.com", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
315299
+ Accepts a token
315300
+ Token well formatted for user 1,
315301
+ session 1
315302
+ Cache miss. Try database.
315303
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315304
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315305
+ Token well formatted and verified. Set cache.
315306
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315307
+ Attempting to get RailsIdentity::User 1
315308
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315309
+ Checking to see if authorized to access object
315310
+ Unpermitted parameters: token, id
315311
+  (0.0ms) SAVEPOINT active_record_1
315312
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315313
+ SQL (0.2ms) UPDATE "rails_identity_users" SET "username" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["username", "foo@example.com"], ["updated_at", "2016-04-15 16:31:46.616915"], ["uuid", "1"]]
315314
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315315
+ Completed 200 OK in 8ms (Views: 0.4ms | ActiveRecord: 0.5ms)
315316
+  (0.4ms) rollback transaction
315317
+  (0.1ms) begin transaction
315318
+ -------------------------------------------------------------------
315319
+ RailsIdentity::UsersControllerTest: test_cannot_delete_another_user
315320
+ -------------------------------------------------------------------
315321
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315322
+ Processing by RailsIdentity::UsersController#destroy as HTML
315323
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"2"}
315324
+ Requires a token
315325
+ Token well formatted for user 1,
315326
+ session 1
315327
+ Cache miss. Try database.
315328
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315329
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315330
+ Token well formatted and verified. Set cache.
315331
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315332
+ Attempting to get RailsIdentity::User 2
315333
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "2"]]
315334
+ Checking to see if authorized to access object
315335
+ RailsIdentity::Errors::UnauthorizedError
315336
+ Completed 401 Unauthorized in 6ms (Views: 0.2ms | ActiveRecord: 0.2ms)
315337
+  (0.1ms) rollback transaction
315338
+  (0.0ms) begin transaction
315339
+ ------------------------------------------------------
315340
+ RailsIdentity::UsersControllerTest: test_create_a_user
315341
+ ------------------------------------------------------
315342
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315343
+ Processing by RailsIdentity::UsersController#create as HTML
315344
+ Parameters: {"username"=>"foo@example.com", "password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]"}
315345
+ Accepts a token
315346
+ Token decode error: Nil JSON web token
315347
+ Suppressing error: Invalid token:
315348
+  (0.1ms) SAVEPOINT active_record_1
315349
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
315350
+ SQL (0.3ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$NzFWBiwk12MxNCrNVz0V8e8QGxGOaajv7ajm04VW/Xxx2p6ZzNYkW"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZGIwMDA0LTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.1beGVYe7P5XeUQTVU4RBzBs1rzuuO57DX6I7wOrl4lo"], ["role", 10], ["created_at", "2016-04-15 16:31:46.638920"], ["updated_at", "2016-04-15 16:31:46.638920"], ["uuid", "8bdb487a-0327-11e6-ba3a-6c4008a6fa2a"]]
315351
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315352
+ [ActiveJob] RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "8bdb487a-0327-11e6-ba3a-6c4008a6fa2a"]]
315353
+ [ActiveJob] [ActionMailer::DeliveryJob] [1630e914-1e32-4fd6-ab2f-7e68c012fd77] Performing ActionMailer::DeliveryJob from Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/8bdb487a-0327-11e6-ba3a-6c4008a6fa2a
315354
+ [ActiveJob] [ActionMailer::DeliveryJob] [1630e914-1e32-4fd6-ab2f-7e68c012fd77] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.html.erb within layouts/mailer (0.1ms)
315355
+ [ActiveJob] [ActionMailer::DeliveryJob] [1630e914-1e32-4fd6-ab2f-7e68c012fd77] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.text.erb within layouts/mailer (0.0ms)
315356
+ [ActiveJob] [ActionMailer::DeliveryJob] [1630e914-1e32-4fd6-ab2f-7e68c012fd77]
315357
+ RailsIdentity::UserMailer#email_verification: processed outbound mail in 2.5ms
315358
+ [ActiveJob] [ActionMailer::DeliveryJob] [1630e914-1e32-4fd6-ab2f-7e68c012fd77]
315359
+ Sent mail to foo@example.com (3.6ms)
315360
+ [ActiveJob] [ActionMailer::DeliveryJob] [1630e914-1e32-4fd6-ab2f-7e68c012fd77] Date: Fri, 15 Apr 2016 11:31:46 -0500
315361
+ From: no-reply@rails-identity.com
315362
+ To: foo@example.com
315363
+ Message-ID: <571117729deac_129323fd344c52464376c@galt.local.mail>
315364
+ Subject: [rails-identity] Email Confirmation
315365
+ Mime-Version: 1.0
315366
+ Content-Type: multipart/alternative;
315367
+ boundary="--==_mimepart_571117729d544_129323fd344c524643699";
315368
+ charset=UTF-8
315369
+ Content-Transfer-Encoding: 7bit
315370
+
315371
+
315372
+ ----==_mimepart_571117729d544_129323fd344c524643699
315373
+ Content-Type: text/plain;
315374
+ charset=UTF-8
315375
+ Content-Transfer-Encoding: 7bit
315376
+
315377
+ Dear foo@example.com,
315378
+
315379
+ Please confirm your account with rails-identity by making a PATCH request
315380
+ on the current user with a provided verification token. For example,
315381
+
315382
+ http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZGIwMDA0LTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.1beGVYe7P5XeUQTVU4RBzBs1rzuuO57DX6I7wOrl4lo verified=true
315383
+
315384
+ will confirm the account. Here is the verification token:
315385
+
315386
+ eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZGIwMDA0LTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.1beGVYe7P5XeUQTVU4RBzBs1rzuuO57DX6I7wOrl4lo
315387
+
315388
+ Thank you for using rails-identity,
315389
+ rails-identity
315390
+
315391
+
315392
+ ----==_mimepart_571117729d544_129323fd344c524643699
315393
+ Content-Type: text/html;
315394
+ charset=UTF-8
315395
+ Content-Transfer-Encoding: 7bit
315396
+
315397
+ <html>
315398
+ <body>
315399
+ <p>Dear foo@example.com,</p>
315400
+
315401
+ <p>Please confirm your account with rails-identity by making a PATCH request
315402
+ on the current user with a provided verification token. For example,
315403
+ <pre>http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZGIwMDA0LTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.1beGVYe7P5XeUQTVU4RBzBs1rzuuO57DX6I7wOrl4lo
315404
+ verified=true</pre> will confirm the account. Here is the verification
315405
+ token:</p>
315406
+
315407
+ <pre>eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZGIwMDA0LTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.1beGVYe7P5XeUQTVU4RBzBs1rzuuO57DX6I7wOrl4lo</pre>
315408
+
315409
+ <p>Thank you for using rails-identity</p>
315410
+ <p><b>rails-identity</b></p>
315411
+
315412
+ </body>
315413
+ </html>
315414
+
315415
+ ----==_mimepart_571117729d544_129323fd344c524643699--
315416
+
315417
+ [ActiveJob] [ActionMailer::DeliveryJob] [1630e914-1e32-4fd6-ab2f-7e68c012fd77] Performed ActionMailer::DeliveryJob from Inline(mailers) in 6.51ms
315418
+ [ActiveJob] Enqueued ActionMailer::DeliveryJob (Job ID: 1630e914-1e32-4fd6-ab2f-7e68c012fd77) to Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/8bdb487a-0327-11e6-ba3a-6c4008a6fa2a
315419
+ Completed 201 Created in 15ms (Views: 0.4ms | ActiveRecord: 0.5ms)
315420
+  (0.5ms) rollback transaction
315421
+  (0.0ms) begin transaction
315422
+ ---------------------------------------------------------------------------------------------
315423
+ RailsIdentity::UsersControllerTest: test_update_a_user_with_a_new_password_using_old_password
315424
+ ---------------------------------------------------------------------------------------------
315425
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315426
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315427
+ Processing by RailsIdentity::UsersController#update as HTML
315428
+ Parameters: {"old_password"=>"[FILTERED]", "password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
315429
+ Accepts a token
315430
+ Token well formatted for user 1,
315431
+ session 1
315432
+ Cache miss. Try database.
315433
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315434
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315435
+ Token well formatted and verified. Set cache.
315436
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315437
+ Attempting to get RailsIdentity::User 1
315438
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315439
+ Checking to see if authorized to access object
315440
+ Unpermitted parameters: old_password, token, id
315441
+  (0.1ms) SAVEPOINT active_record_1
315442
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315443
+ SQL (0.3ms) UPDATE "rails_identity_users" SET "password_digest" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["password_digest", "$2a$04$2Lx6oJ4WFQTyfKeij3p1Puh6L/UN5tHyb6zUNZKYyHrfKqk3oGuN."], ["updated_at", "2016-04-15 16:31:46.739358"], ["uuid", "1"]]
315444
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315445
+ Completed 200 OK in 85ms (Views: 0.4ms | ActiveRecord: 0.6ms)
315446
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315447
+  (0.4ms) rollback transaction
315448
+  (0.1ms) begin transaction
315449
+ ---------------------------------------------------------------
315450
+ RailsIdentity::UsersControllerTest: test_public_can_see_options
315451
+ ---------------------------------------------------------------
315452
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315453
+ Processing by RailsIdentity::UsersController#options as HTML
315454
+ Rendered text template (0.0ms)
315455
+ Completed 200 OK in 1ms (Views: 0.7ms | ActiveRecord: 0.0ms)
315456
+  (0.1ms) rollback transaction
315457
+  (0.1ms) begin transaction
315458
+ -------------------------------------------------------------------------
315459
+ RailsIdentity::UsersControllerTest: test_user_cannot_create_an_admin_user
315460
+ -------------------------------------------------------------------------
315461
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315462
+ Processing by RailsIdentity::UsersController#create as HTML
315463
+ Parameters: {"username"=>"foo@example.com", "password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]", "role"=>"100"}
315464
+ Accepts a token
315465
+ Token decode error: Nil JSON web token
315466
+ Suppressing error: Invalid token:
315467
+ Unpermitted parameter: role
315468
+  (0.1ms) SAVEPOINT active_record_1
315469
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
315470
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$vsx3c6hjazKLWc0rihohPehyXZeoItI.m.1cjs5DLfXhn7SGsiWyC"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZWQ1MzgwLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.dv6iaHYiJaI3y1S8Ijv1trTQbfqQ_pz68KFLbbXtKs0"], ["role", 10], ["created_at", "2016-04-15 16:31:46.759213"], ["updated_at", "2016-04-15 16:31:46.759213"], ["uuid", "8beda448-0327-11e6-ba3a-6c4008a6fa2a"]]
315471
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315472
+ [ActiveJob] RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "8beda448-0327-11e6-ba3a-6c4008a6fa2a"]]
315473
+ [ActiveJob] [ActionMailer::DeliveryJob] [e334960e-783c-4c3f-a358-01ddcae48b28] Performing ActionMailer::DeliveryJob from Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/8beda448-0327-11e6-ba3a-6c4008a6fa2a
315474
+ [ActiveJob] [ActionMailer::DeliveryJob] [e334960e-783c-4c3f-a358-01ddcae48b28] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.html.erb within layouts/mailer (0.1ms)
315475
+ [ActiveJob] [ActionMailer::DeliveryJob] [e334960e-783c-4c3f-a358-01ddcae48b28] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.text.erb within layouts/mailer (0.0ms)
315476
+ [ActiveJob] [ActionMailer::DeliveryJob] [e334960e-783c-4c3f-a358-01ddcae48b28]
315477
+ RailsIdentity::UserMailer#email_verification: processed outbound mail in 2.7ms
315478
+ [ActiveJob] [ActionMailer::DeliveryJob] [e334960e-783c-4c3f-a358-01ddcae48b28]
315479
+ Sent mail to foo@example.com (3.8ms)
315480
+ [ActiveJob] [ActionMailer::DeliveryJob] [e334960e-783c-4c3f-a358-01ddcae48b28] Date: Fri, 15 Apr 2016 11:31:46 -0500
315481
+ From: no-reply@rails-identity.com
315482
+ To: foo@example.com
315483
+ Message-ID: <57111772bb711_129323fd344c52464398e@galt.local.mail>
315484
+ Subject: [rails-identity] Email Confirmation
315485
+ Mime-Version: 1.0
315486
+ Content-Type: multipart/alternative;
315487
+ boundary="--==_mimepart_57111772bad18_129323fd344c524643877";
315488
+ charset=UTF-8
315489
+ Content-Transfer-Encoding: 7bit
315490
+
315491
+
315492
+ ----==_mimepart_57111772bad18_129323fd344c524643877
315493
+ Content-Type: text/plain;
315494
+ charset=UTF-8
315495
+ Content-Transfer-Encoding: 7bit
315496
+
315497
+ Dear foo@example.com,
315498
+
315499
+ Please confirm your account with rails-identity by making a PATCH request
315500
+ on the current user with a provided verification token. For example,
315501
+
315502
+ http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZWQ1MzgwLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.dv6iaHYiJaI3y1S8Ijv1trTQbfqQ_pz68KFLbbXtKs0 verified=true
315503
+
315504
+ will confirm the account. Here is the verification token:
315505
+
315506
+ eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZWQ1MzgwLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.dv6iaHYiJaI3y1S8Ijv1trTQbfqQ_pz68KFLbbXtKs0
315507
+
315508
+ Thank you for using rails-identity,
315509
+ rails-identity
315510
+
315511
+
315512
+ ----==_mimepart_57111772bad18_129323fd344c524643877
315513
+ Content-Type: text/html;
315514
+ charset=UTF-8
315515
+ Content-Transfer-Encoding: 7bit
315516
+
315517
+ <html>
315518
+ <body>
315519
+ <p>Dear foo@example.com,</p>
315520
+
315521
+ <p>Please confirm your account with rails-identity by making a PATCH request
315522
+ on the current user with a provided verification token. For example,
315523
+ <pre>http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZWQ1MzgwLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.dv6iaHYiJaI3y1S8Ijv1trTQbfqQ_pz68KFLbbXtKs0
315524
+ verified=true</pre> will confirm the account. Here is the verification
315525
+ token:</p>
315526
+
315527
+ <pre>eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhiZWQ1MzgwLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.dv6iaHYiJaI3y1S8Ijv1trTQbfqQ_pz68KFLbbXtKs0</pre>
315528
+
315529
+ <p>Thank you for using rails-identity</p>
315530
+ <p><b>rails-identity</b></p>
315531
+
315532
+ </body>
315533
+ </html>
315534
+
315535
+ ----==_mimepart_57111772bad18_129323fd344c524643877--
315536
+
315537
+ [ActiveJob] [ActionMailer::DeliveryJob] [e334960e-783c-4c3f-a358-01ddcae48b28] Performed ActionMailer::DeliveryJob from Inline(mailers) in 6.95ms
315538
+ [ActiveJob] Enqueued ActionMailer::DeliveryJob (Job ID: e334960e-783c-4c3f-a358-01ddcae48b28) to Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/8beda448-0327-11e6-ba3a-6c4008a6fa2a
315539
+ Completed 201 Created in 16ms (Views: 0.4ms | ActiveRecord: 0.5ms)
315540
+  (0.4ms) rollback transaction
315541
+  (0.1ms) begin transaction
315542
+ ------------------------------------------------------------------------------
315543
+ RailsIdentity::UsersControllerTest: test_update_(reissue)_a_verification_token
315544
+ ------------------------------------------------------------------------------
315545
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315546
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315547
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = '1' LIMIT 1
315548
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315549
+ Processing by RailsIdentity::UsersController#update as HTML
315550
+ Parameters: {"issue_verification_token"=>true, "username"=>"one@example.com", "id"=>"current"}
315551
+ Accepts a token
315552
+ Token decode error: Nil JSON web token
315553
+ Suppressing error: Invalid token:
315554
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "one@example.com"]]
315555
+  (0.1ms) SAVEPOINT active_record_1
315556
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "8bf0a332-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "879cea76-1fb9-44ee-9c9b-fc89a3725c54"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmMGEzMzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Vln5VJwlOdPW0Y865ohJbo9msb3Y8EFU3RGl-799UaY"], ["created_at", "2016-04-15 16:31:46.779948"], ["updated_at", "2016-04-15 16:31:46.779948"]]
315557
+  (0.1ms) RELEASE SAVEPOINT active_record_1
315558
+  (0.0ms) SAVEPOINT active_record_1
315559
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315560
+ SQL (0.1ms) UPDATE "rails_identity_users" SET "verification_token" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmMGEzMzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Vln5VJwlOdPW0Y865ohJbo9msb3Y8EFU3RGl-799UaY"], ["updated_at", "2016-04-15 16:31:46.782285"], ["uuid", "1"]]
315561
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315562
+ [ActiveJob] RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315563
+ [ActiveJob] [ActionMailer::DeliveryJob] [8b8dc297-f2e7-4a12-b804-d37253d36284] Performing ActionMailer::DeliveryJob from Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/1
315564
+ [ActiveJob] [ActionMailer::DeliveryJob] [8b8dc297-f2e7-4a12-b804-d37253d36284] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.html.erb within layouts/mailer (0.1ms)
315565
+ [ActiveJob] [ActionMailer::DeliveryJob] [8b8dc297-f2e7-4a12-b804-d37253d36284] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/email_verification.text.erb within layouts/mailer (0.1ms)
315566
+ [ActiveJob] [ActionMailer::DeliveryJob] [8b8dc297-f2e7-4a12-b804-d37253d36284]
315567
+ RailsIdentity::UserMailer#email_verification: processed outbound mail in 2.8ms
315568
+ [ActiveJob] [ActionMailer::DeliveryJob] [8b8dc297-f2e7-4a12-b804-d37253d36284]
315569
+ Sent mail to one@example.com (3.8ms)
315570
+ [ActiveJob] [ActionMailer::DeliveryJob] [8b8dc297-f2e7-4a12-b804-d37253d36284] Date: Fri, 15 Apr 2016 11:31:46 -0500
315571
+ From: no-reply@rails-identity.com
315572
+ To: one@example.com
315573
+ Message-ID: <57111772c0d30_129323fd344c5246441e5@galt.local.mail>
315574
+ Subject: [rails-identity] Email Confirmation
315575
+ Mime-Version: 1.0
315576
+ Content-Type: multipart/alternative;
315577
+ boundary="--==_mimepart_57111772c030c_129323fd344c524644091";
315578
+ charset=UTF-8
315579
+ Content-Transfer-Encoding: 7bit
315580
+
315581
+
315582
+ ----==_mimepart_57111772c030c_129323fd344c524644091
315583
+ Content-Type: text/plain;
315584
+ charset=UTF-8
315585
+ Content-Transfer-Encoding: 7bit
315586
+
315587
+ Dear one@example.com,
315588
+
315589
+ Please confirm your account with rails-identity by making a PATCH request
315590
+ on the current user with a provided verification token. For example,
315591
+
315592
+ http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmMGEzMzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Vln5VJwlOdPW0Y865ohJbo9msb3Y8EFU3RGl-799UaY verified=true
315593
+
315594
+ will confirm the account. Here is the verification token:
315595
+
315596
+ eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmMGEzMzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Vln5VJwlOdPW0Y865ohJbo9msb3Y8EFU3RGl-799UaY
315597
+
315598
+ Thank you for using rails-identity,
315599
+ rails-identity
315600
+
315601
+
315602
+ ----==_mimepart_57111772c030c_129323fd344c524644091
315603
+ Content-Type: text/html;
315604
+ charset=UTF-8
315605
+ Content-Transfer-Encoding: 7bit
315606
+
315607
+ <html>
315608
+ <body>
315609
+ <p>Dear one@example.com,</p>
315610
+
315611
+ <p>Please confirm your account with rails-identity by making a PATCH request
315612
+ on the current user with a provided verification token. For example,
315613
+ <pre>http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmMGEzMzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Vln5VJwlOdPW0Y865ohJbo9msb3Y8EFU3RGl-799UaY
315614
+ verified=true</pre> will confirm the account. Here is the verification
315615
+ token:</p>
315616
+
315617
+ <pre>eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmMGEzMzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Vln5VJwlOdPW0Y865ohJbo9msb3Y8EFU3RGl-799UaY</pre>
315618
+
315619
+ <p>Thank you for using rails-identity</p>
315620
+ <p><b>rails-identity</b></p>
315621
+
315622
+ </body>
315623
+ </html>
315624
+
315625
+ ----==_mimepart_57111772c030c_129323fd344c524644091--
315626
+
315627
+ [ActiveJob] [ActionMailer::DeliveryJob] [8b8dc297-f2e7-4a12-b804-d37253d36284] Performed ActionMailer::DeliveryJob from Inline(mailers) in 7.01ms
315628
+ [ActiveJob] Enqueued ActionMailer::DeliveryJob (Job ID: 8b8dc297-f2e7-4a12-b804-d37253d36284) to Inline(mailers) with arguments: "RailsIdentity::UserMailer", "email_verification", "deliver_now", gid://dummy/RailsIdentity::User/1
315629
+ Rendered text template (0.0ms)
315630
+ Completed 204 No Content in 15ms (Views: 0.3ms | ActiveRecord: 0.7ms)
315631
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = '1' LIMIT 1
315632
+ Processing by RailsIdentity::UsersController#update as HTML
315633
+ Parameters: {"verified"=>true, "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmMGEzMzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Vln5VJwlOdPW0Y865ohJbo9msb3Y8EFU3RGl-799UaY", "id"=>"current"}
315634
+ Accepts a token
315635
+ Token well formatted for user 1,
315636
+ session 8bf0a332-0327-11e6-ba3a-6c4008a6fa2a
315637
+ Cache miss. Try database.
315638
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315639
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "8bf0a332-0327-11e6-ba3a-6c4008a6fa2a"]]
315640
+ Token well formatted and verified. Set cache.
315641
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315642
+ Attempting to get RailsIdentity::User 1
315643
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315644
+ Checking to see if authorized to access object
315645
+ Unpermitted parameters: token, id
315646
+  (0.0ms) SAVEPOINT active_record_1
315647
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315648
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315649
+ Completed 200 OK in 6ms (Views: 0.3ms | ActiveRecord: 1.0ms)
315650
+  (0.4ms) rollback transaction
315651
+  (0.0ms) begin transaction
315652
+ ---------------------------------------------------------------------------------------------
315653
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_well-formed_but_non-existing_token
315654
+ ---------------------------------------------------------------------------------------------
315655
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315656
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315657
+ Processing by RailsIdentity::UsersController#show as HTML
315658
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiMSIsInJvbGUiOjEwLCJpYXQiOjE0NjA3Mzc5MDYsImV4cCI6MTQ2MDczNzk2Nn0.B2q6X3XscnBii9TKcj1H_cMontQqA8doKHmokf0i0JA", "id"=>"1"}
315659
+ Requires a token
315660
+ Token well formatted for user 1,
315661
+ session 1
315662
+ Cache miss. Try database.
315663
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315664
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315665
+ Signature verification raised
315666
+ Cannot verify token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiMSIsInJvbGUiOjEwLCJpYXQiOjE0NjA3Mzc5MDYsImV4cCI6MTQ2MDczNzk2Nn0.B2q6X3XscnBii9TKcj1H_cMontQqA8doKHmokf0i0JA
315667
+ Completed 401 Unauthorized in 2ms (Views: 0.2ms | ActiveRecord: 0.1ms)
315668
+  (0.1ms) rollback transaction
315669
+  (0.0ms) begin transaction
315670
+ --------------------------------------------------------------------------
315671
+ RailsIdentity::UsersControllerTest: test_update_password_using_reset_token
315672
+ --------------------------------------------------------------------------
315673
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315674
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315675
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315676
+ Processing by RailsIdentity::UsersController#update as HTML
315677
+ Parameters: {"issue_reset_token"=>true, "username"=>"one@example.com", "id"=>"current"}
315678
+ Accepts a token
315679
+ Token decode error: Nil JSON web token
315680
+ Suppressing error: Invalid token:
315681
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "one@example.com"]]
315682
+  (0.0ms) SAVEPOINT active_record_1
315683
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "8bf61dc6-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "4530a03d-4cfc-45b0-b6ae-a15b6b985724"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmNjFkYzYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.UqYKgxvudo-8bIM2fOo7Dv43__HGEOfU3MxGGqnSl5w"], ["created_at", "2016-04-15 16:31:46.815702"], ["updated_at", "2016-04-15 16:31:46.815702"]]
315684
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315685
+  (0.0ms) SAVEPOINT active_record_1
315686
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315687
+ SQL (0.1ms) UPDATE "rails_identity_users" SET "reset_token" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["reset_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmNjFkYzYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.UqYKgxvudo-8bIM2fOo7Dv43__HGEOfU3MxGGqnSl5w"], ["updated_at", "2016-04-15 16:31:46.817813"], ["uuid", "1"]]
315688
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315689
+ [ActiveJob] RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315690
+ [ActiveJob] [ActionMailer::DeliveryJob] [aaa358c9-de1b-4617-95eb-131e1a15f1eb] Performing ActionMailer::DeliveryJob from Inline(mailers) with arguments: "RailsIdentity::UserMailer", "password_reset", "deliver_now", gid://dummy/RailsIdentity::User/1
315691
+ [ActiveJob] [ActionMailer::DeliveryJob] [aaa358c9-de1b-4617-95eb-131e1a15f1eb] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/password_reset.html.erb within layouts/mailer (0.5ms)
315692
+ [ActiveJob] [ActionMailer::DeliveryJob] [aaa358c9-de1b-4617-95eb-131e1a15f1eb] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/password_reset.text.erb within layouts/mailer (0.3ms)
315693
+ [ActiveJob] [ActionMailer::DeliveryJob] [aaa358c9-de1b-4617-95eb-131e1a15f1eb]
315694
+ RailsIdentity::UserMailer#password_reset: processed outbound mail in 8.5ms
315695
+ [ActiveJob] [ActionMailer::DeliveryJob] [aaa358c9-de1b-4617-95eb-131e1a15f1eb]
315696
+ Sent mail to one@example.com (3.4ms)
315697
+ [ActiveJob] [ActionMailer::DeliveryJob] [aaa358c9-de1b-4617-95eb-131e1a15f1eb] Date: Fri, 15 Apr 2016 11:31:46 -0500
315698
+ From: no-reply@rails-identity.com
315699
+ To: one@example.com
315700
+ Message-ID: <57111772cad23_129323fd344c524644339@galt.local.mail>
315701
+ Subject: [rails-identity] Password Reset
315702
+ Mime-Version: 1.0
315703
+ Content-Type: multipart/alternative;
315704
+ boundary="--==_mimepart_57111772ca338_129323fd344c5246442f3";
315705
+ charset=UTF-8
315706
+ Content-Transfer-Encoding: 7bit
315707
+
315708
+
315709
+ ----==_mimepart_57111772ca338_129323fd344c5246442f3
315710
+ Content-Type: text/plain;
315711
+ charset=UTF-8
315712
+ Content-Transfer-Encoding: 7bit
315713
+
315714
+ Dear one@example.com,
315715
+
315716
+ You have requested to reset your password. Here are the user UUID and reset
315717
+ token. Make a PATCH request on the UUID with the reset token to set a new
315718
+ password. For instance,
315719
+
315720
+ http PATCH /users/current token=... password=reallysecret password_confirmation=reallysecret
315721
+
315722
+ will set the password to "reallysecret" (without quotes) for the user to
315723
+ whom the reset token was issued.
315724
+
315725
+ Here is the reset token: @user.reset_token
315726
+
315727
+ Good luck! :)
315728
+ rails-identity
315729
+
315730
+
315731
+ ----==_mimepart_57111772ca338_129323fd344c5246442f3
315732
+ Content-Type: text/html;
315733
+ charset=UTF-8
315734
+ Content-Transfer-Encoding: 7bit
315735
+
315736
+ <html>
315737
+ <body>
315738
+ <p>Dear one@example.com,</p>
315739
+
315740
+ <p>You have requested to reset your password. Here are the user UUID and
315741
+ reset token. Make a PATCH request on the UUID with the reset token to set a
315742
+ new password. For instance, <pre>http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmNjFkYzYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.UqYKgxvudo-8bIM2fOo7Dv43__HGEOfU3MxGGqnSl5w password=reallysecret
315743
+ password_confirmation=reallysecret</pre> will set the password to
315744
+ <pre>reallysecret</pre> for the user to whom the reset token was issued.
315745
+ Here is the reset token:</p>
315746
+
315747
+ <pre>eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmNjFkYzYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.UqYKgxvudo-8bIM2fOo7Dv43__HGEOfU3MxGGqnSl5w</pre>
315748
+
315749
+ <p>Good luck! :)</p>
315750
+ <p><b>rails-identity</b></p>
315751
+
315752
+ </body>
315753
+ </html>
315754
+
315755
+ ----==_mimepart_57111772ca338_129323fd344c5246442f3--
315756
+
315757
+ [ActiveJob] [ActionMailer::DeliveryJob] [aaa358c9-de1b-4617-95eb-131e1a15f1eb] Performed ActionMailer::DeliveryJob from Inline(mailers) in 12.39ms
315758
+ [ActiveJob] Enqueued ActionMailer::DeliveryJob (Job ID: aaa358c9-de1b-4617-95eb-131e1a15f1eb) to Inline(mailers) with arguments: "RailsIdentity::UserMailer", "password_reset", "deliver_now", gid://dummy/RailsIdentity::User/1
315759
+ Rendered text template (0.0ms)
315760
+ Completed 204 No Content in 20ms (Views: 0.3ms | ActiveRecord: 0.6ms)
315761
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315762
+ Processing by RailsIdentity::UsersController#update as HTML
315763
+ Parameters: {"password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmNjFkYzYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.UqYKgxvudo-8bIM2fOo7Dv43__HGEOfU3MxGGqnSl5w", "id"=>"1"}
315764
+ Accepts a token
315765
+ Token well formatted for user 1,
315766
+ session 8bf61dc6-0327-11e6-ba3a-6c4008a6fa2a
315767
+ Cache miss. Try database.
315768
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315769
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "8bf61dc6-0327-11e6-ba3a-6c4008a6fa2a"]]
315770
+ Token well formatted and verified. Set cache.
315771
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315772
+ Attempting to get RailsIdentity::User 1
315773
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315774
+ Checking to see if authorized to access object
315775
+ Unpermitted parameters: token, id
315776
+  (0.1ms) SAVEPOINT active_record_1
315777
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315778
+ SQL (0.2ms) UPDATE "rails_identity_users" SET "password_digest" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["password_digest", "$2a$04$WIMYkabPJbhnGjy1CVoGSerLjt3PIYsMG7JOtxZz80R9Ze/X7HqRO"], ["updated_at", "2016-04-15 16:31:46.843189"], ["uuid", "1"]]
315779
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315780
+ Completed 200 OK in 9ms (Views: 0.4ms | ActiveRecord: 1.2ms)
315781
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315782
+  (0.7ms) rollback transaction
315783
+  (0.0ms) begin transaction
315784
+ -----------------------------------------------------------------------
315785
+ RailsIdentity::UsersControllerTest: test_cannot_show_a_nonexisting_user
315786
+ -----------------------------------------------------------------------
315787
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315788
+ Processing by RailsIdentity::UsersController#show as HTML
315789
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"999"}
315790
+ Requires a token
315791
+ Token well formatted for user 1,
315792
+ session 1
315793
+ Cache miss. Try database.
315794
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315795
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315796
+ Token well formatted and verified. Set cache.
315797
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315798
+ Attempting to get RailsIdentity::User 999
315799
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "999"]]
315800
+ RailsIdentity::User 999 cannot be found
315801
+ Completed 404 Not Found in 5ms (Views: 0.2ms | ActiveRecord: 0.2ms)
315802
+  (0.1ms) rollback transaction
315803
+  (0.1ms) begin transaction
315804
+ ------------------------------------------------------
315805
+ RailsIdentity::UsersControllerTest: test_delete_a_user
315806
+ ------------------------------------------------------
315807
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315808
+ Processing by RailsIdentity::UsersController#destroy as HTML
315809
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
315810
+ Requires a token
315811
+ Token well formatted for user 1,
315812
+ session 1
315813
+ Cache miss. Try database.
315814
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315815
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315816
+ Token well formatted and verified. Set cache.
315817
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315818
+ Attempting to get RailsIdentity::User 1
315819
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315820
+ Checking to see if authorized to access object
315821
+  (0.1ms) SAVEPOINT active_record_1
315822
+ SQL (0.2ms) UPDATE "rails_identity_users" SET "deleted_at" = '2016-04-15 16:31:46.864066' WHERE "rails_identity_users"."uuid" = ? [["uuid", "1"]]
315823
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315824
+ Rendered text template (0.0ms)
315825
+ Completed 204 No Content in 6ms (Views: 0.4ms | ActiveRecord: 0.5ms)
315826
+  (0.4ms) rollback transaction
315827
+  (0.0ms) begin transaction
315828
+ ----------------------------------------------------------------------------------------
315829
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_well-formed_but_bogus_payload
315830
+ ----------------------------------------------------------------------------------------
315831
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315832
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315833
+ Processing by RailsIdentity::UsersController#show as HTML
315834
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiZG9lc25vdGV4aXN0Iiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzM3OTY2fQ.VxSdykezqC8F-4bc1hpBONQ0YEgJSI_5GVULzXnzzzU", "id"=>"1"}
315835
+ Requires a token
315836
+ Token well formatted for user 1,
315837
+ session doesnotexist
315838
+ Cache miss. Try database.
315839
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315840
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "doesnotexist"]]
315841
+ Well-formed but invalid session token: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiZG9lc25vdGV4aXN0Iiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzM3OTY2fQ.VxSdykezqC8F-4bc1hpBONQ0YEgJSI_5GVULzXnzzzU
315842
+ Completed 401 Unauthorized in 2ms (Views: 0.2ms | ActiveRecord: 0.1ms)
315843
+  (0.1ms) rollback transaction
315844
+  (0.0ms) begin transaction
315845
+ -------------------------------------------------------------------------
315846
+ RailsIdentity::UsersControllerTest: test_update_(issue)_a_new_reset_token
315847
+ -------------------------------------------------------------------------
315848
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315849
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315850
+ Processing by RailsIdentity::UsersController#update as HTML
315851
+ Parameters: {"issue_reset_token"=>true, "username"=>"one@example.com", "id"=>"current"}
315852
+ Accepts a token
315853
+ Token decode error: Nil JSON web token
315854
+ Suppressing error: Invalid token:
315855
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "one@example.com"]]
315856
+  (0.0ms) SAVEPOINT active_record_1
315857
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "8bfff4d6-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "e7f6e87f-f737-4c50-b3e9-54f198f47676"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmZmY0ZDYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Y4RGV1q_thqahwlzvF4zGaMyWDVP_jYjK6XWJA2s3ZY"], ["created_at", "2016-04-15 16:31:46.880172"], ["updated_at", "2016-04-15 16:31:46.880172"]]
315858
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315859
+  (0.0ms) SAVEPOINT active_record_1
315860
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315861
+ SQL (0.1ms) UPDATE "rails_identity_users" SET "reset_token" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["reset_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmZmY0ZDYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Y4RGV1q_thqahwlzvF4zGaMyWDVP_jYjK6XWJA2s3ZY"], ["updated_at", "2016-04-15 16:31:46.882263"], ["uuid", "1"]]
315862
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315863
+ [ActiveJob] RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315864
+ [ActiveJob] [ActionMailer::DeliveryJob] [16ffae69-0b8d-4194-967e-39cf3b014b3f] Performing ActionMailer::DeliveryJob from Inline(mailers) with arguments: "RailsIdentity::UserMailer", "password_reset", "deliver_now", gid://dummy/RailsIdentity::User/1
315865
+ [ActiveJob] [ActionMailer::DeliveryJob] [16ffae69-0b8d-4194-967e-39cf3b014b3f] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/password_reset.html.erb within layouts/mailer (0.2ms)
315866
+ [ActiveJob] [ActionMailer::DeliveryJob] [16ffae69-0b8d-4194-967e-39cf3b014b3f] Rendered /Users/davidan/Projects/Personal/rails-identity/app/views/rails_identity/user_mailer/password_reset.text.erb within layouts/mailer (0.1ms)
315867
+ [ActiveJob] [ActionMailer::DeliveryJob] [16ffae69-0b8d-4194-967e-39cf3b014b3f]
315868
+ RailsIdentity::UserMailer#password_reset: processed outbound mail in 3.4ms
315869
+ [ActiveJob] [ActionMailer::DeliveryJob] [16ffae69-0b8d-4194-967e-39cf3b014b3f]
315870
+ Sent mail to one@example.com (5.2ms)
315871
+ [ActiveJob] [ActionMailer::DeliveryJob] [16ffae69-0b8d-4194-967e-39cf3b014b3f] Date: Fri, 15 Apr 2016 11:31:46 -0500
315872
+ From: no-reply@rails-identity.com
315873
+ To: one@example.com
315874
+ Message-ID: <57111772d9604_129323fd344c524644569@galt.local.mail>
315875
+ Subject: [rails-identity] Password Reset
315876
+ Mime-Version: 1.0
315877
+ Content-Type: multipart/alternative;
315878
+ boundary="--==_mimepart_57111772d8b2f_129323fd344c5246444a5";
315879
+ charset=UTF-8
315880
+ Content-Transfer-Encoding: 7bit
315881
+
315882
+
315883
+ ----==_mimepart_57111772d8b2f_129323fd344c5246444a5
315884
+ Content-Type: text/plain;
315885
+ charset=UTF-8
315886
+ Content-Transfer-Encoding: 7bit
315887
+
315888
+ Dear one@example.com,
315889
+
315890
+ You have requested to reset your password. Here are the user UUID and reset
315891
+ token. Make a PATCH request on the UUID with the reset token to set a new
315892
+ password. For instance,
315893
+
315894
+ http PATCH /users/current token=... password=reallysecret password_confirmation=reallysecret
315895
+
315896
+ will set the password to "reallysecret" (without quotes) for the user to
315897
+ whom the reset token was issued.
315898
+
315899
+ Here is the reset token: @user.reset_token
315900
+
315901
+ Good luck! :)
315902
+ rails-identity
315903
+
315904
+
315905
+ ----==_mimepart_57111772d8b2f_129323fd344c5246444a5
315906
+ Content-Type: text/html;
315907
+ charset=UTF-8
315908
+ Content-Transfer-Encoding: 7bit
315909
+
315910
+ <html>
315911
+ <body>
315912
+ <p>Dear one@example.com,</p>
315913
+
315914
+ <p>You have requested to reset your password. Here are the user UUID and
315915
+ reset token. Make a PATCH request on the UUID with the reset token to set a
315916
+ new password. For instance, <pre>http PATCH /users/current token=eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmZmY0ZDYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Y4RGV1q_thqahwlzvF4zGaMyWDVP_jYjK6XWJA2s3ZY password=reallysecret
315917
+ password_confirmation=reallysecret</pre> will set the password to
315918
+ <pre>reallysecret</pre> for the user to whom the reset token was issued.
315919
+ Here is the reset token:</p>
315920
+
315921
+ <pre>eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGJmZmY0ZDYtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNiwiZXhwIjoxNDYwNzQxNTA2fQ.Y4RGV1q_thqahwlzvF4zGaMyWDVP_jYjK6XWJA2s3ZY</pre>
315922
+
315923
+ <p>Good luck! :)</p>
315924
+ <p><b>rails-identity</b></p>
315925
+
315926
+ </body>
315927
+ </html>
315928
+
315929
+ ----==_mimepart_57111772d8b2f_129323fd344c5246444a5--
315930
+
315931
+ [ActiveJob] [ActionMailer::DeliveryJob] [16ffae69-0b8d-4194-967e-39cf3b014b3f] Performed ActionMailer::DeliveryJob from Inline(mailers) in 9.06ms
315932
+ [ActiveJob] Enqueued ActionMailer::DeliveryJob (Job ID: 16ffae69-0b8d-4194-967e-39cf3b014b3f) to Inline(mailers) with arguments: "RailsIdentity::UserMailer", "password_reset", "deliver_now", gid://dummy/RailsIdentity::User/1
315933
+ Rendered text template (0.0ms)
315934
+ Completed 204 No Content in 17ms (Views: 0.4ms | ActiveRecord: 0.6ms)
315935
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315936
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = '1' LIMIT 1
315937
+ Processing by RailsIdentity::UsersController#update as HTML
315938
+ Parameters: {"username"=>"foo@example.com", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
315939
+ Accepts a token
315940
+ Token well formatted for user 1,
315941
+ session 1
315942
+ Cache miss. Try database.
315943
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315944
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315945
+ Token well formatted and verified. Set cache.
315946
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315947
+ Attempting to get RailsIdentity::User 1
315948
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315949
+ Checking to see if authorized to access object
315950
+ Unpermitted parameters: token, id
315951
+  (0.0ms) SAVEPOINT active_record_1
315952
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
315953
+ SQL (0.2ms) UPDATE "rails_identity_users" SET "username" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["username", "foo@example.com"], ["updated_at", "2016-04-15 16:31:46.946350"], ["uuid", "1"]]
315954
+  (0.0ms) RELEASE SAVEPOINT active_record_1
315955
+ Completed 200 OK in 50ms (Views: 0.4ms | ActiveRecord: 1.2ms)
315956
+  (0.9ms) rollback transaction
315957
+  (0.0ms) begin transaction
315958
+ ------------------------------------------------------------------
315959
+ RailsIdentity::UsersControllerTest: test_admin_can_show_other_user
315960
+ ------------------------------------------------------------------
315961
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315962
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
315963
+ Processing by RailsIdentity::UsersController#show as HTML
315964
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzg4MzA1fQ.AHk7rkxYSQg_zGjx1B2puIZtrxRkHmgFTaF68DsUfpI", "id"=>"1"}
315965
+ Requires a token
315966
+ Token well formatted for user admin_one,
315967
+ session session_admin_one
315968
+ Cache miss. Try database.
315969
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
315970
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
315971
+ Token well formatted and verified. Set cache.
315972
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
315973
+ Attempting to get RailsIdentity::User 1
315974
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315975
+ Checking to see if authorized to access object
315976
+ Completed 200 OK in 6ms (Views: 0.6ms | ActiveRecord: 0.2ms)
315977
+  (0.1ms) rollback transaction
315978
+  (0.0ms) begin transaction
315979
+ ---------------------------------------------------------------------------
315980
+ RailsIdentity::UsersControllerTest: test_cannot_show_using_no_token_payload
315981
+ ---------------------------------------------------------------------------
315982
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315983
+ Processing by RailsIdentity::UsersController#show as HTML
315984
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.e30.wxiScXdB5HuOI5okzRCDmFOqKD2AGXnRfTfYJmDjoOQ", "id"=>"1"}
315985
+ Requires a token
315986
+ User UUID or session UUID is nil
315987
+ Invalid token payload content: eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.e30.wxiScXdB5HuOI5okzRCDmFOqKD2AGXnRfTfYJmDjoOQ
315988
+ Completed 401 Unauthorized in 1ms (Views: 0.2ms | ActiveRecord: 0.0ms)
315989
+  (0.1ms) rollback transaction
315990
+  (0.0ms) begin transaction
315991
+ ------------------------------------------------------------
315992
+ RailsIdentity::UsersControllerTest: test_show_a_current_user
315993
+ ------------------------------------------------------------
315994
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
315995
+ Processing by RailsIdentity::UsersController#show as HTML
315996
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"current"}
315997
+ Requires a token
315998
+ Token well formatted for user 1,
315999
+ session 1
316000
+ Cache miss. Try database.
316001
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316002
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316003
+ Token well formatted and verified. Set cache.
316004
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316005
+ Attempting to get RailsIdentity::User 1
316006
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316007
+ Checking to see if authorized to access object
316008
+ Completed 200 OK in 5ms (Views: 0.5ms | ActiveRecord: 0.2ms)
316009
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316010
+  (0.1ms) rollback transaction
316011
+  (0.0ms) begin transaction
316012
+ ------------------------------------------------------------------------------
316013
+ RailsIdentity::UsersControllerTest: test_cannot_create_a_user_without_username
316014
+ ------------------------------------------------------------------------------
316015
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316016
+ Processing by RailsIdentity::UsersController#create as HTML
316017
+ Parameters: {"password"=>"[FILTERED]", "password_confirmation"=>"[FILTERED]"}
316018
+ Accepts a token
316019
+ Token decode error: Nil JSON web token
316020
+ Suppressing error: Invalid token:
316021
+  (0.1ms) SAVEPOINT active_record_1
316022
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" IS NULL AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316023
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
316024
+ Completed 400 Bad Request in 6ms (Views: 0.2ms | ActiveRecord: 0.2ms)
316025
+  (0.0ms) rollback transaction
316026
+  (0.0ms) begin transaction
316027
+ ------------------------------------------------------------------------------------------------------------
316028
+ RailsIdentity::UsersControllerTest: test_cannot_update_(reissue)_a_verification_reset_token_without_username
316029
+ ------------------------------------------------------------------------------------------------------------
316030
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316031
+ Processing by RailsIdentity::UsersController#update as HTML
316032
+ Parameters: {"issue_verification_token"=>true, "id"=>"current"}
316033
+ Accepts a token
316034
+ Token decode error: Nil JSON web token
316035
+ Suppressing error: Invalid token:
316036
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" IS NULL LIMIT 1
316037
+ RailsIdentity::Errors::ObjectNotFoundError
316038
+ Completed 404 Not Found in 1ms (Views: 0.2ms | ActiveRecord: 0.1ms)
316039
+  (0.0ms) rollback transaction
316040
+  (0.0ms) begin transaction
316041
+ ------------------------------------------------------------
316042
+ RailsIdentity::UsersControllerTest: test_update_current_user
316043
+ ------------------------------------------------------------
316044
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316045
+ Processing by RailsIdentity::UsersController#update as HTML
316046
+ Parameters: {"username"=>"foo@example.com", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"current"}
316047
+ Accepts a token
316048
+ Token well formatted for user 1,
316049
+ session 1
316050
+ Cache miss. Try database.
316051
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316052
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316053
+ Token well formatted and verified. Set cache.
316054
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316055
+ Attempting to get RailsIdentity::User 1
316056
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316057
+ Checking to see if authorized to access object
316058
+ Unpermitted parameters: token, id
316059
+  (0.0ms) SAVEPOINT active_record_1
316060
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
316061
+ SQL (0.1ms) UPDATE "rails_identity_users" SET "username" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["username", "foo@example.com"], ["updated_at", "2016-04-15 16:31:46.999149"], ["uuid", "1"]]
316062
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316063
+ Completed 200 OK in 7ms (Views: 0.4ms | ActiveRecord: 0.5ms)
316064
+  (0.4ms) rollback transaction
316065
+  (0.0ms) begin transaction
316066
+ ------------------------------------------------------------------------------------------------------
316067
+ RailsIdentity::UsersControllerTest: test_cannot_update_(issue)_a_new_reset_token_with_invalid_username
316068
+ ------------------------------------------------------------------------------------------------------
316069
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316070
+ Processing by RailsIdentity::UsersController#update as HTML
316071
+ Parameters: {"issue_reset_token"=>true, "username"=>"doesnotexist@example.com", "id"=>"current"}
316072
+ Accepts a token
316073
+ Token decode error: Nil JSON web token
316074
+ Suppressing error: Invalid token:
316075
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "doesnotexist@example.com"]]
316076
+ RailsIdentity::Errors::ObjectNotFoundError
316077
+ Completed 404 Not Found in 1ms (Views: 0.2ms | ActiveRecord: 0.1ms)
316078
+  (0.1ms) rollback transaction
316079
+  (0.0ms) begin transaction
316080
+ --------------------------------------------------------------------
316081
+ RailsIdentity::UsersControllerTest: test_cannot_update_invalid_email
316082
+ --------------------------------------------------------------------
316083
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316084
+ Processing by RailsIdentity::UsersController#update as HTML
316085
+ Parameters: {"username"=>"foobar", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
316086
+ Accepts a token
316087
+ Token well formatted for user 1,
316088
+ session 1
316089
+ Cache miss. Try database.
316090
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316091
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316092
+ Token well formatted and verified. Set cache.
316093
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316094
+ Attempting to get RailsIdentity::User 1
316095
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316096
+ Checking to see if authorized to access object
316097
+ Unpermitted parameters: token, id
316098
+  (0.1ms) SAVEPOINT active_record_1
316099
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foobar' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
316100
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
316101
+ Completed 400 Bad Request in 7ms (Views: 0.2ms | ActiveRecord: 0.4ms)
316102
+  (0.0ms) rollback transaction
316103
+  (0.0ms) begin transaction
316104
+ ---------------------------------------------------------------------
316105
+ RailsIdentity::SessionTest: test_cannot_save_a_session_without_a_user
316106
+ ---------------------------------------------------------------------
316107
+  (0.0ms) rollback transaction
316108
+  (0.0ms) begin transaction
316109
+ -----------------------------------------------
316110
+ RailsIdentity::SessionTest: test_save_a_session
316111
+ -----------------------------------------------
316112
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316113
+  (0.0ms) SAVEPOINT active_record_1
316114
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "8c159674-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "9898ddca-812e-479d-ae81-39daba51b085"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGMxNTk2NzQtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYxOTQ3NTA3fQ.m-0Yz4ykB1c6yIJR7P2Q5Qz8L3Y5HX8LtGjdMI34QFM"], ["created_at", "2016-04-15 16:31:47.021835"], ["updated_at", "2016-04-15 16:31:47.021835"]]
316115
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316116
+  (0.4ms) rollback transaction
316117
+  (0.1ms) begin transaction
316118
+ --------------------------------------------------------------------------
316119
+ RailsIdentity::SessionTest: test_session_has_token_and_secret_when_created
316120
+ --------------------------------------------------------------------------
316121
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316122
+  (0.0ms) rollback transaction
316123
+  (0.0ms) begin transaction
316124
+ ----------------------------------------------------------
316125
+ RailsIdentity::UserTest: test_user_can_issue_a_reset_token
316126
+ ----------------------------------------------------------
316127
+  (0.0ms) SAVEPOINT active_record_1
316128
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316129
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$lPl6svojS.LfaQ6RtrlMs.955Hte1y5BkIZT/oSU1tCuyCeLv/gr."], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhjMTZhZDY2LTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYwNzQxNTA3fQ.lqPOmz-HuVkLsDB6sw2_WSWaoWff7ttCOkvZrxJRppw"], ["role", 10], ["created_at", "2016-04-15 16:31:47.029612"], ["updated_at", "2016-04-15 16:31:47.029612"], ["uuid", "8c16e5a6-0327-11e6-ba3a-6c4008a6fa2a"]]
316130
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316131
+  (0.0ms) SAVEPOINT active_record_1
316132
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "8c16e5a6-0327-11e6-ba3a-6c4008a6fa2a"], ["uuid", "8c171558-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "a059746c-4760-4b48-a22f-27a42161ad35"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiI4YzE2ZTVhNi0wMzI3LTExZTYtYmEzYS02YzQwMDhhNmZhMmEiLCJzZXNzaW9uX3V1aWQiOiI4YzE3MTU1OC0wMzI3LTExZTYtYmEzYS02YzQwMDhhNmZhMmEiLCJyb2xlIjoxMCwiaWF0IjoxNDYwNzM3OTA3LCJleHAiOjE0NjA3NDE1MDd9.uQr07L0Ugr_yY2qmB1Uqmj5XLviOBQBEwkUrNdJkJQE"], ["created_at", "2016-04-15 16:31:47.031597"], ["updated_at", "2016-04-15 16:31:47.031597"]]
316133
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316134
+  (0.6ms) rollback transaction
316135
+  (0.0ms) begin transaction
316136
+ --------------------------------------------------------------------------
316137
+ RailsIdentity::UserTest: test_user_is_not_valid_if_username_already_exists
316138
+ --------------------------------------------------------------------------
316139
+  (0.0ms) SAVEPOINT active_record_1
316140
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316141
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
316142
+  (0.0ms) rollback transaction
316143
+  (0.0ms) begin transaction
316144
+ ----------------------------------------------------------------------
316145
+ RailsIdentity::UserTest: test_user_is_valid_with_username_and_password
316146
+ ----------------------------------------------------------------------
316147
+  (0.1ms) SAVEPOINT active_record_1
316148
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316149
+ SQL (0.3ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$1wriNDtIEnOGqtWoCjGhC.S2Kv4Cgy6HbjttlBB2g.nMrjdMWTwi2"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhjMTg1NzkyLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYwNzQxNTA3fQ.fiZ-6ETQNQzW6K8YMH_0N0UJvxuEIa7QcPRNo7Lepzk"], ["role", 10], ["created_at", "2016-04-15 16:31:47.040732"], ["updated_at", "2016-04-15 16:31:47.040732"], ["uuid", "8c189856-0327-11e6-ba3a-6c4008a6fa2a"]]
316150
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316151
+  (0.4ms) rollback transaction
316152
+  (0.0ms) begin transaction
316153
+ ---------------------------------------------------------------------------
316154
+ RailsIdentity::UserTest: test_user_is_not_valid_if_username_is_malformatted
316155
+ ---------------------------------------------------------------------------
316156
+  (0.0ms) SAVEPOINT active_record_1
316157
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316158
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
316159
+  (0.0ms) rollback transaction
316160
+  (0.0ms) begin transaction
316161
+ -----------------------------------------------------------------
316162
+ RailsIdentity::UserTest: test_user_can_issue_a_verification_token
316163
+ -----------------------------------------------------------------
316164
+  (0.0ms) SAVEPOINT active_record_1
316165
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316166
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "foo@example.com"], ["password_digest", "$2a$04$ipHF1bAzyPiw5cT33Yq8VuS8KwVIQcYcgXKMZB0KwWtP0A3hfYDVq"], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhjMTliOTJhLTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYwNzQxNTA3fQ.L43XgTqsnw3cFRvZFeHEg0-USCAmLJ0ZN68oauCbLYc"], ["role", 10], ["created_at", "2016-04-15 16:31:47.049338"], ["updated_at", "2016-04-15 16:31:47.049338"], ["uuid", "8c19e77e-0327-11e6-ba3a-6c4008a6fa2a"]]
316167
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316168
+  (0.0ms) SAVEPOINT active_record_1
316169
+ SQL (0.3ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "8c19e77e-0327-11e6-ba3a-6c4008a6fa2a"], ["uuid", "8c1a10a0-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "9846c8c4-1edc-4afe-867d-4076498d81ed"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiI4YzE5ZTc3ZS0wMzI3LTExZTYtYmEzYS02YzQwMDhhNmZhMmEiLCJzZXNzaW9uX3V1aWQiOiI4YzFhMTBhMC0wMzI3LTExZTYtYmEzYS02YzQwMDhhNmZhMmEiLCJyb2xlIjoxMCwiaWF0IjoxNDYwNzM3OTA3LCJleHAiOjE0NjA3NDE1MDd9.etvgUomDLGp0sXEXMujlDh1JiK6kG-wducF8q0HdwLQ"], ["created_at", "2016-04-15 16:31:47.051100"], ["updated_at", "2016-04-15 16:31:47.051100"]]
316170
+  (0.1ms) RELEASE SAVEPOINT active_record_1
316171
+  (0.5ms) rollback transaction
316172
+  (0.0ms) begin transaction
316173
+ ------------------------------------------------------------------
316174
+ RailsIdentity::UserTest: test_user_is_not_valid_without_a_password
316175
+ ------------------------------------------------------------------
316176
+  (0.0ms) SAVEPOINT active_record_1
316177
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'foo@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316178
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
316179
+  (0.0ms) rollback transaction
316180
+  (0.0ms) begin transaction
316181
+ ---------------------------------------------------------------
316182
+ RailsIdentity::UserTest: test_user_has_a_role_of_100_by_default
316183
+ ---------------------------------------------------------------
316184
+  (0.0ms) SAVEPOINT active_record_1
316185
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'new@example.com' AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316186
+ SQL (0.2ms) INSERT INTO "rails_identity_users" ("username", "password_digest", "verification_token", "role", "created_at", "updated_at", "uuid") VALUES (?, ?, ?, ?, ?, ?, ?) [["username", "new@example.com"], ["password_digest", "$2a$04$a2Fxp8RAWfyCPXF3yAvD1ubmmmDNx46krk.9CNSm1iw13dWW.16a."], ["verification_token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOm51bGwsInNlc3Npb25fdXVpZCI6IjhjMWIzNWQ0LTAzMjctMTFlNi1iYTNhLTZjNDAwOGE2ZmEyYSIsInJvbGUiOm51bGwsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYwNzQxNTA3fQ.p1LXP5kxyuxrtfa9Q5D46LRfjNHAzpIYUvouzb2J_UU"], ["role", 10], ["created_at", "2016-04-15 16:31:47.059487"], ["updated_at", "2016-04-15 16:31:47.059487"], ["uuid", "8c1b7616-0327-11e6-ba3a-6c4008a6fa2a"]]
316187
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316188
+  (0.4ms) rollback transaction
316189
+  (0.1ms) begin transaction
316190
+ ------------------------------------------------------------------
316191
+ RailsIdentity::UserTest: test_user_is_not_valid_without_a_username
316192
+ ------------------------------------------------------------------
316193
+  (0.0ms) SAVEPOINT active_record_1
316194
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" IS NULL AND "rails_identity_users"."deleted_at" IS NULL) LIMIT 1
316195
+  (0.0ms) ROLLBACK TO SAVEPOINT active_record_1
316196
+  (0.0ms) rollback transaction
316197
+  (0.0ms) begin transaction
316198
+ ---------------------------------------------------------------------------------------------------
316199
+ RailsIdentity::SessionsControllerTest: test_user_can_list_all_his_sessions_using_user_id_in_routing
316200
+ ---------------------------------------------------------------------------------------------------
316201
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316202
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316203
+ Processing by RailsIdentity::SessionsController#index as HTML
316204
+ Parameters: {"user_id"=>"1", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM"}
316205
+ Requires a token
316206
+ Token well formatted for user 1,
316207
+ session 1
316208
+ Cache miss. Try database.
316209
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316210
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316211
+ Token well formatted and verified. Set cache.
316212
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316213
+ Attempting to get user 1
316214
+ Attempting to get RailsIdentity::User 1
316215
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316216
+ Checking to see if authorized to access object
316217
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."user_uuid" = '1'
316218
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [b5159c0e-112d-4986-94c9-be96de25586d] Performing RailsIdentity::SessionsCleanupJob from Inline(default)
316219
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [b5159c0e-112d-4986-94c9-be96de25586d] Performed RailsIdentity::SessionsCleanupJob from Inline(default) in 0.06ms
316220
+ [ActiveJob] Enqueued RailsIdentity::SessionsCleanupJob (Job ID: b5159c0e-112d-4986-94c9-be96de25586d) to Inline(default)
316221
+ Completed 200 OK in 7ms (Views: 0.5ms | ActiveRecord: 0.2ms)
316222
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."user_uuid" = '1'
316223
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316224
+  (0.0ms) rollback transaction
316225
+  (0.0ms) begin transaction
316226
+ -----------------------------------------------------------------------
316227
+ RailsIdentity::SessionsControllerTest: test_public_cannot_list_sessions
316228
+ -----------------------------------------------------------------------
316229
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316230
+ Processing by RailsIdentity::SessionsController#index as HTML
316231
+ Requires a token
316232
+ Token decode error: Nil JSON web token
316233
+ Invalid token:
316234
+ Completed 401 Unauthorized in 0ms (Views: 0.1ms | ActiveRecord: 0.0ms)
316235
+  (0.1ms) rollback transaction
316236
+  (0.0ms) begin transaction
316237
+ -----------------------------------------------------------------------------
316238
+ RailsIdentity::SessionsControllerTest: test_cannot_show_a_nonexisting_session
316239
+ -----------------------------------------------------------------------------
316240
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316241
+ Processing by RailsIdentity::SessionsController#show as HTML
316242
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"999"}
316243
+ Requires a token
316244
+ Token well formatted for user 1,
316245
+ session 1
316246
+ Cache miss. Try database.
316247
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316248
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316249
+ Token well formatted and verified. Set cache.
316250
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316251
+ Attempting to get RailsIdentity::Session 999
316252
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "999"]]
316253
+ RailsIdentity::Session 999 cannot be found
316254
+ Completed 404 Not Found in 4ms (Views: 0.2ms | ActiveRecord: 0.2ms)
316255
+  (0.1ms) rollback transaction
316256
+  (0.0ms) begin transaction
316257
+ -------------------------------------------------------------------------
316258
+ RailsIdentity::SessionsControllerTest: test_cannot_delete_other's_session
316259
+ -------------------------------------------------------------------------
316260
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316261
+ Processing by RailsIdentity::SessionsController#destroy as HTML
316262
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"2"}
316263
+ Requires a token
316264
+ Token well formatted for user 1,
316265
+ session 1
316266
+ Cache miss. Try database.
316267
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316268
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316269
+ Token well formatted and verified. Set cache.
316270
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316271
+ Attempting to get RailsIdentity::Session 2
316272
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "2"]]
316273
+ Checking to see if authorized to access object
316274
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "2"]]
316275
+ RailsIdentity::Errors::UnauthorizedError
316276
+ Completed 401 Unauthorized in 5ms (Views: 0.2ms | ActiveRecord: 0.2ms)
316277
+  (0.1ms) rollback transaction
316278
+  (0.0ms) begin transaction
316279
+ ----------------------------------------------------------------------------------------------
316280
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_with_non-existent_username
316281
+ ----------------------------------------------------------------------------------------------
316282
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316283
+ Processing by RailsIdentity::SessionsController#create as HTML
316284
+ Parameters: {"username"=>"idontexist", "password"=>"[FILTERED]"}
316285
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "idontexist"]]
316286
+ Attempting to get user
316287
+ Completed 401 Unauthorized in 1ms (Views: 0.2ms | ActiveRecord: 0.1ms)
316288
+  (0.1ms) rollback transaction
316289
+  (0.0ms) begin transaction
316290
+ -----------------------------------------------------------------------
316291
+ RailsIdentity::SessionsControllerTest: test_cannot_show_expired_session
316292
+ -----------------------------------------------------------------------
316293
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316294
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316295
+  (0.0ms) SAVEPOINT active_record_1
316296
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "8c233fc2-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "71beaa6a-963a-4ea8-8261-45830f0c03ea"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGMyMzNmYzItMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYwNzM3OTA2fQ.QizJsfjC155sFGG6o07nnHBW6Ynopcpmyl8bKDhCpfw"], ["created_at", "2016-04-15 16:31:47.111425"], ["updated_at", "2016-04-15 16:31:47.111425"]]
316297
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316298
+ Processing by RailsIdentity::SessionsController#show as HTML
316299
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"8c233fc2-0327-11e6-ba3a-6c4008a6fa2a"}
316300
+ Requires a token
316301
+ Token well formatted for user 1,
316302
+ session 1
316303
+ Cache miss. Try database.
316304
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316305
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316306
+ Token well formatted and verified. Set cache.
316307
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316308
+ Attempting to get RailsIdentity::Session 8c233fc2-0327-11e6-ba3a-6c4008a6fa2a
316309
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "8c233fc2-0327-11e6-ba3a-6c4008a6fa2a"]]
316310
+ Checking to see if authorized to access object
316311
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316312
+  (0.0ms) SAVEPOINT active_record_1
316313
+ SQL (0.2ms) DELETE FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? [["uuid", "8c233fc2-0327-11e6-ba3a-6c4008a6fa2a"]]
316314
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316315
+ RailsIdentity::Errors::ObjectNotFoundError
316316
+ Completed 404 Not Found in 6ms (Views: 0.2ms | ActiveRecord: 0.5ms)
316317
+  (0.6ms) rollback transaction
316318
+  (0.0ms) begin transaction
316319
+ -----------------------------------------------------------------------------------------
316320
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_with_a_wrong_password
316321
+ -----------------------------------------------------------------------------------------
316322
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316323
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316324
+ Processing by RailsIdentity::SessionsController#create as HTML
316325
+ Parameters: {"username"=>"one@example.com", "password"=>"[FILTERED]"}
316326
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "one@example.com"]]
316327
+ Attempting to get user
316328
+ Completed 401 Unauthorized in 66ms (Views: 0.3ms | ActiveRecord: 0.1ms)
316329
+  (0.1ms) rollback transaction
316330
+  (0.0ms) begin transaction
316331
+ ------------------------------------------------------------------
316332
+ RailsIdentity::SessionsControllerTest: test_show_a_current_session
316333
+ ------------------------------------------------------------------
316334
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316335
+ Processing by RailsIdentity::SessionsController#show as HTML
316336
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"current"}
316337
+ Requires a token
316338
+ Token well formatted for user 1,
316339
+ session 1
316340
+ Cache miss. Try database.
316341
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316342
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316343
+ Token well formatted and verified. Set cache.
316344
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316345
+ Attempting to get RailsIdentity::Session 1
316346
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316347
+ Checking to see if authorized to access object
316348
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316349
+ Completed 200 OK in 5ms (Views: 0.5ms | ActiveRecord: 0.2ms)
316350
+  (0.1ms) rollback transaction
316351
+  (0.0ms) begin transaction
316352
+ ----------------------------------------------------------
316353
+ RailsIdentity::SessionsControllerTest: test_show_a_session
316354
+ ----------------------------------------------------------
316355
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316356
+ Processing by RailsIdentity::SessionsController#show as HTML
316357
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
316358
+ Requires a token
316359
+ Token well formatted for user 1,
316360
+ session 1
316361
+ Cache miss. Try database.
316362
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316363
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316364
+ Token well formatted and verified. Set cache.
316365
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316366
+ Attempting to get RailsIdentity::Session 1
316367
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316368
+ Checking to see if authorized to access object
316369
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316370
+ Completed 200 OK in 5ms (Views: 0.5ms | ActiveRecord: 0.2ms)
316371
+  (0.1ms) rollback transaction
316372
+  (0.0ms) begin transaction
316373
+ ------------------------------------------------------------------
316374
+ RailsIdentity::SessionsControllerTest: test_public_can_see_options
316375
+ ------------------------------------------------------------------
316376
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316377
+ Processing by RailsIdentity::SessionsController#options as HTML
316378
+ Rendered text template (0.0ms)
316379
+ Completed 200 OK in 1ms (Views: 1.1ms | ActiveRecord: 0.0ms)
316380
+  (0.1ms) rollback transaction
316381
+  (0.0ms) begin transaction
316382
+ ----------------------------------------------------------------------------
316383
+ RailsIdentity::SessionsControllerTest: test_user_cannot_list_expired_session
316384
+ ----------------------------------------------------------------------------
316385
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316386
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316387
+  (0.0ms) SAVEPOINT active_record_1
316388
+ SQL (0.2ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "8c33c34c-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "7fd210c3-350e-4f09-9de1-dc75c7491986"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGMzM2MzNGMtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYwNzM3OTA2fQ.uh26vII2vATOmE71_Oj0yyzhkFvlS-RY4cJI2tZAj5U"], ["created_at", "2016-04-15 16:31:47.219655"], ["updated_at", "2016-04-15 16:31:47.219655"]]
316389
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316390
+ Processing by RailsIdentity::SessionsController#index as HTML
316391
+ Parameters: {"user_id"=>"1", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM"}
316392
+ Requires a token
316393
+ Token well formatted for user 1,
316394
+ session 1
316395
+ Cache miss. Try database.
316396
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316397
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316398
+ Token well formatted and verified. Set cache.
316399
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316400
+ Attempting to get user 1
316401
+ Attempting to get RailsIdentity::User 1
316402
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316403
+ Checking to see if authorized to access object
316404
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."user_uuid" = '1'
316405
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [c7ceced9-864d-463c-b1bb-8eb04488ec7b] Performing RailsIdentity::SessionsCleanupJob from Inline(default) with arguments: "8c33c34c-0327-11e6-ba3a-6c4008a6fa2a"
316406
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [c7ceced9-864d-463c-b1bb-8eb04488ec7b] RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "8c33c34c-0327-11e6-ba3a-6c4008a6fa2a"]]
316407
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [c7ceced9-864d-463c-b1bb-8eb04488ec7b]  (0.0ms) SAVEPOINT active_record_1
316408
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [c7ceced9-864d-463c-b1bb-8eb04488ec7b] SQL (0.3ms) DELETE FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? [["uuid", "8c33c34c-0327-11e6-ba3a-6c4008a6fa2a"]]
316409
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [c7ceced9-864d-463c-b1bb-8eb04488ec7b]  (0.0ms) RELEASE SAVEPOINT active_record_1
316410
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [c7ceced9-864d-463c-b1bb-8eb04488ec7b] Performed RailsIdentity::SessionsCleanupJob from Inline(default) in 1.16ms
316411
+ [ActiveJob] Enqueued RailsIdentity::SessionsCleanupJob (Job ID: c7ceced9-864d-463c-b1bb-8eb04488ec7b) to Inline(default) with arguments: "8c33c34c-0327-11e6-ba3a-6c4008a6fa2a"
316412
+ Completed 200 OK in 8ms (Views: 0.5ms | ActiveRecord: 0.7ms)
316413
+  (0.6ms) rollback transaction
316414
+  (0.0ms) begin transaction
316415
+ ------------------------------------------------------------------------------------
316416
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_without_username
316417
+ ------------------------------------------------------------------------------------
316418
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316419
+ Processing by RailsIdentity::SessionsController#create as HTML
316420
+ Parameters: {"password"=>"[FILTERED]"}
316421
+ RailsIdentity::User Load (0.2ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" IS NULL LIMIT 1
316422
+ Attempting to get user
316423
+ Completed 401 Unauthorized in 2ms (Views: 0.2ms | ActiveRecord: 0.2ms)
316424
+  (0.1ms) rollback transaction
316425
+  (0.0ms) begin transaction
316426
+ -------------------------------------------------------------------------
316427
+ RailsIdentity::SessionsControllerTest: test_public_cannot_create_sessions
316428
+ -------------------------------------------------------------------------
316429
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316430
+ Processing by RailsIdentity::SessionsController#index as HTML
316431
+ Requires a token
316432
+ Token decode error: Nil JSON web token
316433
+ Invalid token:
316434
+ Completed 401 Unauthorized in 0ms (Views: 0.2ms | ActiveRecord: 0.0ms)
316435
+  (0.1ms) rollback transaction
316436
+  (0.0ms) begin transaction
316437
+ --------------------------------------------------------------------------
316438
+ RailsIdentity::SessionsControllerTest: test_admin_can_show_other's_session
316439
+ --------------------------------------------------------------------------
316440
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316441
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
316442
+ Processing by RailsIdentity::SessionsController#show as HTML
316443
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzg4MzA1fQ.AHk7rkxYSQg_zGjx1B2puIZtrxRkHmgFTaF68DsUfpI", "id"=>"1"}
316444
+ Requires a token
316445
+ Token well formatted for user admin_one,
316446
+ session session_admin_one
316447
+ Cache miss. Try database.
316448
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
316449
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
316450
+ Token well formatted and verified. Set cache.
316451
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
316452
+ Attempting to get RailsIdentity::Session 1
316453
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316454
+ Checking to see if authorized to access object
316455
+ Completed 200 OK in 4ms (Views: 0.4ms | ActiveRecord: 0.1ms)
316456
+  (0.1ms) rollback transaction
316457
+  (0.0ms) begin transaction
316458
+ -----------------------------------------------------------------------------
316459
+ RailsIdentity::SessionsControllerTest: test_user_cannot_list_other's_sessions
316460
+ -----------------------------------------------------------------------------
316461
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316462
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "2"]]
316463
+ Processing by RailsIdentity::SessionsController#index as HTML
316464
+ Parameters: {"user_id"=>"2", "token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM"}
316465
+ Requires a token
316466
+ Token well formatted for user 1,
316467
+ session 1
316468
+ Cache miss. Try database.
316469
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316470
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316471
+ Token well formatted and verified. Set cache.
316472
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316473
+ Attempting to get user 2
316474
+ Attempting to get RailsIdentity::User 2
316475
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "2"]]
316476
+ Checking to see if authorized to access object
316477
+ Not authorized to access user 2
316478
+ Completed 401 Unauthorized in 4ms (Views: 0.1ms | ActiveRecord: 0.2ms)
316479
+  (0.4ms) rollback transaction
316480
+  (0.1ms) begin transaction
316481
+ --------------------------------------------------------------------
316482
+ RailsIdentity::SessionsControllerTest: test_delete_a_current_session
316483
+ --------------------------------------------------------------------
316484
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316485
+ Processing by RailsIdentity::SessionsController#destroy as HTML
316486
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"current"}
316487
+ Requires a token
316488
+ Token well formatted for user 1,
316489
+ session 1
316490
+ Cache miss. Try database.
316491
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316492
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316493
+ Token well formatted and verified. Set cache.
316494
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316495
+ Attempting to get RailsIdentity::Session 1
316496
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316497
+ Checking to see if authorized to access object
316498
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316499
+  (0.1ms) SAVEPOINT active_record_1
316500
+ SQL (0.2ms) DELETE FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? [["uuid", "1"]]
316501
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316502
+ Rendered text template (0.0ms)
316503
+ Completed 204 No Content in 7ms (Views: 0.5ms | ActiveRecord: 0.5ms)
316504
+  (0.4ms) rollback transaction
316505
+  (0.0ms) begin transaction
316506
+ --------------------------------------------------------------------------------
316507
+ RailsIdentity::SessionsControllerTest: test_cannot_delete_a_non-existent_session
316508
+ --------------------------------------------------------------------------------
316509
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316510
+ Processing by RailsIdentity::SessionsController#destroy as HTML
316511
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"999"}
316512
+ Requires a token
316513
+ Token well formatted for user 1,
316514
+ session 1
316515
+ Cache miss. Try database.
316516
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316517
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316518
+ Token well formatted and verified. Set cache.
316519
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316520
+ Attempting to get RailsIdentity::Session 999
316521
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "999"]]
316522
+ RailsIdentity::Session 999 cannot be found
316523
+ Completed 404 Not Found in 4ms (Views: 0.2ms | ActiveRecord: 0.2ms)
316524
+  (0.1ms) rollback transaction
316525
+  (0.1ms) begin transaction
316526
+ ----------------------------------------------------------------------
316527
+ RailsIdentity::SessionsControllerTest: test_public_cannot_show_session
316528
+ ----------------------------------------------------------------------
316529
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316530
+ Processing by RailsIdentity::SessionsController#show as HTML
316531
+ Parameters: {"id"=>"1"}
316532
+ Requires a token
316533
+ Token decode error: Nil JSON web token
316534
+ Invalid token:
316535
+ Completed 401 Unauthorized in 0ms (Views: 0.2ms | ActiveRecord: 0.0ms)
316536
+  (0.1ms) rollback transaction
316537
+  (0.0ms) begin transaction
316538
+ -----------------------------------------------------------------------------------
316539
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_if_not_verified
316540
+ -----------------------------------------------------------------------------------
316541
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316542
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316543
+  (0.0ms) SAVEPOINT active_record_1
316544
+ RailsIdentity::User Exists (0.1ms) SELECT 1 AS one FROM "rails_identity_users" WHERE ("rails_identity_users"."username" = 'one@example.com' AND "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" != '1') LIMIT 1
316545
+ SQL (0.2ms) UPDATE "rails_identity_users" SET "verified" = ?, "updated_at" = ? WHERE "rails_identity_users"."uuid" = ? [["verified", "f"], ["updated_at", "2016-04-15 16:31:47.331306"], ["uuid", "1"]]
316546
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316547
+ Processing by RailsIdentity::SessionsController#create as HTML
316548
+ Parameters: {"username"=>"one@example.com", "password"=>"[FILTERED]"}
316549
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "one@example.com"]]
316550
+ RailsIdentity::Errors::UnauthorizedError
316551
+ Completed 401 Unauthorized in 77ms (Views: 0.2ms | ActiveRecord: 0.1ms)
316552
+  (1.1ms) rollback transaction
316553
+  (0.1ms) begin transaction
316554
+ ----------------------------------------------------------------------------
316555
+ RailsIdentity::SessionsControllerTest: test_admin_can_delete_other's_session
316556
+ ----------------------------------------------------------------------------
316557
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316558
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
316559
+ Processing by RailsIdentity::SessionsController#destroy as HTML
316560
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiJzZXNzaW9uX2FkbWluX29uZSIsInVzZXJfdXVpZCI6ImFkbWluX29uZSIsInJvbGUiOjEwMCwiZXhwIjoxNDYwNzg4MzA1fQ.AHk7rkxYSQg_zGjx1B2puIZtrxRkHmgFTaF68DsUfpI", "id"=>"1"}
316561
+ Requires a token
316562
+ Token well formatted for user admin_one,
316563
+ session session_admin_one
316564
+ Cache miss. Try database.
316565
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
316566
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "session_admin_one"]]
316567
+ Token well formatted and verified. Set cache.
316568
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "admin_one"]]
316569
+ Attempting to get RailsIdentity::Session 1
316570
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316571
+ Checking to see if authorized to access object
316572
+  (0.1ms) SAVEPOINT active_record_1
316573
+ SQL (0.1ms) DELETE FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? [["uuid", "1"]]
316574
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316575
+ Rendered text template (0.0ms)
316576
+ Completed 204 No Content in 5ms (Views: 0.4ms | ActiveRecord: 0.4ms)
316577
+  (0.4ms) rollback transaction
316578
+  (0.1ms) begin transaction
316579
+ -----------------------------------------------------------------------
316580
+ RailsIdentity::SessionsControllerTest: test_cannot_show_other's_session
316581
+ -----------------------------------------------------------------------
316582
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316583
+ Processing by RailsIdentity::SessionsController#show as HTML
316584
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"2"}
316585
+ Requires a token
316586
+ Token well formatted for user 1,
316587
+ session 1
316588
+ Cache miss. Try database.
316589
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316590
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316591
+ Token well formatted and verified. Set cache.
316592
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316593
+ Attempting to get RailsIdentity::Session 2
316594
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "2"]]
316595
+ Checking to see if authorized to access object
316596
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "2"]]
316597
+ RailsIdentity::Errors::UnauthorizedError
316598
+ Completed 401 Unauthorized in 5ms (Views: 0.2ms | ActiveRecord: 0.2ms)
316599
+  (0.1ms) rollback transaction
316600
+  (0.0ms) begin transaction
316601
+ --------------------------------------------------------------------------------------
316602
+ RailsIdentity::SessionsControllerTest: test_cannot_create_a_session_without_a_password
316603
+ --------------------------------------------------------------------------------------
316604
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316605
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316606
+ Processing by RailsIdentity::SessionsController#create as HTML
316607
+ Parameters: {"username"=>"one@example.com"}
316608
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "one@example.com"]]
316609
+ Attempting to get user
316610
+ Completed 401 Unauthorized in 68ms (Views: 0.3ms | ActiveRecord: 0.1ms)
316611
+  (0.1ms) rollback transaction
316612
+  (0.0ms) begin transaction
316613
+ --------------------------------------------------------------------------
316614
+ RailsIdentity::SessionsControllerTest: test_user_can_list_all_his_sessions
316615
+ --------------------------------------------------------------------------
316616
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316617
+ Processing by RailsIdentity::SessionsController#index as HTML
316618
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM"}
316619
+ Requires a token
316620
+ Token well formatted for user 1,
316621
+ session 1
316622
+ Cache miss. Try database.
316623
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316624
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316625
+ Token well formatted and verified. Set cache.
316626
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316627
+ Attempting to get user
316628
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."user_uuid" = '1'
316629
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [50470315-c010-40b4-b437-aa9852b7ad6f] Performing RailsIdentity::SessionsCleanupJob from Inline(default)
316630
+ [ActiveJob] [RailsIdentity::SessionsCleanupJob] [50470315-c010-40b4-b437-aa9852b7ad6f] Performed RailsIdentity::SessionsCleanupJob from Inline(default) in 0.05ms
316631
+ [ActiveJob] Enqueued RailsIdentity::SessionsCleanupJob (Job ID: 50470315-c010-40b4-b437-aa9852b7ad6f) to Inline(default)
316632
+ Completed 200 OK in 5ms (Views: 0.4ms | ActiveRecord: 0.2ms)
316633
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316634
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."user_uuid" = '1'
316635
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316636
+  (0.0ms) rollback transaction
316637
+  (0.1ms) begin transaction
316638
+ ------------------------------------------------------------
316639
+ RailsIdentity::SessionsControllerTest: test_delete_a_session
316640
+ ------------------------------------------------------------
316641
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316642
+ Processing by RailsIdentity::SessionsController#destroy as HTML
316643
+ Parameters: {"token"=>"eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJzZXNzaW9uX3V1aWQiOiIxIiwidXNlcl91dWlkIjoiMSIsInJvbGUiOjEwLCJleHAiOjE0NjA3ODgzMDV9.3_aDDoZUIuWjtOhHY1d-STL2FYpn41ZZrC2PNI2PERM", "id"=>"1"}
316644
+ Requires a token
316645
+ Token well formatted for user 1,
316646
+ session 1
316647
+ Cache miss. Try database.
316648
+ RailsIdentity::User Load (0.1ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316649
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316650
+ Token well formatted and verified. Set cache.
316651
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316652
+ Attempting to get RailsIdentity::Session 1
316653
+ RailsIdentity::Session Load (0.0ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316654
+ Checking to see if authorized to access object
316655
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316656
+  (0.1ms) SAVEPOINT active_record_1
316657
+ SQL (0.2ms) DELETE FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? [["uuid", "1"]]
316658
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316659
+ Rendered text template (0.0ms)
316660
+ Completed 204 No Content in 7ms (Views: 0.4ms | ActiveRecord: 0.5ms)
316661
+  (0.3ms) rollback transaction
316662
+  (0.0ms) begin transaction
316663
+ ------------------------------------------------------------
316664
+ RailsIdentity::SessionsControllerTest: test_create_a_session
316665
+ ------------------------------------------------------------
316666
+ RailsIdentity::Session Load (0.1ms) SELECT "rails_identity_sessions".* FROM "rails_identity_sessions" WHERE "rails_identity_sessions"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316667
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."uuid" = ? LIMIT 1 [["uuid", "1"]]
316668
+ Processing by RailsIdentity::SessionsController#create as HTML
316669
+ Parameters: {"username"=>"one@example.com", "password"=>"[FILTERED]"}
316670
+ RailsIdentity::User Load (0.0ms) SELECT "rails_identity_users".* FROM "rails_identity_users" WHERE "rails_identity_users"."deleted_at" IS NULL AND "rails_identity_users"."username" = ? LIMIT 1 [["username", "one@example.com"]]
316671
+  (0.1ms) SAVEPOINT active_record_1
316672
+ SQL (0.3ms) INSERT INTO "rails_identity_sessions" ("user_uuid", "uuid", "secret", "token", "created_at", "updated_at") VALUES (?, ?, ?, ?, ?, ?) [["user_uuid", "1"], ["uuid", "8c6ec9b0-0327-11e6-ba3a-6c4008a6fa2a"], ["secret", "12b6397a-bf5d-48f6-86ba-c591af986f3a"], ["token", "eyJ0eXAiOiJKV1QiLCJhbGciOiJIUzI1NiJ9.eyJ1c2VyX3V1aWQiOiIxIiwic2Vzc2lvbl91dWlkIjoiOGM2ZWM5YjAtMDMyNy0xMWU2LWJhM2EtNmM0MDA4YTZmYTJhIiwicm9sZSI6MTAsImlhdCI6MTQ2MDczNzkwNywiZXhwIjoxNDYxOTQ3NTA3fQ.B-a00KX0fxLleWRqLp07GI6mY_GuTmV2INftCOVYqfI"], ["created_at", "2016-04-15 16:31:47.606785"], ["updated_at", "2016-04-15 16:31:47.606785"]]
316673
+  (0.0ms) RELEASE SAVEPOINT active_record_1
316674
+ Completed 201 Created in 74ms (Views: 0.4ms | ActiveRecord: 0.4ms)
316675
+  (0.4ms) rollback transaction