diff options
author | Pawel Chojnacki <pawel@chojnacki.ws> | 2017-02-17 16:44:57 +0300 |
---|---|---|
committer | Pawel Chojnacki <pawel@chojnacki.ws> | 2017-03-06 17:41:25 +0300 |
commit | 9cc0ff8f468c54e23172492d97f6d9b428d3ad2e (patch) | |
tree | 5de31ec4dea0df354cc246b809dff5ef376316d5 /spec/requests/api/doorkeeper_access_spec.rb | |
parent | 80fbced2e0b8d291173e1002f150bc5551e87359 (diff) |
Cleanup common code in Unique Ips tests
Diffstat (limited to 'spec/requests/api/doorkeeper_access_spec.rb')
-rw-r--r-- | spec/requests/api/doorkeeper_access_spec.rb | 23 |
1 files changed, 0 insertions, 23 deletions
diff --git a/spec/requests/api/doorkeeper_access_spec.rb b/spec/requests/api/doorkeeper_access_spec.rb index b2864f448a8..634b2261c5e 100644 --- a/spec/requests/api/doorkeeper_access_spec.rb +++ b/spec/requests/api/doorkeeper_access_spec.rb @@ -1,28 +1,5 @@ require 'spec_helper' -shared_examples 'user login request with unique ip limit' do - include_context 'limit login to only one ip' do - it 'allows user authenticating from the same ip' do - change_ip('ip') - request - expect(response).to have_http_status(200) - - request - expect(response).to have_http_status(200) - end - - it 'blocks user authenticating from two distinct ips' do - change_ip('ip') - request - expect(response).to have_http_status(200) - - change_ip('ip2') - request - expect(response).to have_http_status(403) - end - end -end - describe API::API, api: true do include ApiHelpers |