Skip to content

Commit

Permalink
fix: remove employee phone_number test
Browse files Browse the repository at this point in the history
  • Loading branch information
sirtawast committed Sep 22, 2023
1 parent 08f9bd5 commit 5dc6233
Showing 1 changed file with 0 additions and 7 deletions.
7 changes: 0 additions & 7 deletions backend/benefit/applications/tests/test_applications_api.py
Original file line number Diff line number Diff line change
Expand Up @@ -531,7 +531,6 @@ def test_application_post_invalid_employee_data(api_client, application):
data["employee"]["monthly_pay"] = "30000000.00" # value too high
data["employee"]["social_security_number"] = "260778-323X" # invalid checksum
data["employee"]["employee_language"] = None # non-null required
data["employee"]["phone_number"] = "+359505658789" # Invalid country code
data["employee"]["working_hours"] = 16 # Must be > 18 hour per weeek
data["employee"]["vacation_money"] = -1 # Must be >= 0
data["employee"]["other_expenses"] = -1 # Must be >= 0
Expand All @@ -542,7 +541,6 @@ def test_application_post_invalid_employee_data(api_client, application):
assert response.data.keys() == {"employee"}
assert response.data["employee"].keys() == {
"monthly_pay",
"phone_number",
"social_security_number",
"employee_language",
"working_hours",
Expand Down Expand Up @@ -619,19 +617,14 @@ def test_application_put_edit_employee(api_client, application):
"""
new_ssn = "260778-323Y"
data = ApplicantApplicationSerializer(application).data
data["employee"]["phone_number"] = "0505658789"
data["employee"]["social_security_number"] = new_ssn
old_employee_pk = application.employee.pk
response = api_client.put(
get_detail_url(application),
data,
)
assert response.status_code == 200
assert (
response.data["employee"]["phone_number"] == "0505658789"
) # normalized format
application.refresh_from_db()
assert application.employee.phone_number == "+358505658789"
assert application.employee.social_security_number == new_ssn
assert old_employee_pk == application.employee.pk

Expand Down

0 comments on commit 5dc6233

Please sign in to comment.