fidor_api 0.1.1 → 0.1.2

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
- SHA1:
3
- metadata.gz: 88f1a281f0d36a0ff9a5690b030deecc3cf6d239
4
- data.tar.gz: 2ffb3283f62afadf3847d1b0f2e432b9e184c119
2
+ SHA256:
3
+ metadata.gz: 97d79aedc44411ce99bd89c3700e70ae29ab2ebe63c087ec4334dd7ab0eb060f
4
+ data.tar.gz: c86deca6712ddba2367a2a85be38fde92a6eb3fd832bf7c7a72bdba22557cf82
5
5
  SHA512:
6
- metadata.gz: 9a905a705a97cf7248e90965e5b6996b5139f9ca614c085295cccfd0c5e7da1bf4df99648d22c81eec4d97d4dd96777e7541a7576757eee9c72c0138b7089e73
7
- data.tar.gz: b988a49f55e77c1cb431e33523036692f19aa63589c81c04c23caf56f8faa266698a5125a1050777c4e135f3e9c05a9a5bfa0f4c8bf2813e6787bd741b5261d4
6
+ metadata.gz: 89297cd1ac37f13e1a59666ee0bb87954d8d71a325d0568ac6b4540ac20659e3ad911400ddba946dfa3387973ed3d99d79027ecbc82fc230de49fce4ce3030d4
7
+ data.tar.gz: 2a6850779ef5e7c0670b990a03a43812fa8d681143517d7b031e476e10ac99a0147b5b96562baa6e0e57af2653319793eb12712a59dc88782a6c7a12fa7d8b24
data/.ruby-version CHANGED
@@ -1 +1 @@
1
- 2.4.1
1
+ 2.5.0
data/.travis.yml CHANGED
@@ -1,12 +1,20 @@
1
+ branches:
2
+ only:
3
+ - master
4
+
1
5
  language: ruby
6
+
2
7
  rvm:
3
- - "2.2.7"
4
- - "2.3.4"
5
- - "2.4.1"
8
+ - "2.3.6"
9
+ - "2.4.3"
10
+ - "2.5.0"
11
+
6
12
  before_install:
7
13
  - gem install bundler
14
+
8
15
  addons:
9
16
  code_climate:
10
17
  repo_token: 2b2b2a8c28682817f985f0afba1e5d643bcc801c6af1a1294869bc118742e95f
18
+
11
19
  after_success:
12
20
  - bundle exec codeclimate-test-reporter
data/CHANGELOG.md CHANGED
@@ -1,5 +1,11 @@
1
1
  # Changelog
2
2
 
3
+ ## v0.1.2
4
+
5
+ * Allow usage in rails 5.2 projects
6
+ * Small bugfix for getting current user and chaning passwords
7
+ * Bump used Ruby Versions in Dev & CI
8
+
3
9
  ## v0.1.1
4
10
 
5
11
  * Allow usage in rails 5.1 projects
data/Gemfile CHANGED
@@ -10,6 +10,6 @@ group :development, :test do
10
10
  gem "shoulda-matchers", "~> 2.8"
11
11
  gem "vcr", "~> 3.0"
12
12
  gem "webmock"
13
- gem "simplecov", github: "colszowka/simplecov"
13
+ gem "simplecov"
14
14
  gem "codeclimate-test-reporter", group: :test, require: nil
15
15
  end
data/fidor_api.gemspec CHANGED
@@ -18,7 +18,7 @@ Gem::Specification.new do |spec|
18
18
  spec.require_paths = ["lib"]
19
19
 
20
20
  spec.add_dependency "faraday", "~> 0.8"
21
- spec.add_dependency "activesupport", ">= 4.2", "< 5.2"
22
- spec.add_dependency "activemodel", ">= 4.2", "< 5.2"
21
+ spec.add_dependency "activesupport", ">= 4.2", "< 6.0"
22
+ spec.add_dependency "activemodel", ">= 4.2", "< 6.0"
23
23
  spec.add_dependency "model_attribute", "~> 2.1"
24
24
  end
@@ -2,15 +2,14 @@ module FidorApi
2
2
  class Password < Connectivity::Resource
3
3
  extend ModelAttribute
4
4
 
5
- self.endpoint = Connectivity::Endpoint.new("/password_resets", :collection, version: "2", tokenless: true)
6
-
7
5
  def self.request_new(email)
8
- params = {email: email, type: "reset_token"}
9
- response = endpoint.for(self).put(action: "new_token", payload: params)
6
+ endpoint = Connectivity::Endpoint.new("/password_resets/new_token", :resource, version: "2", tokenless: true)
7
+ response = endpoint.for(self).put(payload: { email: email, type: "reset_token" })
10
8
  response.body["success"]
11
9
  end
12
10
 
13
11
  def self.update(attributes)
12
+ endpoint = Connectivity::Endpoint.new("/password_resets", :collection, version: "2", tokenless: true)
14
13
  response = endpoint.for(self).post(payload: attributes)
15
14
  response.body["success"]
16
15
  end
@@ -2,7 +2,7 @@ module FidorApi
2
2
  class User < Connectivity::Resource
3
3
  extend ModelAttribute
4
4
 
5
- self.endpoint = Connectivity::Endpoint.new('/users', :collection)
5
+ self.endpoint = Connectivity::Endpoint.new('/users/current', :resource)
6
6
 
7
7
  attribute :id, :integer
8
8
  attribute :email, :string
@@ -12,7 +12,7 @@ module FidorApi
12
12
  attribute :updated_at, :time
13
13
 
14
14
  def self.current
15
- new endpoint.for(self).get(action: 'current').body
15
+ new endpoint.for(self).get.body
16
16
  end
17
17
 
18
18
  module ClientSupport
@@ -1,3 +1,3 @@
1
1
  module FidorApi
2
- VERSION = "0.1.1"
2
+ VERSION = "0.1.2"
3
3
  end
metadata CHANGED
@@ -1,14 +1,14 @@
1
1
  --- !ruby/object:Gem::Specification
2
2
  name: fidor_api
3
3
  version: !ruby/object:Gem::Version
4
- version: 0.1.1
4
+ version: 0.1.2
5
5
  platform: ruby
6
6
  authors:
7
7
  - Fidor
8
8
  autorequire:
9
9
  bindir: bin
10
10
  cert_chain: []
11
- date: 2017-05-01 00:00:00.000000000 Z
11
+ date: 2018-01-03 00:00:00.000000000 Z
12
12
  dependencies:
13
13
  - !ruby/object:Gem::Dependency
14
14
  name: faraday
@@ -33,7 +33,7 @@ dependencies:
33
33
  version: '4.2'
34
34
  - - "<"
35
35
  - !ruby/object:Gem::Version
36
- version: '5.2'
36
+ version: '6.0'
37
37
  type: :runtime
38
38
  prerelease: false
39
39
  version_requirements: !ruby/object:Gem::Requirement
@@ -43,7 +43,7 @@ dependencies:
43
43
  version: '4.2'
44
44
  - - "<"
45
45
  - !ruby/object:Gem::Version
46
- version: '5.2'
46
+ version: '6.0'
47
47
  - !ruby/object:Gem::Dependency
48
48
  name: activemodel
49
49
  requirement: !ruby/object:Gem::Requirement
@@ -53,7 +53,7 @@ dependencies:
53
53
  version: '4.2'
54
54
  - - "<"
55
55
  - !ruby/object:Gem::Version
56
- version: '5.2'
56
+ version: '6.0'
57
57
  type: :runtime
58
58
  prerelease: false
59
59
  version_requirements: !ruby/object:Gem::Requirement
@@ -63,7 +63,7 @@ dependencies:
63
63
  version: '4.2'
64
64
  - - "<"
65
65
  - !ruby/object:Gem::Version
66
- version: '5.2'
66
+ version: '6.0'
67
67
  - !ruby/object:Gem::Dependency
68
68
  name: model_attribute
69
69
  requirement: !ruby/object:Gem::Requirement
@@ -171,7 +171,7 @@ required_rubygems_version: !ruby/object:Gem::Requirement
171
171
  version: '0'
172
172
  requirements: []
173
173
  rubyforge_project:
174
- rubygems_version: 2.6.11
174
+ rubygems_version: 2.7.4
175
175
  signing_key:
176
176
  specification_version: 4
177
177
  summary: Simple ruby client for the Fidor Bank API