Skip to content

Commit 96d7871

Browse files
committed
update tests
1 parent 0ebe097 commit 96d7871

2 files changed

Lines changed: 6 additions & 6 deletions

File tree

tests/client/test_create_brancher.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from unittest.mock import Mock
33

44
from hypernode_api_python.client import (
5-
HYPERNODE_API_APP_BRANCHER_ENDPOINT,
5+
HYPERNODE_API_BRANCHER_APP_ENDPOINT,
66
HypernodeAPIPython,
77
)
88

@@ -15,14 +15,14 @@ def setUp(self):
1515
self.app_name = "my_app"
1616

1717
def test_brancher_endpoint_is_correct(self):
18-
self.assertEqual("/v2/app/{}/brancher/", HYPERNODE_API_APP_BRANCHER_ENDPOINT)
18+
self.assertEqual("/v2/brancher/app/{}/", HYPERNODE_API_BRANCHER_APP_ENDPOINT)
1919

2020
def test_calls_create_brancher_endpoint_properly(self):
2121
data = {"clear_services": ["mysql"]}
2222
self.client.create_brancher(self.app_name, data)
2323

2424
self.mock_request.assert_called_once_with(
25-
"POST", f"/v2/app/{self.app_name}/brancher/", data=data
25+
"POST", f"/v2/brancher/app/{self.app_name}/", data=data
2626
)
2727

2828
def test_returns_create_brancher_data(self):

tests/client/test_get_active_branchers.py

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
from unittest.mock import Mock
33

44
from hypernode_api_python.client import (
5-
HYPERNODE_API_APP_BRANCHER_ENDPOINT,
5+
HYPERNODE_API_BRANCHER_APP_ENDPOINT,
66
HypernodeAPIPython,
77
)
88

@@ -15,13 +15,13 @@ def setUp(self):
1515
self.app_name = "my_app"
1616

1717
def test_brancher_endpoint_is_correct(self):
18-
self.assertEqual("/v2/app/{}/brancher/", HYPERNODE_API_APP_BRANCHER_ENDPOINT)
18+
self.assertEqual("/v2/brancher/app/{}/", HYPERNODE_API_BRANCHER_APP_ENDPOINT)
1919

2020
def test_calls_get_active_branchers_endpoint_properly(self):
2121
self.client.get_active_branchers(self.app_name)
2222

2323
self.mock_request.assert_called_once_with(
24-
"GET", f"/v2/app/{self.app_name}/brancher/"
24+
"GET", f"/v2/brancher/app/{self.app_name}/"
2525
)
2626

2727
def test_returns_active_branchers_data(self):

0 commit comments

Comments
 (0)