cloudsponge 0.9.11 → 0.9.12

Sign up to get free protection for your applications and to get access to all the features.
@@ -1,7 +1,7 @@
1
1
  PATH
2
2
  remote: .
3
3
  specs:
4
- cloudsponge (0.9.10)
4
+ cloudsponge (0.9.11)
5
5
  json (>= 1.6.1)
6
6
 
7
7
  GEM
@@ -39,13 +39,14 @@ module Cloudsponge
39
39
  # look at the given service and decide how which begin function to invoke.
40
40
  unless username.nil? || username.empty?
41
41
  resp = begin_import_username_password(source_name, username, password, user_id)
42
+ consent_url = resp['url'] if resp['url']
42
43
  else
43
44
  unless (source_name =~ /OUTLOOK/i || source_name =~ /ADDRESSBOOK/i).nil?
44
45
  resp = begin_import_applet(source_name, user_id)
45
46
  applet_tag = create_applet_tag(resp['id'], resp['url'])
46
47
  else
47
48
  resp = begin_import_consent(source_name, user_id, redirect_url)
48
- consent_url = resp['url']
49
+ consent_url = resp['url'] if resp['url']
49
50
  end
50
51
  end
51
52
 
@@ -1,3 +1,3 @@
1
1
  module Cloudsponge
2
- VERSION = "0.9.11"
2
+ VERSION = "0.9.12"
3
3
  end
@@ -14,6 +14,22 @@ class TestContactImporter < Test::Unit::TestCase
14
14
  contacts = events_wait(importer)
15
15
  assert contacts
16
16
  end
17
+
18
+ def test_aol_import
19
+ importer = Cloudsponge::ContactImporter.new(DOMAIN_KEY, DOMAIN_PASSWORD)
20
+ resp = importer.begin_import('AOL', 'u', 'p')
21
+ puts "Navigate to #{resp[:consent_url]} and complete the authentication process." if resp[:consent_url]
22
+ contacts = events_wait(importer)
23
+ assert contacts
24
+ end
25
+
26
+ def test_wl_import
27
+ importer = Cloudsponge::ContactImporter.new(DOMAIN_KEY, DOMAIN_PASSWORD)
28
+ resp = importer.begin_import('WINDOWSLIVE')
29
+ puts "Navigate to #{resp[:consent_url]} and complete the authentication process." if resp[:consent_url]
30
+ contacts = events_wait(importer)
31
+ assert contacts
32
+ end
17
33
 
18
34
  def test_auth_import
19
35
  importer = Cloudsponge::ContactImporter.new(DOMAIN_KEY, DOMAIN_PASSWORD)
@@ -0,0 +1,2 @@
1
+ require 'test/unit'
2
+ require 'cloudsponge'
metadata CHANGED
@@ -5,8 +5,8 @@ version: !ruby/object:Gem::Version
5
5
  segments:
6
6
  - 0
7
7
  - 9
8
- - 11
9
- version: 0.9.11
8
+ - 12
9
+ version: 0.9.12
10
10
  platform: ruby
11
11
  authors:
12
12
  - Graeme Rouse
@@ -14,7 +14,7 @@ autorequire:
14
14
  bindir: bin
15
15
  cert_chain: []
16
16
 
17
- date: 2013-08-06 00:00:00 -07:00
17
+ date: 2013-08-20 00:00:00 -07:00
18
18
  default_executable:
19
19
  dependencies:
20
20
  - !ruby/object:Gem::Dependency