finapps 5.0.19 → 5.0.20

Sign up to get free protection for your applications and to get access to all the features.
checksums.yaml CHANGED
@@ -1,7 +1,7 @@
1
1
  ---
2
2
  SHA256:
3
- metadata.gz: a0149d16f03d34730c867cecd5403eafa545a86409873c53486d0de8389d6a24
4
- data.tar.gz: 9e1d672c3b64ef9e403b8fa049ab10757ecdc5dd475e34c7b2547275b8f8d773
3
+ metadata.gz: 1148f9034f5e17b0b9cc457d691fcd97b088e4f6c93b6d90605309355d8593ba
4
+ data.tar.gz: b5cebf9220a9c550850777fec411fbe71bbe4d0d044cb0dd1ab0b0bdee6b38cf
5
5
  SHA512:
6
- metadata.gz: ff86485841923122273e9edd26ce173f852f3de9df705825659f3c72cb10cddd633b0520133a9dcda15ba51df2c5c4abdb6b8ad44dfd50d9a3841ab05966f772
7
- data.tar.gz: 57897eb362e78eb67cad51f8d3d130485006e4d61e01899f13b7fdcfa4e250091a67e1111ae60384c80497dcacd730a0aba20e424394cfc14f04ab1a44dd5580
6
+ metadata.gz: 5f2b36a775aac0b1d140480abb01ef6362db0e9a111ab40a16b228bd16d6a12322ffbba07fd55471591c0c5d263b1331d86ae623b4eb5ca7de8bd31765643cf2
7
+ data.tar.gz: 8a4291a8a37b1c77a8af3c9f8bb35d807b8ca6817f2b2415a6d7223091812d17bef230003ba4292a85fca58ed826ea47938509f06f1b77cec30abd63069f5f8c
data/finapps.gemspec CHANGED
@@ -27,7 +27,7 @@ Gem::Specification.new do |spec|
27
27
  spec.add_development_dependency 'gem-release', '~> 2.0', '>= 2.0.3'
28
28
  spec.add_development_dependency 'guard', '~> 2.15', '>= 2.15.0'
29
29
  spec.add_development_dependency 'guard-rspec', '~> 4.7', '>= 4.7.3'
30
- spec.add_development_dependency 'rake', '~> 12.3', '>= 12.3.2'
30
+ spec.add_development_dependency 'rake', '~> 13.0', '>= 13.0.1'
31
31
  spec.add_development_dependency 'rspec', '~> 3.8', '>= 3.8.0'
32
32
  spec.add_development_dependency 'rubocop', '~> 0.74', '>= 0.74.0'
33
33
  spec.add_development_dependency 'rubocop-performance', '~> 1.4', '>= 1.4.1'
@@ -30,6 +30,12 @@ module FinApps
30
30
 
31
31
  super id, "p/institution/consumer/#{id}"
32
32
  end
33
+
34
+ def public_token(id)
35
+ not_blank(id, :consumer_institution_id)
36
+
37
+ send_request "p/institution/consumer/#{id}/token", :get
38
+ end
33
39
  end
34
40
  end
35
41
  end
@@ -1,5 +1,5 @@
1
1
  # frozen_string_literal: true
2
2
 
3
3
  module FinApps
4
- VERSION = '5.0.19'
4
+ VERSION = '5.0.20'
5
5
  end
@@ -77,4 +77,16 @@ RSpec.describe FinApps::REST::PlaidConsumerInstitutions do
77
77
  expect(destroy[RESULTS]).to be_nil
78
78
  end
79
79
  end
80
+
81
+ describe '#public_token' do
82
+ subject(:public_token) do
83
+ FinApps::REST::PlaidConsumerInstitutions.new(api_client)
84
+ .public_token(:consumer_institution_id)
85
+ end
86
+
87
+ it_behaves_like 'an API request'
88
+ it_behaves_like 'a successful request'
89
+ it('returns no results') { expect(public_token[RESULTS]).not_to be_nil }
90
+ it('returns the public token') { expect(public_token[RESULTS]).to have_key(:public_token) }
91
+ end
80
92
  end
@@ -64,6 +64,9 @@ class FakeApi < Sinatra::Base
64
64
  delete("/#{version}/p/institution/consumer/:consumer_institution_id") do
65
65
  status 204
66
66
  end
67
+ get("/#{version}/p/institution/consumer/:consumer_institution_id/token") do
68
+ json_response 200, 'plaid/institution/consumer/public_token.json'
69
+ end
67
70
 
68
71
  # plaid_accounts
69
72
  get("/#{version}/p/account") do
@@ -0,0 +1,3 @@
1
+ {
2
+ "public_token": "public-sandbox-9b21a48b-ec09-4a62-b994-ac2bafd0b3db"
3
+ }
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: finapps
3
3
  version: !ruby/object:Gem::Version
4
- version: 5.0.19
4
+ version: 5.0.20
5
5
  platform: ruby
6
6
  authors:
7
7
  - Erich Quintero
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2019-12-17 00:00:00.000000000 Z
11
+ date: 2019-12-18 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: finapps_core
@@ -136,20 +136,20 @@ dependencies:
136
136
  requirements:
137
137
  - - "~>"
138
138
  - !ruby/object:Gem::Version
139
- version: '12.3'
139
+ version: '13.0'
140
140
  - - ">="
141
141
  - !ruby/object:Gem::Version
142
- version: 12.3.2
142
+ version: 13.0.1
143
143
  type: :development
144
144
  prerelease: false
145
145
  version_requirements: !ruby/object:Gem::Requirement
146
146
  requirements:
147
147
  - - "~>"
148
148
  - !ruby/object:Gem::Version
149
- version: '12.3'
149
+ version: '13.0'
150
150
  - - ">="
151
151
  - !ruby/object:Gem::Version
152
- version: 12.3.2
152
+ version: 13.0.1
153
153
  - !ruby/object:Gem::Dependency
154
154
  name: rspec
155
155
  requirement: !ruby/object:Gem::Requirement
@@ -398,6 +398,7 @@ files:
398
398
  - spec/support/fixtures/plaid/institution/consumer/add-missing-public-token.json
399
399
  - spec/support/fixtures/plaid/institution/consumer/add.json
400
400
  - spec/support/fixtures/plaid/institution/consumer/list.json
401
+ - spec/support/fixtures/plaid/institution/consumer/public_token.json
401
402
  - spec/support/fixtures/plaid/institution/consumer/show.json
402
403
  - spec/support/fixtures/plaid/institution/consumer/show_accounts.json
403
404
  - spec/support/fixtures/plaid/institution/logo.png
@@ -452,41 +453,41 @@ signing_key:
452
453
  specification_version: 4
453
454
  summary: FinApps REST API ruby client.
454
455
  test_files:
455
- - spec/utils/query_builder_spec.rb
456
- - spec/spec_helpers/client.rb
457
- - spec/spec_helper.rb
458
- - spec/support/fake_api.rb
459
- - spec/rest/alert_occurrences_spec.rb
460
- - spec/rest/consumers_spec.rb
461
- - spec/rest/order_statuses_spec.rb
462
- - spec/rest/api_request.rb
463
- - spec/rest/orders_spec.rb
464
- - spec/rest/client_spec.rb
465
- - spec/rest/password_resets_spec.rb
466
- - spec/rest/version_spec.rb
467
- - spec/rest/operators_spec.rb
468
- - spec/rest/tenant_app_settings_spec.rb
469
- - spec/rest/operators_password_resets_spec.rb
470
456
  - spec/rest/portfolios_consumers_spec.rb
457
+ - spec/rest/consumers_portfolios_spec.rb
458
+ - spec/rest/operators_password_resets_spec.rb
471
459
  - spec/rest/portfolios_available_consumers_spec.rb
472
460
  - spec/rest/products_spec.rb
473
- - spec/rest/order_assignments_spec.rb
474
- - spec/rest/order_refreshes_spec.rb
461
+ - spec/rest/statements_spec.rb
462
+ - spec/rest/alert_definitions_spec.rb
463
+ - spec/rest/version_spec.rb
464
+ - spec/rest/consumers_spec.rb
465
+ - spec/rest/orders_spec.rb
475
466
  - spec/rest/order_tokens_spec.rb
476
- - spec/rest/consumers_portfolios_spec.rb
467
+ - spec/rest/tenant_app_settings_spec.rb
468
+ - spec/rest/operators_spec.rb
477
469
  - spec/rest/verix/verix_records_spec.rb
478
470
  - spec/rest/verix/verix_metadata_spec.rb
479
- - spec/rest/sessions_spec.rb
480
- - spec/rest/portfolio_reports_spec.rb
481
- - spec/rest/portfolios_alerts_spec.rb
482
- - spec/rest/plaid/plaid_webhooks_spec.rb
471
+ - spec/rest/client_spec.rb
472
+ - spec/rest/tenant_settings_spec.rb
473
+ - spec/rest/api_request.rb
474
+ - spec/rest/alert_occurrences_spec.rb
475
+ - spec/rest/password_resets_spec.rb
476
+ - spec/rest/order_reports_spec.rb
477
+ - spec/rest/portfolios_spec.rb
478
+ - spec/rest/order_statuses_spec.rb
479
+ - spec/rest/plaid/plaid_accounts_spec.rb
483
480
  - spec/rest/plaid/plaid_account_permissions_spec.rb
484
- - spec/rest/plaid/plaid_consumer_institutions_spec.rb
481
+ - spec/rest/plaid/plaid_webhooks_spec.rb
485
482
  - spec/rest/plaid/plaid_institution_logos_spec.rb
486
- - spec/rest/plaid/plaid_accounts_spec.rb
487
- - spec/rest/order_reports_spec.rb
488
- - spec/rest/statements_spec.rb
489
- - spec/rest/alert_definitions_spec.rb
483
+ - spec/rest/plaid/plaid_consumer_institutions_spec.rb
484
+ - spec/rest/order_refreshes_spec.rb
490
485
  - spec/rest/order_notifications_spec.rb
491
- - spec/rest/tenant_settings_spec.rb
492
- - spec/rest/portfolios_spec.rb
486
+ - spec/rest/portfolios_alerts_spec.rb
487
+ - spec/rest/order_assignments_spec.rb
488
+ - spec/rest/sessions_spec.rb
489
+ - spec/rest/portfolio_reports_spec.rb
490
+ - spec/support/fake_api.rb
491
+ - spec/utils/query_builder_spec.rb
492
+ - spec/spec_helpers/client.rb
493
+ - spec/spec_helper.rb