diff --git a/tests/api_resources/hris/benefits/test_individuals.py b/tests/api_resources/hris/benefits/test_individuals.py index 9defbc96..98571e3e 100644 --- a/tests/api_resources/hris/benefits/test_individuals.py +++ b/tests/api_resources/hris/benefits/test_individuals.py @@ -26,7 +26,7 @@ class TestIndividuals: @parametrize def test_method_enroll_many(self, client: Finch) -> None: individual = client.hris.benefits.individuals.enroll_many( - "string", + benefit_id="benefit_id", individuals=[{}], ) assert_matches_type(SyncSinglePage[EnrolledIndividual], individual, path=["response"]) @@ -34,7 +34,7 @@ def test_method_enroll_many(self, client: Finch) -> None: @parametrize def test_raw_response_enroll_many(self, client: Finch) -> None: response = client.hris.benefits.individuals.with_raw_response.enroll_many( - "string", + benefit_id="benefit_id", individuals=[{}], ) @@ -46,7 +46,7 @@ def test_raw_response_enroll_many(self, client: Finch) -> None: @parametrize def test_streaming_response_enroll_many(self, client: Finch) -> None: with client.hris.benefits.individuals.with_streaming_response.enroll_many( - "string", + benefit_id="benefit_id", individuals=[{}], ) as response: assert not response.is_closed @@ -61,21 +61,21 @@ def test_streaming_response_enroll_many(self, client: Finch) -> None: def test_path_params_enroll_many(self, client: Finch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): client.hris.benefits.individuals.with_raw_response.enroll_many( - "", + benefit_id="", individuals=[{}], ) @parametrize def test_method_enrolled_ids(self, client: Finch) -> None: individual = client.hris.benefits.individuals.enrolled_ids( - "string", + "benefit_id", ) assert_matches_type(IndividualEnrolledIDsResponse, individual, path=["response"]) @parametrize def test_raw_response_enrolled_ids(self, client: Finch) -> None: response = client.hris.benefits.individuals.with_raw_response.enrolled_ids( - "string", + "benefit_id", ) assert response.is_closed is True @@ -86,7 +86,7 @@ def test_raw_response_enrolled_ids(self, client: Finch) -> None: @parametrize def test_streaming_response_enrolled_ids(self, client: Finch) -> None: with client.hris.benefits.individuals.with_streaming_response.enrolled_ids( - "string", + "benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -106,14 +106,14 @@ def test_path_params_enrolled_ids(self, client: Finch) -> None: @parametrize def test_method_retrieve_many_benefits(self, client: Finch) -> None: individual = client.hris.benefits.individuals.retrieve_many_benefits( - "string", + benefit_id="benefit_id", ) assert_matches_type(SyncSinglePage[IndividualBenefit], individual, path=["response"]) @parametrize def test_method_retrieve_many_benefits_with_all_params(self, client: Finch) -> None: individual = client.hris.benefits.individuals.retrieve_many_benefits( - "string", + benefit_id="benefit_id", individual_ids="d675d2b7-6d7b-41a8-b2d3-001eb3fb88f6,d02a6346-1f08-4312-a064-49ff3cafaa7a", ) assert_matches_type(SyncSinglePage[IndividualBenefit], individual, path=["response"]) @@ -121,7 +121,7 @@ def test_method_retrieve_many_benefits_with_all_params(self, client: Finch) -> N @parametrize def test_raw_response_retrieve_many_benefits(self, client: Finch) -> None: response = client.hris.benefits.individuals.with_raw_response.retrieve_many_benefits( - "string", + benefit_id="benefit_id", ) assert response.is_closed is True @@ -132,7 +132,7 @@ def test_raw_response_retrieve_many_benefits(self, client: Finch) -> None: @parametrize def test_streaming_response_retrieve_many_benefits(self, client: Finch) -> None: with client.hris.benefits.individuals.with_streaming_response.retrieve_many_benefits( - "string", + benefit_id="benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -146,20 +146,20 @@ def test_streaming_response_retrieve_many_benefits(self, client: Finch) -> None: def test_path_params_retrieve_many_benefits(self, client: Finch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): client.hris.benefits.individuals.with_raw_response.retrieve_many_benefits( - "", + benefit_id="", ) @parametrize def test_method_unenroll_many(self, client: Finch) -> None: individual = client.hris.benefits.individuals.unenroll_many( - "string", + benefit_id="benefit_id", ) assert_matches_type(SyncSinglePage[UnenrolledIndividual], individual, path=["response"]) @parametrize def test_method_unenroll_many_with_all_params(self, client: Finch) -> None: individual = client.hris.benefits.individuals.unenroll_many( - "string", + benefit_id="benefit_id", individual_ids=["string", "string", "string"], ) assert_matches_type(SyncSinglePage[UnenrolledIndividual], individual, path=["response"]) @@ -167,7 +167,7 @@ def test_method_unenroll_many_with_all_params(self, client: Finch) -> None: @parametrize def test_raw_response_unenroll_many(self, client: Finch) -> None: response = client.hris.benefits.individuals.with_raw_response.unenroll_many( - "string", + benefit_id="benefit_id", ) assert response.is_closed is True @@ -178,7 +178,7 @@ def test_raw_response_unenroll_many(self, client: Finch) -> None: @parametrize def test_streaming_response_unenroll_many(self, client: Finch) -> None: with client.hris.benefits.individuals.with_streaming_response.unenroll_many( - "string", + benefit_id="benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -192,7 +192,7 @@ def test_streaming_response_unenroll_many(self, client: Finch) -> None: def test_path_params_unenroll_many(self, client: Finch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): client.hris.benefits.individuals.with_raw_response.unenroll_many( - "", + benefit_id="", ) @@ -202,7 +202,7 @@ class TestAsyncIndividuals: @parametrize async def test_method_enroll_many(self, async_client: AsyncFinch) -> None: individual = await async_client.hris.benefits.individuals.enroll_many( - "string", + benefit_id="benefit_id", individuals=[{}], ) assert_matches_type(AsyncSinglePage[EnrolledIndividual], individual, path=["response"]) @@ -210,7 +210,7 @@ async def test_method_enroll_many(self, async_client: AsyncFinch) -> None: @parametrize async def test_raw_response_enroll_many(self, async_client: AsyncFinch) -> None: response = await async_client.hris.benefits.individuals.with_raw_response.enroll_many( - "string", + benefit_id="benefit_id", individuals=[{}], ) @@ -222,7 +222,7 @@ async def test_raw_response_enroll_many(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_enroll_many(self, async_client: AsyncFinch) -> None: async with async_client.hris.benefits.individuals.with_streaming_response.enroll_many( - "string", + benefit_id="benefit_id", individuals=[{}], ) as response: assert not response.is_closed @@ -237,21 +237,21 @@ async def test_streaming_response_enroll_many(self, async_client: AsyncFinch) -> async def test_path_params_enroll_many(self, async_client: AsyncFinch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): await async_client.hris.benefits.individuals.with_raw_response.enroll_many( - "", + benefit_id="", individuals=[{}], ) @parametrize async def test_method_enrolled_ids(self, async_client: AsyncFinch) -> None: individual = await async_client.hris.benefits.individuals.enrolled_ids( - "string", + "benefit_id", ) assert_matches_type(IndividualEnrolledIDsResponse, individual, path=["response"]) @parametrize async def test_raw_response_enrolled_ids(self, async_client: AsyncFinch) -> None: response = await async_client.hris.benefits.individuals.with_raw_response.enrolled_ids( - "string", + "benefit_id", ) assert response.is_closed is True @@ -262,7 +262,7 @@ async def test_raw_response_enrolled_ids(self, async_client: AsyncFinch) -> None @parametrize async def test_streaming_response_enrolled_ids(self, async_client: AsyncFinch) -> None: async with async_client.hris.benefits.individuals.with_streaming_response.enrolled_ids( - "string", + "benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -282,14 +282,14 @@ async def test_path_params_enrolled_ids(self, async_client: AsyncFinch) -> None: @parametrize async def test_method_retrieve_many_benefits(self, async_client: AsyncFinch) -> None: individual = await async_client.hris.benefits.individuals.retrieve_many_benefits( - "string", + benefit_id="benefit_id", ) assert_matches_type(AsyncSinglePage[IndividualBenefit], individual, path=["response"]) @parametrize async def test_method_retrieve_many_benefits_with_all_params(self, async_client: AsyncFinch) -> None: individual = await async_client.hris.benefits.individuals.retrieve_many_benefits( - "string", + benefit_id="benefit_id", individual_ids="d675d2b7-6d7b-41a8-b2d3-001eb3fb88f6,d02a6346-1f08-4312-a064-49ff3cafaa7a", ) assert_matches_type(AsyncSinglePage[IndividualBenefit], individual, path=["response"]) @@ -297,7 +297,7 @@ async def test_method_retrieve_many_benefits_with_all_params(self, async_client: @parametrize async def test_raw_response_retrieve_many_benefits(self, async_client: AsyncFinch) -> None: response = await async_client.hris.benefits.individuals.with_raw_response.retrieve_many_benefits( - "string", + benefit_id="benefit_id", ) assert response.is_closed is True @@ -308,7 +308,7 @@ async def test_raw_response_retrieve_many_benefits(self, async_client: AsyncFinc @parametrize async def test_streaming_response_retrieve_many_benefits(self, async_client: AsyncFinch) -> None: async with async_client.hris.benefits.individuals.with_streaming_response.retrieve_many_benefits( - "string", + benefit_id="benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -322,20 +322,20 @@ async def test_streaming_response_retrieve_many_benefits(self, async_client: Asy async def test_path_params_retrieve_many_benefits(self, async_client: AsyncFinch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): await async_client.hris.benefits.individuals.with_raw_response.retrieve_many_benefits( - "", + benefit_id="", ) @parametrize async def test_method_unenroll_many(self, async_client: AsyncFinch) -> None: individual = await async_client.hris.benefits.individuals.unenroll_many( - "string", + benefit_id="benefit_id", ) assert_matches_type(AsyncSinglePage[UnenrolledIndividual], individual, path=["response"]) @parametrize async def test_method_unenroll_many_with_all_params(self, async_client: AsyncFinch) -> None: individual = await async_client.hris.benefits.individuals.unenroll_many( - "string", + benefit_id="benefit_id", individual_ids=["string", "string", "string"], ) assert_matches_type(AsyncSinglePage[UnenrolledIndividual], individual, path=["response"]) @@ -343,7 +343,7 @@ async def test_method_unenroll_many_with_all_params(self, async_client: AsyncFin @parametrize async def test_raw_response_unenroll_many(self, async_client: AsyncFinch) -> None: response = await async_client.hris.benefits.individuals.with_raw_response.unenroll_many( - "string", + benefit_id="benefit_id", ) assert response.is_closed is True @@ -354,7 +354,7 @@ async def test_raw_response_unenroll_many(self, async_client: AsyncFinch) -> Non @parametrize async def test_streaming_response_unenroll_many(self, async_client: AsyncFinch) -> None: async with async_client.hris.benefits.individuals.with_streaming_response.unenroll_many( - "string", + benefit_id="benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -368,5 +368,5 @@ async def test_streaming_response_unenroll_many(self, async_client: AsyncFinch) async def test_path_params_unenroll_many(self, async_client: AsyncFinch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): await async_client.hris.benefits.individuals.with_raw_response.unenroll_many( - "", + benefit_id="", ) diff --git a/tests/api_resources/hris/test_benefits.py b/tests/api_resources/hris/test_benefits.py index ea02d4ac..ce1adced 100644 --- a/tests/api_resources/hris/test_benefits.py +++ b/tests/api_resources/hris/test_benefits.py @@ -31,7 +31,7 @@ def test_method_create(self, client: Finch) -> None: @parametrize def test_method_create_with_all_params(self, client: Finch) -> None: benefit = client.hris.benefits.create( - description="string", + description="description", frequency="one_time", type="401k", ) @@ -60,14 +60,14 @@ def test_streaming_response_create(self, client: Finch) -> None: @parametrize def test_method_retrieve(self, client: Finch) -> None: benefit = client.hris.benefits.retrieve( - "string", + "benefit_id", ) assert_matches_type(CompanyBenefit, benefit, path=["response"]) @parametrize def test_raw_response_retrieve(self, client: Finch) -> None: response = client.hris.benefits.with_raw_response.retrieve( - "string", + "benefit_id", ) assert response.is_closed is True @@ -78,7 +78,7 @@ def test_raw_response_retrieve(self, client: Finch) -> None: @parametrize def test_streaming_response_retrieve(self, client: Finch) -> None: with client.hris.benefits.with_streaming_response.retrieve( - "string", + "benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -98,22 +98,22 @@ def test_path_params_retrieve(self, client: Finch) -> None: @parametrize def test_method_update(self, client: Finch) -> None: benefit = client.hris.benefits.update( - "string", + benefit_id="benefit_id", ) assert_matches_type(UpdateCompanyBenefitResponse, benefit, path=["response"]) @parametrize def test_method_update_with_all_params(self, client: Finch) -> None: benefit = client.hris.benefits.update( - "string", - description="string", + benefit_id="benefit_id", + description="description", ) assert_matches_type(UpdateCompanyBenefitResponse, benefit, path=["response"]) @parametrize def test_raw_response_update(self, client: Finch) -> None: response = client.hris.benefits.with_raw_response.update( - "string", + benefit_id="benefit_id", ) assert response.is_closed is True @@ -124,7 +124,7 @@ def test_raw_response_update(self, client: Finch) -> None: @parametrize def test_streaming_response_update(self, client: Finch) -> None: with client.hris.benefits.with_streaming_response.update( - "string", + benefit_id="benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -138,7 +138,7 @@ def test_streaming_response_update(self, client: Finch) -> None: def test_path_params_update(self, client: Finch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): client.hris.benefits.with_raw_response.update( - "", + benefit_id="", ) @parametrize @@ -203,7 +203,7 @@ async def test_method_create(self, async_client: AsyncFinch) -> None: @parametrize async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> None: benefit = await async_client.hris.benefits.create( - description="string", + description="description", frequency="one_time", type="401k", ) @@ -232,14 +232,14 @@ async def test_streaming_response_create(self, async_client: AsyncFinch) -> None @parametrize async def test_method_retrieve(self, async_client: AsyncFinch) -> None: benefit = await async_client.hris.benefits.retrieve( - "string", + "benefit_id", ) assert_matches_type(CompanyBenefit, benefit, path=["response"]) @parametrize async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: response = await async_client.hris.benefits.with_raw_response.retrieve( - "string", + "benefit_id", ) assert response.is_closed is True @@ -250,7 +250,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_retrieve(self, async_client: AsyncFinch) -> None: async with async_client.hris.benefits.with_streaming_response.retrieve( - "string", + "benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -270,22 +270,22 @@ async def test_path_params_retrieve(self, async_client: AsyncFinch) -> None: @parametrize async def test_method_update(self, async_client: AsyncFinch) -> None: benefit = await async_client.hris.benefits.update( - "string", + benefit_id="benefit_id", ) assert_matches_type(UpdateCompanyBenefitResponse, benefit, path=["response"]) @parametrize async def test_method_update_with_all_params(self, async_client: AsyncFinch) -> None: benefit = await async_client.hris.benefits.update( - "string", - description="string", + benefit_id="benefit_id", + description="description", ) assert_matches_type(UpdateCompanyBenefitResponse, benefit, path=["response"]) @parametrize async def test_raw_response_update(self, async_client: AsyncFinch) -> None: response = await async_client.hris.benefits.with_raw_response.update( - "string", + benefit_id="benefit_id", ) assert response.is_closed is True @@ -296,7 +296,7 @@ async def test_raw_response_update(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_update(self, async_client: AsyncFinch) -> None: async with async_client.hris.benefits.with_streaming_response.update( - "string", + benefit_id="benefit_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -310,7 +310,7 @@ async def test_streaming_response_update(self, async_client: AsyncFinch) -> None async def test_path_params_update(self, async_client: AsyncFinch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `benefit_id` but received ''"): await async_client.hris.benefits.with_raw_response.update( - "", + benefit_id="", ) @parametrize diff --git a/tests/api_resources/hris/test_employments.py b/tests/api_resources/hris/test_employments.py index d228f309..22779d16 100644 --- a/tests/api_resources/hris/test_employments.py +++ b/tests/api_resources/hris/test_employments.py @@ -21,14 +21,22 @@ class TestEmployments: @parametrize def test_method_retrieve_many(self, client: Finch) -> None: employment = client.hris.employments.retrieve_many( - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) assert_matches_type(SyncResponsesPage[EmploymentDataResponse], employment, path=["response"]) @parametrize def test_raw_response_retrieve_many(self, client: Finch) -> None: response = client.hris.employments.with_raw_response.retrieve_many( - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) assert response.is_closed is True @@ -39,7 +47,11 @@ def test_raw_response_retrieve_many(self, client: Finch) -> None: @parametrize def test_streaming_response_retrieve_many(self, client: Finch) -> None: with client.hris.employments.with_streaming_response.retrieve_many( - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -56,14 +68,22 @@ class TestAsyncEmployments: @parametrize async def test_method_retrieve_many(self, async_client: AsyncFinch) -> None: employment = await async_client.hris.employments.retrieve_many( - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) assert_matches_type(AsyncResponsesPage[EmploymentDataResponse], employment, path=["response"]) @parametrize async def test_raw_response_retrieve_many(self, async_client: AsyncFinch) -> None: response = await async_client.hris.employments.with_raw_response.retrieve_many( - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) assert response.is_closed is True @@ -74,7 +94,11 @@ async def test_raw_response_retrieve_many(self, async_client: AsyncFinch) -> Non @parametrize async def test_streaming_response_retrieve_many(self, async_client: AsyncFinch) -> None: async with async_client.hris.employments.with_streaming_response.retrieve_many( - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" diff --git a/tests/api_resources/hris/test_individuals.py b/tests/api_resources/hris/test_individuals.py index f34d10fb..72031f6d 100644 --- a/tests/api_resources/hris/test_individuals.py +++ b/tests/api_resources/hris/test_individuals.py @@ -27,7 +27,11 @@ def test_method_retrieve_many(self, client: Finch) -> None: def test_method_retrieve_many_with_all_params(self, client: Finch) -> None: individual = client.hris.individuals.retrieve_many( options={"include": ["string", "string", "string"]}, - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) assert_matches_type(SyncResponsesPage[IndividualResponse], individual, path=["response"]) @@ -64,7 +68,11 @@ async def test_method_retrieve_many(self, async_client: AsyncFinch) -> None: async def test_method_retrieve_many_with_all_params(self, async_client: AsyncFinch) -> None: individual = await async_client.hris.individuals.retrieve_many( options={"include": ["string", "string", "string"]}, - requests=[{"individual_id": "string"}, {"individual_id": "string"}, {"individual_id": "string"}], + requests=[ + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + {"individual_id": "individual_id"}, + ], ) assert_matches_type(AsyncResponsesPage[IndividualResponse], individual, path=["response"]) diff --git a/tests/api_resources/jobs/test_automated.py b/tests/api_resources/jobs/test_automated.py index 5cf5644a..a56e5d93 100644 --- a/tests/api_resources/jobs/test_automated.py +++ b/tests/api_resources/jobs/test_automated.py @@ -52,14 +52,14 @@ def test_streaming_response_create(self, client: Finch) -> None: @parametrize def test_method_retrieve(self, client: Finch) -> None: automated = client.jobs.automated.retrieve( - "string", + "job_id", ) assert_matches_type(AutomatedAsyncJob, automated, path=["response"]) @parametrize def test_raw_response_retrieve(self, client: Finch) -> None: response = client.jobs.automated.with_raw_response.retrieve( - "string", + "job_id", ) assert response.is_closed is True @@ -70,7 +70,7 @@ def test_raw_response_retrieve(self, client: Finch) -> None: @parametrize def test_streaming_response_retrieve(self, client: Finch) -> None: with client.jobs.automated.with_streaming_response.retrieve( - "string", + "job_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -158,14 +158,14 @@ async def test_streaming_response_create(self, async_client: AsyncFinch) -> None @parametrize async def test_method_retrieve(self, async_client: AsyncFinch) -> None: automated = await async_client.jobs.automated.retrieve( - "string", + "job_id", ) assert_matches_type(AutomatedAsyncJob, automated, path=["response"]) @parametrize async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: response = await async_client.jobs.automated.with_raw_response.retrieve( - "string", + "job_id", ) assert response.is_closed is True @@ -176,7 +176,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_retrieve(self, async_client: AsyncFinch) -> None: async with async_client.jobs.automated.with_streaming_response.retrieve( - "string", + "job_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" diff --git a/tests/api_resources/jobs/test_manual.py b/tests/api_resources/jobs/test_manual.py index ec6d528a..df63695c 100644 --- a/tests/api_resources/jobs/test_manual.py +++ b/tests/api_resources/jobs/test_manual.py @@ -20,14 +20,14 @@ class TestManual: @parametrize def test_method_retrieve(self, client: Finch) -> None: manual = client.jobs.manual.retrieve( - "string", + "job_id", ) assert_matches_type(ManualAsyncJob, manual, path=["response"]) @parametrize def test_raw_response_retrieve(self, client: Finch) -> None: response = client.jobs.manual.with_raw_response.retrieve( - "string", + "job_id", ) assert response.is_closed is True @@ -38,7 +38,7 @@ def test_raw_response_retrieve(self, client: Finch) -> None: @parametrize def test_streaming_response_retrieve(self, client: Finch) -> None: with client.jobs.manual.with_streaming_response.retrieve( - "string", + "job_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -62,14 +62,14 @@ class TestAsyncManual: @parametrize async def test_method_retrieve(self, async_client: AsyncFinch) -> None: manual = await async_client.jobs.manual.retrieve( - "string", + "job_id", ) assert_matches_type(ManualAsyncJob, manual, path=["response"]) @parametrize async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: response = await async_client.jobs.manual.with_raw_response.retrieve( - "string", + "job_id", ) assert response.is_closed is True @@ -80,7 +80,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_retrieve(self, async_client: AsyncFinch) -> None: async with async_client.jobs.manual.with_streaming_response.retrieve( - "string", + "job_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" diff --git a/tests/api_resources/payroll/test_pay_groups.py b/tests/api_resources/payroll/test_pay_groups.py index 1eeaf7f9..755c263e 100644 --- a/tests/api_resources/payroll/test_pay_groups.py +++ b/tests/api_resources/payroll/test_pay_groups.py @@ -21,14 +21,14 @@ class TestPayGroups: @parametrize def test_method_retrieve(self, client: Finch) -> None: pay_group = client.payroll.pay_groups.retrieve( - "string", + "pay_group_id", ) assert_matches_type(PayGroupRetrieveResponse, pay_group, path=["response"]) @parametrize def test_raw_response_retrieve(self, client: Finch) -> None: response = client.payroll.pay_groups.with_raw_response.retrieve( - "string", + "pay_group_id", ) assert response.is_closed is True @@ -39,7 +39,7 @@ def test_raw_response_retrieve(self, client: Finch) -> None: @parametrize def test_streaming_response_retrieve(self, client: Finch) -> None: with client.payroll.pay_groups.with_streaming_response.retrieve( - "string", + "pay_group_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -96,14 +96,14 @@ class TestAsyncPayGroups: @parametrize async def test_method_retrieve(self, async_client: AsyncFinch) -> None: pay_group = await async_client.payroll.pay_groups.retrieve( - "string", + "pay_group_id", ) assert_matches_type(PayGroupRetrieveResponse, pay_group, path=["response"]) @parametrize async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: response = await async_client.payroll.pay_groups.with_raw_response.retrieve( - "string", + "pay_group_id", ) assert response.is_closed is True @@ -114,7 +114,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_retrieve(self, async_client: AsyncFinch) -> None: async with async_client.payroll.pay_groups.with_streaming_response.retrieve( - "string", + "pay_group_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" diff --git a/tests/api_resources/sandbox/connections/test_accounts.py b/tests/api_resources/sandbox/connections/test_accounts.py index 82058694..0655efff 100644 --- a/tests/api_resources/sandbox/connections/test_accounts.py +++ b/tests/api_resources/sandbox/connections/test_accounts.py @@ -25,7 +25,7 @@ class TestAccounts: def test_method_create(self, client: Finch) -> None: account = client.sandbox.connections.accounts.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", ) assert_matches_type(AccountCreateResponse, account, path=["response"]) @@ -34,7 +34,7 @@ def test_method_create(self, client: Finch) -> None: def test_method_create_with_all_params(self, client: Finch) -> None: account = client.sandbox.connections.accounts.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", authentication_type="credential", products=["string", "string", "string"], ) @@ -45,7 +45,7 @@ def test_method_create_with_all_params(self, client: Finch) -> None: def test_raw_response_create(self, client: Finch) -> None: response = client.sandbox.connections.accounts.with_raw_response.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", ) assert response.is_closed is True @@ -58,7 +58,7 @@ def test_raw_response_create(self, client: Finch) -> None: def test_streaming_response_create(self, client: Finch) -> None: with client.sandbox.connections.accounts.with_streaming_response.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -109,7 +109,7 @@ class TestAsyncAccounts: async def test_method_create(self, async_client: AsyncFinch) -> None: account = await async_client.sandbox.connections.accounts.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", ) assert_matches_type(AccountCreateResponse, account, path=["response"]) @@ -118,7 +118,7 @@ async def test_method_create(self, async_client: AsyncFinch) -> None: async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> None: account = await async_client.sandbox.connections.accounts.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", authentication_type="credential", products=["string", "string", "string"], ) @@ -129,7 +129,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> async def test_raw_response_create(self, async_client: AsyncFinch) -> None: response = await async_client.sandbox.connections.accounts.with_raw_response.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", ) assert response.is_closed is True @@ -142,7 +142,7 @@ async def test_raw_response_create(self, async_client: AsyncFinch) -> None: async def test_streaming_response_create(self, async_client: AsyncFinch) -> None: async with async_client.sandbox.connections.accounts.with_streaming_response.create( company_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", - provider_id="string", + provider_id="provider_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" diff --git a/tests/api_resources/sandbox/test_company.py b/tests/api_resources/sandbox/test_company.py index 4104eb8a..4935c0cb 100644 --- a/tests/api_resources/sandbox/test_company.py +++ b/tests/api_resources/sandbox/test_company.py @@ -22,12 +22,12 @@ def test_method_update(self, client: Finch) -> None: company = client.sandbox.company.update( accounts=[{}, {}, {}], departments=[{}, {}, {}], - ein="string", + ein="ein", entity={}, - legal_name="string", + legal_name="legal_name", locations=[{}, {}, {}], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) assert_matches_type(CompanyUpdateResponse, company, path=["response"]) @@ -36,81 +36,81 @@ def test_method_update_with_all_params(self, client: Finch) -> None: company = client.sandbox.company.update( accounts=[ { - "routing_number": "string", - "account_name": "string", - "institution_name": "string", + "routing_number": "routing_number", + "account_name": "account_name", + "institution_name": "institution_name", "account_type": "checking", - "account_number": "string", + "account_number": "account_number", }, { - "routing_number": "string", - "account_name": "string", - "institution_name": "string", + "routing_number": "routing_number", + "account_name": "account_name", + "institution_name": "institution_name", "account_type": "checking", - "account_number": "string", + "account_number": "account_number", }, { - "routing_number": "string", - "account_name": "string", - "institution_name": "string", + "routing_number": "routing_number", + "account_name": "account_name", + "institution_name": "institution_name", "account_type": "checking", - "account_number": "string", + "account_number": "account_number", }, ], departments=[ { - "name": "string", - "parent": {"name": "string"}, + "name": "name", + "parent": {"name": "name"}, }, { - "name": "string", - "parent": {"name": "string"}, + "name": "name", + "parent": {"name": "name"}, }, { - "name": "string", - "parent": {"name": "string"}, + "name": "name", + "parent": {"name": "name"}, }, ], - ein="string", + ein="ein", entity={ "type": "llc", "subtype": "s_corporation", }, - legal_name="string", + legal_name="legal_name", locations=[ { - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, { - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, { - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, ], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) assert_matches_type(CompanyUpdateResponse, company, path=["response"]) @@ -119,12 +119,12 @@ def test_raw_response_update(self, client: Finch) -> None: response = client.sandbox.company.with_raw_response.update( accounts=[{}, {}, {}], departments=[{}, {}, {}], - ein="string", + ein="ein", entity={}, - legal_name="string", + legal_name="legal_name", locations=[{}, {}, {}], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) assert response.is_closed is True @@ -137,12 +137,12 @@ def test_streaming_response_update(self, client: Finch) -> None: with client.sandbox.company.with_streaming_response.update( accounts=[{}, {}, {}], departments=[{}, {}, {}], - ein="string", + ein="ein", entity={}, - legal_name="string", + legal_name="legal_name", locations=[{}, {}, {}], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -161,12 +161,12 @@ async def test_method_update(self, async_client: AsyncFinch) -> None: company = await async_client.sandbox.company.update( accounts=[{}, {}, {}], departments=[{}, {}, {}], - ein="string", + ein="ein", entity={}, - legal_name="string", + legal_name="legal_name", locations=[{}, {}, {}], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) assert_matches_type(CompanyUpdateResponse, company, path=["response"]) @@ -175,81 +175,81 @@ async def test_method_update_with_all_params(self, async_client: AsyncFinch) -> company = await async_client.sandbox.company.update( accounts=[ { - "routing_number": "string", - "account_name": "string", - "institution_name": "string", + "routing_number": "routing_number", + "account_name": "account_name", + "institution_name": "institution_name", "account_type": "checking", - "account_number": "string", + "account_number": "account_number", }, { - "routing_number": "string", - "account_name": "string", - "institution_name": "string", + "routing_number": "routing_number", + "account_name": "account_name", + "institution_name": "institution_name", "account_type": "checking", - "account_number": "string", + "account_number": "account_number", }, { - "routing_number": "string", - "account_name": "string", - "institution_name": "string", + "routing_number": "routing_number", + "account_name": "account_name", + "institution_name": "institution_name", "account_type": "checking", - "account_number": "string", + "account_number": "account_number", }, ], departments=[ { - "name": "string", - "parent": {"name": "string"}, + "name": "name", + "parent": {"name": "name"}, }, { - "name": "string", - "parent": {"name": "string"}, + "name": "name", + "parent": {"name": "name"}, }, { - "name": "string", - "parent": {"name": "string"}, + "name": "name", + "parent": {"name": "name"}, }, ], - ein="string", + ein="ein", entity={ "type": "llc", "subtype": "s_corporation", }, - legal_name="string", + legal_name="legal_name", locations=[ { - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, { - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, { - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, ], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) assert_matches_type(CompanyUpdateResponse, company, path=["response"]) @@ -258,12 +258,12 @@ async def test_raw_response_update(self, async_client: AsyncFinch) -> None: response = await async_client.sandbox.company.with_raw_response.update( accounts=[{}, {}, {}], departments=[{}, {}, {}], - ein="string", + ein="ein", entity={}, - legal_name="string", + legal_name="legal_name", locations=[{}, {}, {}], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) assert response.is_closed is True @@ -276,12 +276,12 @@ async def test_streaming_response_update(self, async_client: AsyncFinch) -> None async with async_client.sandbox.company.with_streaming_response.update( accounts=[{}, {}, {}], departments=[{}, {}, {}], - ein="string", + ein="ein", entity={}, - legal_name="string", + legal_name="legal_name", locations=[{}, {}, {}], - primary_email="string", - primary_phone_number="string", + primary_email="primary_email", + primary_phone_number="primary_phone_number", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" diff --git a/tests/api_resources/sandbox/test_connections.py b/tests/api_resources/sandbox/test_connections.py index 2cbb0fe0..574747fb 100644 --- a/tests/api_resources/sandbox/test_connections.py +++ b/tests/api_resources/sandbox/test_connections.py @@ -21,7 +21,7 @@ class TestConnections: @parametrize def test_method_create(self, client: Finch) -> None: connection = client.sandbox.connections.create( - provider_id="string", + provider_id="provider_id", ) assert_matches_type(ConnectionCreateResponse, connection, path=["response"]) @@ -29,7 +29,7 @@ def test_method_create(self, client: Finch) -> None: @parametrize def test_method_create_with_all_params(self, client: Finch) -> None: connection = client.sandbox.connections.create( - provider_id="string", + provider_id="provider_id", authentication_type="credential", employee_size=0, products=["string", "string", "string"], @@ -40,7 +40,7 @@ def test_method_create_with_all_params(self, client: Finch) -> None: @parametrize def test_raw_response_create(self, client: Finch) -> None: response = client.sandbox.connections.with_raw_response.create( - provider_id="string", + provider_id="provider_id", ) assert response.is_closed is True @@ -52,7 +52,7 @@ def test_raw_response_create(self, client: Finch) -> None: @parametrize def test_streaming_response_create(self, client: Finch) -> None: with client.sandbox.connections.with_streaming_response.create( - provider_id="string", + provider_id="provider_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -70,7 +70,7 @@ class TestAsyncConnections: @parametrize async def test_method_create(self, async_client: AsyncFinch) -> None: connection = await async_client.sandbox.connections.create( - provider_id="string", + provider_id="provider_id", ) assert_matches_type(ConnectionCreateResponse, connection, path=["response"]) @@ -78,7 +78,7 @@ async def test_method_create(self, async_client: AsyncFinch) -> None: @parametrize async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> None: connection = await async_client.sandbox.connections.create( - provider_id="string", + provider_id="provider_id", authentication_type="credential", employee_size=0, products=["string", "string", "string"], @@ -89,7 +89,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> @parametrize async def test_raw_response_create(self, async_client: AsyncFinch) -> None: response = await async_client.sandbox.connections.with_raw_response.create( - provider_id="string", + provider_id="provider_id", ) assert response.is_closed is True @@ -101,7 +101,7 @@ async def test_raw_response_create(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_create(self, async_client: AsyncFinch) -> None: async with async_client.sandbox.connections.with_streaming_response.create( - provider_id="string", + provider_id="provider_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" diff --git a/tests/api_resources/sandbox/test_employment.py b/tests/api_resources/sandbox/test_employment.py index 7183dac5..6cdca66e 100644 --- a/tests/api_resources/sandbox/test_employment.py +++ b/tests/api_resources/sandbox/test_employment.py @@ -20,86 +20,86 @@ class TestEmployment: @parametrize def test_method_update(self, client: Finch) -> None: employment = client.sandbox.employment.update( - "string", + individual_id="individual_id", ) assert_matches_type(EmploymentUpdateResponse, employment, path=["response"]) @parametrize def test_method_update_with_all_params(self, client: Finch) -> None: employment = client.sandbox.employment.update( - "string", - class_code="string", + individual_id="individual_id", + class_code="class_code", custom_fields=[ { - "name": "string", + "name": "name", "value": {}, }, { - "name": "string", + "name": "name", "value": {}, }, { - "name": "string", + "name": "name", "value": {}, }, ], - department={"name": "string"}, + department={"name": "name"}, employment={ "type": "employee", "subtype": "full_time", }, - end_date="string", - first_name="string", + end_date="end_date", + first_name="first_name", income={ "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, income_history=[ { "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, { "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, { "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, ], is_active=True, - last_name="string", + last_name="last_name", location={ - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, - manager={"id": "string"}, - middle_name="string", - source_id="string", + manager={"id": "id"}, + middle_name="middle_name", + source_id="source_id", start_date="3/4/2020", - title="string", + title="title", ) assert_matches_type(EmploymentUpdateResponse, employment, path=["response"]) @parametrize def test_raw_response_update(self, client: Finch) -> None: response = client.sandbox.employment.with_raw_response.update( - "string", + individual_id="individual_id", ) assert response.is_closed is True @@ -110,7 +110,7 @@ def test_raw_response_update(self, client: Finch) -> None: @parametrize def test_streaming_response_update(self, client: Finch) -> None: with client.sandbox.employment.with_streaming_response.update( - "string", + individual_id="individual_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -124,7 +124,7 @@ def test_streaming_response_update(self, client: Finch) -> None: def test_path_params_update(self, client: Finch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `individual_id` but received ''"): client.sandbox.employment.with_raw_response.update( - "", + individual_id="", ) @@ -134,86 +134,86 @@ class TestAsyncEmployment: @parametrize async def test_method_update(self, async_client: AsyncFinch) -> None: employment = await async_client.sandbox.employment.update( - "string", + individual_id="individual_id", ) assert_matches_type(EmploymentUpdateResponse, employment, path=["response"]) @parametrize async def test_method_update_with_all_params(self, async_client: AsyncFinch) -> None: employment = await async_client.sandbox.employment.update( - "string", - class_code="string", + individual_id="individual_id", + class_code="class_code", custom_fields=[ { - "name": "string", + "name": "name", "value": {}, }, { - "name": "string", + "name": "name", "value": {}, }, { - "name": "string", + "name": "name", "value": {}, }, ], - department={"name": "string"}, + department={"name": "name"}, employment={ "type": "employee", "subtype": "full_time", }, - end_date="string", - first_name="string", + end_date="end_date", + first_name="first_name", income={ "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, income_history=[ { "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, { "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, { "unit": "yearly", "amount": 0, - "currency": "string", - "effective_date": "string", + "currency": "currency", + "effective_date": "effective_date", }, ], is_active=True, - last_name="string", + last_name="last_name", location={ - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, - manager={"id": "string"}, - middle_name="string", - source_id="string", + manager={"id": "id"}, + middle_name="middle_name", + source_id="source_id", start_date="3/4/2020", - title="string", + title="title", ) assert_matches_type(EmploymentUpdateResponse, employment, path=["response"]) @parametrize async def test_raw_response_update(self, async_client: AsyncFinch) -> None: response = await async_client.sandbox.employment.with_raw_response.update( - "string", + individual_id="individual_id", ) assert response.is_closed is True @@ -224,7 +224,7 @@ async def test_raw_response_update(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_update(self, async_client: AsyncFinch) -> None: async with async_client.sandbox.employment.with_streaming_response.update( - "string", + individual_id="individual_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -238,5 +238,5 @@ async def test_streaming_response_update(self, async_client: AsyncFinch) -> None async def test_path_params_update(self, async_client: AsyncFinch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `individual_id` but received ''"): await async_client.sandbox.employment.with_raw_response.update( - "", + individual_id="", ) diff --git a/tests/api_resources/sandbox/test_individual.py b/tests/api_resources/sandbox/test_individual.py index 5d8f0683..4bd79d3e 100644 --- a/tests/api_resources/sandbox/test_individual.py +++ b/tests/api_resources/sandbox/test_individual.py @@ -20,68 +20,68 @@ class TestIndividual: @parametrize def test_method_update(self, client: Finch) -> None: individual = client.sandbox.individual.update( - "string", + individual_id="individual_id", ) assert_matches_type(IndividualUpdateResponse, individual, path=["response"]) @parametrize def test_method_update_with_all_params(self, client: Finch) -> None: individual = client.sandbox.individual.update( - "string", + individual_id="individual_id", dob="12/20/1989", emails=[ { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, ], - encrypted_ssn="string", + encrypted_ssn="encrypted_ssn", ethnicity="asian", - first_name="string", + first_name="first_name", gender="female", - last_name="string", - middle_name="string", + last_name="last_name", + middle_name="middle_name", phone_numbers=[ { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, ], - preferred_name="string", + preferred_name="preferred_name", residence={ - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, - ssn="string", + ssn="ssn", ) assert_matches_type(IndividualUpdateResponse, individual, path=["response"]) @parametrize def test_raw_response_update(self, client: Finch) -> None: response = client.sandbox.individual.with_raw_response.update( - "string", + individual_id="individual_id", ) assert response.is_closed is True @@ -92,7 +92,7 @@ def test_raw_response_update(self, client: Finch) -> None: @parametrize def test_streaming_response_update(self, client: Finch) -> None: with client.sandbox.individual.with_streaming_response.update( - "string", + individual_id="individual_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -106,7 +106,7 @@ def test_streaming_response_update(self, client: Finch) -> None: def test_path_params_update(self, client: Finch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `individual_id` but received ''"): client.sandbox.individual.with_raw_response.update( - "", + individual_id="", ) @@ -116,68 +116,68 @@ class TestAsyncIndividual: @parametrize async def test_method_update(self, async_client: AsyncFinch) -> None: individual = await async_client.sandbox.individual.update( - "string", + individual_id="individual_id", ) assert_matches_type(IndividualUpdateResponse, individual, path=["response"]) @parametrize async def test_method_update_with_all_params(self, async_client: AsyncFinch) -> None: individual = await async_client.sandbox.individual.update( - "string", + individual_id="individual_id", dob="12/20/1989", emails=[ { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, ], - encrypted_ssn="string", + encrypted_ssn="encrypted_ssn", ethnicity="asian", - first_name="string", + first_name="first_name", gender="female", - last_name="string", - middle_name="string", + last_name="last_name", + middle_name="middle_name", phone_numbers=[ { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, { - "data": "string", + "data": "data", "type": "work", }, ], - preferred_name="string", + preferred_name="preferred_name", residence={ - "line1": "string", - "line2": "string", - "city": "string", - "state": "string", - "postal_code": "string", - "country": "string", - "name": "string", - "source_id": "string", + "line1": "line1", + "line2": "line2", + "city": "city", + "state": "state", + "postal_code": "postal_code", + "country": "country", + "name": "name", + "source_id": "source_id", }, - ssn="string", + ssn="ssn", ) assert_matches_type(IndividualUpdateResponse, individual, path=["response"]) @parametrize async def test_raw_response_update(self, async_client: AsyncFinch) -> None: response = await async_client.sandbox.individual.with_raw_response.update( - "string", + individual_id="individual_id", ) assert response.is_closed is True @@ -188,7 +188,7 @@ async def test_raw_response_update(self, async_client: AsyncFinch) -> None: @parametrize async def test_streaming_response_update(self, async_client: AsyncFinch) -> None: async with async_client.sandbox.individual.with_streaming_response.update( - "string", + individual_id="individual_id", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -202,5 +202,5 @@ async def test_streaming_response_update(self, async_client: AsyncFinch) -> None async def test_path_params_update(self, async_client: AsyncFinch) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `individual_id` but received ''"): await async_client.sandbox.individual.with_raw_response.update( - "", + individual_id="", ) diff --git a/tests/api_resources/sandbox/test_payment.py b/tests/api_resources/sandbox/test_payment.py index 9b0c803a..5f1c5356 100644 --- a/tests/api_resources/sandbox/test_payment.py +++ b/tests/api_resources/sandbox/test_payment.py @@ -25,7 +25,7 @@ def test_method_create(self, client: Finch) -> None: @parametrize def test_method_create_with_all_params(self, client: Finch) -> None: payment = client.sandbox.payment.create( - end_date="string", + end_date="end_date", pay_statements=[ { "individual_id": "b2338cfb-472f-4f72-9faa-e028c083144a", @@ -34,56 +34,56 @@ def test_method_create_with_all_params(self, client: Finch) -> None: "total_hours": 0, "gross_pay": { "amount": 0, - "currency": "string", + "currency": "currency", }, "net_pay": { "amount": 0, - "currency": "string", + "currency": "currency", }, "earnings": [ { "type": "salary", - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "hours": 0, }, { "type": "salary", - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "hours": 0, }, { "type": "salary", - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "hours": 0, }, ], "taxes": [ { "type": "state", - "name": "string", + "name": "name", "employer": True, "amount": 0, - "currency": "string", + "currency": "currency", }, { "type": "state", - "name": "string", + "name": "name", "employer": True, "amount": 0, - "currency": "string", + "currency": "currency", }, { "type": "state", - "name": "string", + "name": "name", "employer": True, "amount": 0, - "currency": "string", + "currency": "currency", }, ], "employee_deductions": [ @@ -97,27 +97,27 @@ def test_method_create_with_all_params(self, client: Finch) -> None: ], "employer_contributions": [ { - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "type": "401k", }, { - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "type": "401k", }, { - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "type": "401k", }, ], } ], - start_date="string", + start_date="start_date", ) assert_matches_type(PaymentCreateResponse, payment, path=["response"]) @@ -153,7 +153,7 @@ async def test_method_create(self, async_client: AsyncFinch) -> None: @parametrize async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> None: payment = await async_client.sandbox.payment.create( - end_date="string", + end_date="end_date", pay_statements=[ { "individual_id": "b2338cfb-472f-4f72-9faa-e028c083144a", @@ -162,56 +162,56 @@ async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> "total_hours": 0, "gross_pay": { "amount": 0, - "currency": "string", + "currency": "currency", }, "net_pay": { "amount": 0, - "currency": "string", + "currency": "currency", }, "earnings": [ { "type": "salary", - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "hours": 0, }, { "type": "salary", - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "hours": 0, }, { "type": "salary", - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "hours": 0, }, ], "taxes": [ { "type": "state", - "name": "string", + "name": "name", "employer": True, "amount": 0, - "currency": "string", + "currency": "currency", }, { "type": "state", - "name": "string", + "name": "name", "employer": True, "amount": 0, - "currency": "string", + "currency": "currency", }, { "type": "state", - "name": "string", + "name": "name", "employer": True, "amount": 0, - "currency": "string", + "currency": "currency", }, ], "employee_deductions": [ @@ -225,27 +225,27 @@ async def test_method_create_with_all_params(self, async_client: AsyncFinch) -> ], "employer_contributions": [ { - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "type": "401k", }, { - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "type": "401k", }, { - "name": "string", + "name": "name", "amount": 0, - "currency": "string", + "currency": "currency", "type": "401k", }, ], } ], - start_date="string", + start_date="start_date", ) assert_matches_type(PaymentCreateResponse, payment, path=["response"])