Merge pull request #9713 from demarches-simplifiees/8742-privileges
tech: migration api entreprise privileges
This commit is contained in:
commit
ba17f8d8aa
3 changed files with 3 additions and 3 deletions
|
@ -10,7 +10,7 @@ class APIEntreprise::API
|
||||||
ATTESTATION_SOCIALE_RESOURCE_NAME = "v4/urssaf/unites_legales/%{id}/attestation_vigilance"
|
ATTESTATION_SOCIALE_RESOURCE_NAME = "v4/urssaf/unites_legales/%{id}/attestation_vigilance"
|
||||||
ATTESTATION_FISCALE_RESOURCE_NAME = "v4/dgfip/unites_legales/%{id}/attestation_fiscale"
|
ATTESTATION_FISCALE_RESOURCE_NAME = "v4/dgfip/unites_legales/%{id}/attestation_fiscale"
|
||||||
BILANS_BDF_RESOURCE_NAME = "v3/banque_de_france/unites_legales/%{id}/bilans"
|
BILANS_BDF_RESOURCE_NAME = "v3/banque_de_france/unites_legales/%{id}/bilans"
|
||||||
PRIVILEGES_RESOURCE_NAME = "v2/privileges"
|
PRIVILEGES_RESOURCE_NAME = "privileges"
|
||||||
|
|
||||||
TIMEOUT = 20
|
TIMEOUT = 20
|
||||||
DEFAULT_API_ENTREPRISE_DELAY = 0.0
|
DEFAULT_API_ENTREPRISE_DELAY = 0.0
|
||||||
|
|
|
@ -300,7 +300,7 @@ describe APIEntreprise::API do
|
||||||
before do
|
before do
|
||||||
api.token = token
|
api.token = token
|
||||||
|
|
||||||
stub_request(:get, "https://entreprise.api.gouv.fr/v2/privileges")
|
stub_request(:get, "https://entreprise.api.gouv.fr/privileges")
|
||||||
.to_return(body: body, status: status)
|
.to_return(body: body, status: status)
|
||||||
end
|
end
|
||||||
|
|
||||||
|
|
|
@ -7,7 +7,7 @@ describe APIEntreprise::PrivilegesAdapter do
|
||||||
subject { adapter }
|
subject { adapter }
|
||||||
|
|
||||||
before do
|
before do
|
||||||
stub_request(:get, "https://entreprise.api.gouv.fr/v2/privileges")
|
stub_request(:get, "https://entreprise.api.gouv.fr/privileges")
|
||||||
.to_return(body: body, status: status)
|
.to_return(body: body, status: status)
|
||||||
allow_any_instance_of(APIEntrepriseToken).to receive(:expired?).and_return(false)
|
allow_any_instance_of(APIEntrepriseToken).to receive(:expired?).and_return(false)
|
||||||
end
|
end
|
||||||
|
|
Loading…
Reference in a new issue