Merge branch 'develop' into staging
This commit is contained in:
commit
a078dbfc05
2 changed files with 49 additions and 1 deletions
|
@ -25,7 +25,7 @@ feature 'As a User I wanna create a dossier', js: true do
|
||||||
expect(page).to have_current_path(users_dossier_recapitulatif_path(Dossier.first.id.to_s), only_path: true)
|
expect(page).to have_current_path(users_dossier_recapitulatif_path(Dossier.first.id.to_s), only_path: true)
|
||||||
end
|
end
|
||||||
|
|
||||||
scenario 'Identification through siret' do
|
scenario 'Identification through siret', vcr: {cassette_name: 'search_ban_paris'} do
|
||||||
login_as user, scope: :user
|
login_as user, scope: :user
|
||||||
visit commencer_path(procedure_path: procedure_with_siret.path)
|
visit commencer_path(procedure_path: procedure_with_siret.path)
|
||||||
expect(page).to have_current_path(users_dossier_path(Dossier.first.id.to_s), only_path: true)
|
expect(page).to have_current_path(users_dossier_path(Dossier.first.id.to_s), only_path: true)
|
||||||
|
|
48
spec/fixtures/cassettes/search_ban_paris.yml
vendored
Normal file
48
spec/fixtures/cassettes/search_ban_paris.yml
vendored
Normal file
|
@ -0,0 +1,48 @@
|
||||||
|
---
|
||||||
|
http_interactions:
|
||||||
|
- request:
|
||||||
|
method: get
|
||||||
|
uri: http://api-adresse.data.gouv.fr/search?limit=1&q=50%20AV%20DES%20CHAMPS%20ELYSEES%20complement_adresse%2075008%20PARIS%208
|
||||||
|
body:
|
||||||
|
encoding: US-ASCII
|
||||||
|
string: ''
|
||||||
|
headers:
|
||||||
|
Accept:
|
||||||
|
- "*/*"
|
||||||
|
Accept-Encoding:
|
||||||
|
- gzip, deflate
|
||||||
|
User-Agent:
|
||||||
|
- rest-client/2.0.0 (darwin15.6.0 x86_64) ruby/2.3.1p112
|
||||||
|
response:
|
||||||
|
status:
|
||||||
|
code: 200
|
||||||
|
message: OK
|
||||||
|
headers:
|
||||||
|
Server:
|
||||||
|
- nginx/1.11.3
|
||||||
|
Date:
|
||||||
|
- Tue, 20 Dec 2016 11:36:58 GMT
|
||||||
|
Content-Type:
|
||||||
|
- application/json; charset=utf-8
|
||||||
|
Content-Length:
|
||||||
|
- '660'
|
||||||
|
Connection:
|
||||||
|
- keep-alive
|
||||||
|
Access-Control-Allow-Origin:
|
||||||
|
- "*"
|
||||||
|
Access-Control-Allow-Headers:
|
||||||
|
- X-Requested-With
|
||||||
|
body:
|
||||||
|
encoding: UTF-8
|
||||||
|
string: '{"limit": 1, "attribution": "BAN", "version": "draft", "licence": "ODbL
|
||||||
|
1.0", "query": "50 AV DES CHAMPS ELYSEES complement_adresse 75008 PARIS 8",
|
||||||
|
"type": "FeatureCollection", "features": [{"geometry": {"type": "Point", "coordinates":
|
||||||
|
[2.306888, 48.870374]}, "properties": {"citycode": "75108", "postcode": "75008",
|
||||||
|
"name": "50 Avenue des Champs \u00c9lys\u00e9es", "id": "ADRNIVX_0000000270748251",
|
||||||
|
"type": "housenumber", "context": "75, \u00cele-de-France", "score": 0.596517719568567,
|
||||||
|
"label": "50 Avenue des Champs \u00c9lys\u00e9es 75008 Paris", "city": "Paris",
|
||||||
|
"housenumber": "50", "street": "Avenue des Champs \u00c9lys\u00e9es"}, "type":
|
||||||
|
"Feature"}]}'
|
||||||
|
http_version:
|
||||||
|
recorded_at: Tue, 20 Dec 2016 11:36:58 GMT
|
||||||
|
recorded_with: VCR 3.0.3
|
Loading…
Reference in a new issue