lifen 1.6.7 → 1.6.8
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- checksums.yaml +4 -4
- data/CHANGELOG.md +5 -0
- data/Gemfile.lock +1 -1
- data/lib/lifen/communication/channel.rb +1 -1
- data/lib/lifen/version.rb +1 -1
- data/spec/cassettes/users/find_by_rpps/missing_line_attribute.yml +124 -0
- data/spec/users_spec.rb +13 -0
- metadata +4 -2
checksums.yaml
CHANGED
@@ -1,7 +1,7 @@
|
|
1
1
|
---
|
2
2
|
SHA1:
|
3
|
-
metadata.gz:
|
4
|
-
data.tar.gz:
|
3
|
+
metadata.gz: a3d322a8bc4f1c194166d375f02116f0ac2cbe8e
|
4
|
+
data.tar.gz: b8e31970ddbdca6c158ee313c4405b0f7340f2e9
|
5
5
|
SHA512:
|
6
|
-
metadata.gz:
|
7
|
-
data.tar.gz:
|
6
|
+
metadata.gz: 961fe51d9c3518abc4ed8372d250ec1df9a5f3b3ad75942a04609ddb6f8935050faa67b083c15585b33c9b5cb5f7736017d90e8ff9ec795d825b591014b6453e
|
7
|
+
data.tar.gz: f3ae94a202cc841fda0abe90f5b3a1147076232d82d6ef115ce6f0b7bfee1d4bd05334ee5b286ebe5fd6b07972fa6a7ecf4bb349320fdf2c2eff2a2f74538860
|
data/CHANGELOG.md
CHANGED
data/Gemfile.lock
CHANGED
@@ -25,7 +25,7 @@ module Lifen
|
|
25
25
|
end
|
26
26
|
|
27
27
|
def self.from_json(json, type = nil)
|
28
|
-
new(uuid: json["id"], type: type, value: json["value"] || "#{json["line"].join(", ")}, #{json["postalCode"]} #{json["city"]}")
|
28
|
+
new(uuid: json["id"], type: type, value: json["value"] || "#{Array(json["line"]).join(", ")}, #{json["postalCode"]} #{json["city"]}")
|
29
29
|
end
|
30
30
|
|
31
31
|
end
|
data/lib/lifen/version.rb
CHANGED
@@ -0,0 +1,124 @@
|
|
1
|
+
---
|
2
|
+
http_interactions:
|
3
|
+
- request:
|
4
|
+
method: get
|
5
|
+
uri: https://develop.lifen.fr/fhir/Practitioner/?identifier=810004085790
|
6
|
+
body:
|
7
|
+
encoding: UTF-8
|
8
|
+
string: "{}"
|
9
|
+
headers:
|
10
|
+
User-Agent:
|
11
|
+
- Faraday v0.11.0
|
12
|
+
Authorization:
|
13
|
+
- Bearer valid_application_access_token
|
14
|
+
Content-Type:
|
15
|
+
- application/json
|
16
|
+
Accept:
|
17
|
+
- application/json
|
18
|
+
Accept-Encoding:
|
19
|
+
- gzip;q=1.0,deflate;q=0.6,identity;q=0.3
|
20
|
+
response:
|
21
|
+
status:
|
22
|
+
code: 200
|
23
|
+
message: OK
|
24
|
+
headers:
|
25
|
+
Server:
|
26
|
+
- Apache-Coyote/1.1
|
27
|
+
X-B3-Sampled:
|
28
|
+
- '1'
|
29
|
+
X-B3-Spanid:
|
30
|
+
- e916970475956836
|
31
|
+
X-B3-Traceid:
|
32
|
+
- e916970475956836
|
33
|
+
X-Content-Type-Options:
|
34
|
+
- nosniff
|
35
|
+
X-Xss-Protection:
|
36
|
+
- 1; mode=block
|
37
|
+
Cache-Control:
|
38
|
+
- no-cache, no-store, max-age=0, must-revalidate
|
39
|
+
Pragma:
|
40
|
+
- no-cache
|
41
|
+
Expires:
|
42
|
+
- '0'
|
43
|
+
X-Powered-By:
|
44
|
+
- HAPI FHIR 2.1 REST Server (FHIR Server; FHIR 1.0.2/DSTU2)
|
45
|
+
Last-Modified:
|
46
|
+
- Wed, 01 Mar 2017 09:21:41 GMT
|
47
|
+
Content-Type:
|
48
|
+
- application/json+fhir;charset=UTF-8
|
49
|
+
Transfer-Encoding:
|
50
|
+
- chunked
|
51
|
+
Date:
|
52
|
+
- Wed, 01 Mar 2017 09:21:41 GMT
|
53
|
+
Connection:
|
54
|
+
- close
|
55
|
+
Access-Control-Allow-Credentials:
|
56
|
+
- 'true'
|
57
|
+
body:
|
58
|
+
encoding: UTF-8
|
59
|
+
string: |-
|
60
|
+
{
|
61
|
+
"resourceType": "Bundle",
|
62
|
+
"id": "d9015de6-9193-46db-b161-36ac26069a00",
|
63
|
+
"meta": {
|
64
|
+
"lastUpdated": "2017-03-01T09:21:41.553+00:00"
|
65
|
+
},
|
66
|
+
"type": "searchset",
|
67
|
+
"total": 1,
|
68
|
+
"link": [
|
69
|
+
{
|
70
|
+
"relation": "self",
|
71
|
+
"url": "http://demo.lifen.fr/public-api/fhir/Practitioner/?identifier=810004085790"
|
72
|
+
}
|
73
|
+
],
|
74
|
+
"entry": [
|
75
|
+
{
|
76
|
+
"fullUrl": "http://demo.lifen.fr/public-api/fhir/Practitioner/11e5c86b-e4ba-eee4-9b29-deb9993a92c0",
|
77
|
+
"resource": {
|
78
|
+
"resourceType": "Practitioner",
|
79
|
+
"id": "11e5c86b-e4ba-eee4-9b29-deb9993a92c0",
|
80
|
+
"identifier": [
|
81
|
+
{
|
82
|
+
"system": "http://honestica.com/fhir/identifier/fr/asip",
|
83
|
+
"value": "810004085790"
|
84
|
+
}
|
85
|
+
],
|
86
|
+
"name": {
|
87
|
+
"text": "WILLIAM ECLANCHER",
|
88
|
+
"family": [
|
89
|
+
"ECLANCHER"
|
90
|
+
],
|
91
|
+
"given": [
|
92
|
+
"WILLIAM"
|
93
|
+
],
|
94
|
+
"prefix": [
|
95
|
+
"DR"
|
96
|
+
]
|
97
|
+
},
|
98
|
+
"telecom": [
|
99
|
+
{
|
100
|
+
"id": "11e61052-91cf-185b-8234-6accfa9deeee",
|
101
|
+
"system": "email",
|
102
|
+
"value": "William.ECLANCHER@medical75.apicrypt.org"
|
103
|
+
},
|
104
|
+
{
|
105
|
+
"id": "11e62721-8caa-da09-b2d8-6accfa9deeee",
|
106
|
+
"system": "email",
|
107
|
+
"value": "william.eclancher@medecin.mssante.fr"
|
108
|
+
}
|
109
|
+
],
|
110
|
+
"address": [
|
111
|
+
{
|
112
|
+
"id": "11e5c86e-adb9-5453-9b29-deb9993a92c0",
|
113
|
+
"city": "Paris",
|
114
|
+
"postalCode": "75016",
|
115
|
+
"country": "FRANCE"
|
116
|
+
}
|
117
|
+
]
|
118
|
+
}
|
119
|
+
}
|
120
|
+
]
|
121
|
+
}
|
122
|
+
http_version:
|
123
|
+
recorded_at: Wed, 01 Mar 2017 09:21:41 GMT
|
124
|
+
recorded_with: VCR 3.0.3
|
data/spec/users_spec.rb
CHANGED
@@ -256,6 +256,19 @@ describe Lifen::User do
|
|
256
256
|
expect(address.value).to eq "Batiment Nord, 11 RUE CHARLES TELLIER, 75016 Paris"
|
257
257
|
end
|
258
258
|
|
259
|
+
context 'missing lines attribute' do
|
260
|
+
|
261
|
+
it 'does not raise an issue' do
|
262
|
+
VCR.use_cassette "users/find_by_rpps/missing_line_attribute" do
|
263
|
+
@user = Lifen::User.find_by_rpps("810004085790")
|
264
|
+
end
|
265
|
+
|
266
|
+
address = @user.channels.last
|
267
|
+
|
268
|
+
expect(address.value).to eq ", 75016 Paris"
|
269
|
+
end
|
270
|
+
end
|
271
|
+
|
259
272
|
|
260
273
|
end
|
261
274
|
|
metadata
CHANGED
@@ -1,14 +1,14 @@
|
|
1
1
|
--- !ruby/object:Gem::Specification
|
2
2
|
name: lifen
|
3
3
|
version: !ruby/object:Gem::Version
|
4
|
-
version: 1.6.
|
4
|
+
version: 1.6.8
|
5
5
|
platform: ruby
|
6
6
|
authors:
|
7
7
|
- Etienne Depaulis
|
8
8
|
autorequire:
|
9
9
|
bindir: bin
|
10
10
|
cert_chain: []
|
11
|
-
date: 2017-03-
|
11
|
+
date: 2017-03-23 00:00:00.000000000 Z
|
12
12
|
dependencies:
|
13
13
|
- !ruby/object:Gem::Dependency
|
14
14
|
name: bundler
|
@@ -197,6 +197,7 @@ files:
|
|
197
197
|
- spec/cassettes/users/find/existing_uuid.yml
|
198
198
|
- spec/cassettes/users/find/missing_uuid.yml
|
199
199
|
- spec/cassettes/users/find_by_rpps/existing_rpps.yml
|
200
|
+
- spec/cassettes/users/find_by_rpps/missing_line_attribute.yml
|
200
201
|
- spec/cassettes/users/reload/existing_uuid.yml
|
201
202
|
- spec/cassettes/users/save/existing_uuid.yml
|
202
203
|
- spec/cassettes/users/status/reload/invalid_token.yml
|
@@ -262,6 +263,7 @@ test_files:
|
|
262
263
|
- spec/cassettes/users/find/existing_uuid.yml
|
263
264
|
- spec/cassettes/users/find/missing_uuid.yml
|
264
265
|
- spec/cassettes/users/find_by_rpps/existing_rpps.yml
|
266
|
+
- spec/cassettes/users/find_by_rpps/missing_line_attribute.yml
|
265
267
|
- spec/cassettes/users/reload/existing_uuid.yml
|
266
268
|
- spec/cassettes/users/save/existing_uuid.yml
|
267
269
|
- spec/cassettes/users/status/reload/invalid_token.yml
|