99
1010from courier import Courier , AsyncCourier
1111from tests .utils import assert_matches_type
12- from courier .types import SendSendMessageResponse
12+ from courier .types import SendMessageResponse
1313
1414base_url = os .environ .get ("TEST_API_BASE_URL" , "http://127.0.0.1:4010" )
1515
@@ -19,21 +19,21 @@ class TestSend:
1919
2020 @pytest .mark .skip (reason = "Prism tests are disabled" )
2121 @parametrize
22- def test_method_send_message (self , client : Courier ) -> None :
23- send = client .send .send_message (
22+ def test_method_message (self , client : Courier ) -> None :
23+ send = client .send .message (
2424 message = {
2525 "content" : {
2626 "elements" : [{}],
2727 "version" : "version" ,
2828 }
2929 },
3030 )
31- assert_matches_type (SendSendMessageResponse , send , path = ["response" ])
31+ assert_matches_type (SendMessageResponse , send , path = ["response" ])
3232
3333 @pytest .mark .skip (reason = "Prism tests are disabled" )
3434 @parametrize
35- def test_raw_response_send_message (self , client : Courier ) -> None :
36- response = client .send .with_raw_response .send_message (
35+ def test_raw_response_message (self , client : Courier ) -> None :
36+ response = client .send .with_raw_response .message (
3737 message = {
3838 "content" : {
3939 "elements" : [{}],
@@ -45,12 +45,12 @@ def test_raw_response_send_message(self, client: Courier) -> None:
4545 assert response .is_closed is True
4646 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
4747 send = response .parse ()
48- assert_matches_type (SendSendMessageResponse , send , path = ["response" ])
48+ assert_matches_type (SendMessageResponse , send , path = ["response" ])
4949
5050 @pytest .mark .skip (reason = "Prism tests are disabled" )
5151 @parametrize
52- def test_streaming_response_send_message (self , client : Courier ) -> None :
53- with client .send .with_streaming_response .send_message (
52+ def test_streaming_response_message (self , client : Courier ) -> None :
53+ with client .send .with_streaming_response .message (
5454 message = {
5555 "content" : {
5656 "elements" : [{}],
@@ -62,7 +62,7 @@ def test_streaming_response_send_message(self, client: Courier) -> None:
6262 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
6363
6464 send = response .parse ()
65- assert_matches_type (SendSendMessageResponse , send , path = ["response" ])
65+ assert_matches_type (SendMessageResponse , send , path = ["response" ])
6666
6767 assert cast (Any , response .is_closed ) is True
6868
@@ -74,21 +74,21 @@ class TestAsyncSend:
7474
7575 @pytest .mark .skip (reason = "Prism tests are disabled" )
7676 @parametrize
77- async def test_method_send_message (self , async_client : AsyncCourier ) -> None :
78- send = await async_client .send .send_message (
77+ async def test_method_message (self , async_client : AsyncCourier ) -> None :
78+ send = await async_client .send .message (
7979 message = {
8080 "content" : {
8181 "elements" : [{}],
8282 "version" : "version" ,
8383 }
8484 },
8585 )
86- assert_matches_type (SendSendMessageResponse , send , path = ["response" ])
86+ assert_matches_type (SendMessageResponse , send , path = ["response" ])
8787
8888 @pytest .mark .skip (reason = "Prism tests are disabled" )
8989 @parametrize
90- async def test_raw_response_send_message (self , async_client : AsyncCourier ) -> None :
91- response = await async_client .send .with_raw_response .send_message (
90+ async def test_raw_response_message (self , async_client : AsyncCourier ) -> None :
91+ response = await async_client .send .with_raw_response .message (
9292 message = {
9393 "content" : {
9494 "elements" : [{}],
@@ -100,12 +100,12 @@ async def test_raw_response_send_message(self, async_client: AsyncCourier) -> No
100100 assert response .is_closed is True
101101 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
102102 send = await response .parse ()
103- assert_matches_type (SendSendMessageResponse , send , path = ["response" ])
103+ assert_matches_type (SendMessageResponse , send , path = ["response" ])
104104
105105 @pytest .mark .skip (reason = "Prism tests are disabled" )
106106 @parametrize
107- async def test_streaming_response_send_message (self , async_client : AsyncCourier ) -> None :
108- async with async_client .send .with_streaming_response .send_message (
107+ async def test_streaming_response_message (self , async_client : AsyncCourier ) -> None :
108+ async with async_client .send .with_streaming_response .message (
109109 message = {
110110 "content" : {
111111 "elements" : [{}],
@@ -117,6 +117,6 @@ async def test_streaming_response_send_message(self, async_client: AsyncCourier)
117117 assert response .http_request .headers .get ("X-Stainless-Lang" ) == "python"
118118
119119 send = await response .parse ()
120- assert_matches_type (SendSendMessageResponse , send , path = ["response" ])
120+ assert_matches_type (SendMessageResponse , send , path = ["response" ])
121121
122122 assert cast (Any , response .is_closed ) is True
0 commit comments