Skip to content

Conversation

d-beezee
Copy link
Member

No description provided.

@github-actions
Copy link

github-actions bot commented Sep 15, 2023

Tests difference:

New Tests

< Iban - Should answer 200 if logged in
< Iban - Should create a row in the requests with fiscal_profile_id = current tester fiscal id
< Iban - Should create a row in the requests with tester_id = current tester id
< Iban - Should create a row in the requests with the amount equal to sum of current payments not paid and is_paid=0
< Iban - Should create a row in the requests with the body data for iban and account_holder and paypal_email null
< Iban - Should update the attributions with is_requested =1 and request_id = the id of the inserted request 
< POST /users/me/payments - empty booty - Should answer 403 if logged in but with empty booty
< POST /users/me/payments - inactive fiscal profile - Should answer 403 if logged with a booty but without fiscal profile
< POST /users/me/payments - processing payment - Should answer 403 if logged with a valid fiscal, a booty over threshold but with a payment already processing
< POST /users/me/payments - stamp not required - Should create a row with stamp_required = false if the amount gross is under 77,47
< POST /users/me/payments - under threshold - Should answer 403 if logged with a valid fiscal profile but the booty under threshold
< POST /users/me/payments - under threshold - Should answer 403 if logged with a valid fiscal, a booty over threshold but with a payment already processing
< POST /users/me/payments/ - fiscal profile 1 - Should create a row in the requests amount_witholding = gross - amount  if fiscal category is 1
< POST /users/me/payments/ - fiscal profile 1 - Should create a row in the requests with amount_gross = 125% of the amount if fiscal category is 1
< POST /users/me/payments/ - fiscal profile 1 - Should create a row in the requests withholding_tax_percentage = 20  if fiscal category is 1
< POST /users/me/payments/ - fiscal profile 2 - Should answer 403 if fiscal category is 2 (i.e. witholding > 5000 )
< POST /users/me/payments/ - fiscal profile 3 - Should answer 403 if fiscal category is 3 (i.e. vat )
< POST /users/me/payments/ - fiscal profile 4 - Should answer 200 if fiscal category is 4 (i.e. foreign)
< POST /users/me/payments/ - fiscal profile 4 - Should create a row in the requests amount_witholding = gross - amount  if fiscal category is 4
< POST /users/me/payments/ - fiscal profile 4 - Should create a row in the requests with amount_gross = 100% of the amount if fiscal category is 4
< POST /users/me/payments/ - fiscal profile 4 - Should create a row in the requests withholding_tax_percentage = 0  if fiscal category is 4
< POST /users/me/payments/ - fiscal profile 5 - Should answer 403 if fiscal category is 3 (i.e. company )
< Paypal - Should answer 200 if logged in
< Paypal - Should answer 403 if not logged in
< Paypal - Should create a row in the requests paypal_email = the email sent in the body and iban null
< Paypal - Should create a row in the requests with fiscal_profile_id = current tester fiscal id
< Paypal - Should create a row in the requests with tester_id = current tester id
< Paypal - Should create a row in the requests with the amount equal to current sum of payments not paid and is_paid=0
< Paypal - Should update the attributions with is_requested =1 and request_id = the id of the inserted request 

Removed Tests

> POST /users/me/payments - invalid data - Should answer 403 if logged in but with empty booty
> POST /users/me/payments - invalid data - Should answer 403 if logged with a booty but with an invalid fiscal profile
> POST /users/me/payments - invalid data - Should answer 403 if logged with a booty but without fiscal profile
> POST /users/me/payments - invalid data - Should answer 403 if logged with a valid fiscal profile but the booty under threshold
> POST /users/me/payments - invalid data - Should answer 403 if logged with a valid fiscal, a booty over threshold but with a payment already processing
> POST /users/me/payments - stamp required - Should create a row with stamp_required = false if the amount gross is under 77,47
< POST /users/me/payments/ - fiscal profile 2 - Should answer 403 if fiscal category is 2 (i.e. witholding > 5000 )
> POST /users/me/payments - valid iban - Should answer 200 if logged in
> POST /users/me/payments - valid iban - Should create a row in the requests with fiscal_profile_id = current tester fiscal id
> POST /users/me/payments - valid iban - Should create a row in the requests with tester_id = current tester id
> POST /users/me/payments - valid iban - Should create a row in the requests with the amount equal to current pending booty and is_paid=0
> POST /users/me/payments - valid iban - Should create a row in the requests with the body data for iban and account_holder and paypal_email null
> POST /users/me/payments - valid iban - Should update the attributions with is_requested =1 and request_id = the id of the inserted request 
> POST /users/me/payments - valid paypal - Should answer 200 if logged in
> POST /users/me/payments - valid paypal - Should answer 403 if not logged in
> POST /users/me/payments - valid paypal - Should create a row in the requests paypal_email = the email sent in the body and iban null
> POST /users/me/payments - valid paypal - Should create a row in the requests with fiscal_profile_id = current tester fiscal id
> POST /users/me/payments - valid paypal - Should create a row in the requests with tester_id = current tester id
> POST /users/me/payments - valid paypal - Should create a row in the requests with the amount equal to current pending booty and is_paid=0
> POST /users/me/payments - valid paypal - Should update the attributions with is_requested =1 and request_id = the id of the inserted request 
> POST /users/me/payments/ - fiscal profiles - Should answer 200 if fiscal category is 4 (i.e. foreign)
> POST /users/me/payments/ - fiscal profiles - Should answer 403 if fiscal category is 2 (i.e. witholding > 5000 )
> POST /users/me/payments/ - fiscal profiles - Should answer 403 if fiscal category is 3 (i.e. not a compatible regime)
> POST /users/me/payments/ - fiscal profiles - Should answer 403 if fiscal category is 5 (i.e. company)
> POST /users/me/payments/ - fiscal profiles - Should create a row in the requests amount_witholding = gross - amount  if fiscal category is 1
> POST /users/me/payments/ - fiscal profiles - Should create a row in the requests amount_witholding = gross - amount  if fiscal category is 4
> POST /users/me/payments/ - fiscal profiles - Should create a row in the requests with amount_gross = 100% of the amount if fiscal category is 4
> POST /users/me/payments/ - fiscal profiles - Should create a row in the requests with amount_gross = 125% of the amount if fiscal category is 1
> POST /users/me/payments/ - fiscal profiles - Should create a row in the requests withholding_tax_percentage = 0  if fiscal category is 4
> POST /users/me/payments/ - fiscal profiles - Should create a row in the requests withholding_tax_percentage = 20  if fiscal category is 1

@d-beezee d-beezee changed the base branch from add-examples to develop September 15, 2023 16:40
@d-beezee d-beezee force-pushed the use-gross-on-post-payments branch from 963f875 to 1e4639d Compare September 15, 2023 16:41
@coveralls
Copy link
Collaborator

Coverage Status

coverage: 73.502% (+0.08%) from 73.427% when pulling d5e1bd4 on use-gross-on-post-payments into 0570fb8 on develop.

@d-beezee d-beezee closed this Sep 22, 2023
@d-beezee d-beezee deleted the use-gross-on-post-payments branch September 22, 2023 13:27
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants