summaryrefslogtreecommitdiff
path: root/test/remote/nicknym_source_test.rb
diff options
context:
space:
mode:
Diffstat (limited to 'test/remote/nicknym_source_test.rb')
-rw-r--r--test/remote/nicknym_source_test.rb15
1 files changed, 13 insertions, 2 deletions
diff --git a/test/remote/nicknym_source_test.rb b/test/remote/nicknym_source_test.rb
index 4ca3033..b97f2b2 100644
--- a/test/remote/nicknym_source_test.rb
+++ b/test/remote/nicknym_source_test.rb
@@ -10,13 +10,24 @@ require 'nickserver/email_address'
class RemoteNicknymSourceTest < CelluloidTest
include HttpAdapterHelper
- def test_availablility_check
+ def test_available_for_mail
source.available_for? 'mail.bitmask.net'
- refute source.available_for? 'dl.bitmask.net' # not a provider
rescue HTTP::ConnectionError => e
skip e.to_s
end
+ # not a provider
+ def test_not_available
+ refute source.available_for? 'dl.bitmask.net'
+ rescue HTTP::ConnectionError => e
+ skip e.to_s
+ end
+
+ # cs.ucl.ac.uk only has an MX not an A-record
+ def test_not_available_without_a_record
+ refute source.available_for? 'cs.ucl.ac.uk'
+ end
+
def test_successful_query
response = source.query(email_with_key)
skip if response.status == 404