54 Commits

Author SHA1 Message Date
Carlos Antonio da Silva
2261005ed5 Refactor a bit to avoid two model attributes lookup
Tidy up tests a bit.
2012-12-04 17:37:12 -02:00
Drew Ulmer
77ec1b08cd Move test models into their own file so they can be used elsewhere 2012-12-01 21:06:03 -06:00
Nils Landt
1d6ee13aae Refactor according to rodrigoflores
- Favor using update_attribute instead of constructor parameters in user
  factory for tests
- Test for accurate error message when confirmation token is expired
- Don't check twice whether the confirmation period is expired
2012-07-16 11:20:01 +02:00
Nils Landt
6e48fcee76 Fix tests for email token expiration
The tests work now, but are a bit wonky because User.create does things
I don't understand.
2012-07-11 18:30:36 +02:00
Nils Landt
87f2fa9767 Add options to expire confirmation tokens
With this patch, functionality is added to expire the confirmation
tokens that are being sent by email.
For example, if a token is valid for 3 days only, it cannot be used for
confirmation on the 4th day.
2012-07-09 14:43:12 +02:00
Carlos Galdino
c179cef365 Change the minimum password length to 8 2012-07-06 11:46:46 -03:00
Chris Oliver
37c55eb192 Added tests for flexible routing constraints 2012-06-15 13:06:29 -05:00
Carlos Antonio da Silva
b6e30427a3 Pass the block argument straight to the assertion methods in test helpers 2012-05-15 17:19:21 -03:00
Rodrigo Flores
fffc3b1e0e Moved a method to support 2012-03-03 14:41:22 -03:00
Lucas Mazza
64c05f2ce9 Fix the assert_same_content assertion helper
and a broken confirmable test.
2012-02-22 16:49:09 -02:00
Rodrigo Flores
bc11e9f300 One exception to rule them all 2012-02-22 13:55:05 -02:00
Rodrigo Flores
faf8b01ecc Fixing some tests and adding an assert message 2012-02-22 13:55:05 -02:00
Rodrigo Flores
d7337c5b26 Added a missing test and asserting same content for 1.8 compatibility 2012-02-22 13:55:05 -02:00
José Valim
7c11564613 Remove Rails 3.0 only code. 2012-01-02 20:43:39 +01:00
José Valim
d952dea32b Remove the code that was dynamically adding columns to active record 2011-12-11 20:07:50 +01:00
José Valim
9a6ac7ab69 Add confirmable to admin. 2011-12-11 20:07:50 +01:00
José Valim
6d681c5b8a Merge remote-tracking branch 'heimidal/updates' into reconfirm
Conflicts:
	lib/devise/models/confirmable.rb
	test/support/helpers.rb
2011-12-04 20:58:41 +01:00
José Valim
dc8aa9ef83 Move param filtering to its own object and make all finder methods pass through it, closes #1413. 2011-11-10 10:14:02 -02:00
Vasiliy Ermolovich
f00d9c5eff generate migrations with new .change method for rails >= 3.1. closes #1345 2011-11-06 15:47:34 +03:00
Brian Rose
a1407565c8 Selectively add reconfirmable field in tests when necessary. 2011-08-30 22:19:18 -06:00
Brian Rose
a7c5a2e65d Fix up implementation of reconfirmable. 2011-08-30 22:19:17 -06:00
SixArm
2a5669967f Change test email addresses to ues RFC 2606 reserved domain example.com 2011-04-18 15:59:13 +08:00
Andrew Dahl
8d1e23c67d add unit and integration tests for case insensitive keys 2010-11-20 15:54:01 +01:00
Carlos Antonio da Silva
ffaba3f1d3 Avoid RAILS_DEFAULT_LOGGER deprecation warning from Webrat
This must be fixed in Webrat.
2010-09-26 14:53:36 -03:00
Carlos Antonio da Silva
f60123ce01 Bump webrat to 0.7.1 2010-09-26 14:45:00 -03:00
Thibaud Guillaume-Gentil
c121d8026e Avoid BCrypt::Errors::InvalidSalt: invalid salt
when password_salt is nil.

Signed-off-by: José Valim <jose.valim@gmail.com>
2010-09-21 12:09:07 +02:00
José Valim
00c6f583e2 More OAuth tests. 2010-07-26 20:33:22 +02:00
José Valim
bd0e2a3180 devise_for now accepts a block. All routes inside the block uses the scope defined by devise_for.
You are now allowed to do:

  devise_for :users do
    # Non conventional sign_in route
    get "/sign_in" => "devise/sessions#new"
  end

And it should work as expected.
2010-07-07 10:51:14 +02:00
José Valim
750560ae87 Ensure method is always POST on new.html.erb forms, closes #365. Also, start to remove usage of assert_template. 2010-07-06 16:01:22 +02:00
José Valim
23e608e27b No need to append ?unauthenticated=true in URLs anymore since Flash was moved to a middleware in Rails 3. 2010-04-03 11:43:31 +02:00
José Valim
2a082f3e4c Fix some unlockable bugs. 2010-03-28 23:09:28 +02:00
José Valim
ea71be8d2a More compatibility with Rails master. 2010-03-28 07:15:52 +02:00
José Valim
28a6be456a Require files before monkey patching them. 2010-03-23 16:28:17 +01:00
José Valim
ac742e3271 Clean up lockable and class methods API. 2010-03-10 16:13:54 +01:00
José Valim
4a0b9c663a Use metal for Devise::FailureApp. \m/ 2010-02-19 09:52:12 +01:00
José Valim
d466849c57 More tests passing for Rails 3 compatibility. 369 tests, 788 assertions, 34 failures, 16 errors. 2010-02-16 16:11:30 +01:00
José Valim
766316b5e7 Got tests running on Rails 3: 369 tests, 486 assertions, 45 failures, 124 errors. 2010-02-16 14:31:49 +01:00
José Valim
1cf4dc798d Add Http Basic Authentication support. 2010-02-06 01:33:32 +01:00
Jonas Grimfelt
e1440fb430 Initial support for authorization using "authentication token" (a.k.a. "single access token") - new module. Corresponding changes to Devise core to hook events like "after_changed_password" (only one added now - only one that makes much sense for latest module) easily. Unit and integration tests included. NOTE: One failing test for hooking Warden::Manager.after_authentication - gets ignored for some reason.
Signed-off-by: José Valim <jose.valim@gmail.com>
2010-02-02 12:36:44 +01:00
Marcelo Silveira
d2fa737aa0 introducing lockable implementation 2010-01-01 17:57:35 -02:00
José Valim
35a8d13369 Tests passing for ActiveRecord and MongoMapper. 2009-12-21 21:10:23 +01:00
José Valim
947de72617 More test files. 2009-12-21 19:57:26 +01:00
José Valim
78303cd5c5 Got another bunch of tests passing with MongoMapper. 2009-12-21 19:57:17 +01:00
José Valim
371a9bb0d0 Major refactoring. Allow Warden::Manager to be configured through Devise, undeprecate Devise.confirm_within, Devise.pepper and friends and move Rails hooks to their own file. 2009-11-03 09:35:11 -02:00
Carlos A. da Silva
9643a5fa6d Removing attr_accessible. 2009-10-22 20:18:16 -02:00
Carlos A. da Silva
0eb8b3b7cc Mailer subjects namespaced by model 2009-10-20 01:28:01 -02:00
Carlos A. da Silva
28a7f78fba Creating rememberable module. 2009-10-20 00:31:33 -02:00
Carlos A. da Silva
a5cb147eb2 Stores the requested page before signing in and redirect the user to the stored uri after. 2009-10-17 11:12:50 -03:00
José Valim
f1cecacc99 Move mappings to routes. 2009-10-12 21:49:51 -03:00
José Valim
b012bc800b Kick tests back to life. 2009-10-11 23:24:57 -03:00