Skip to content

Commit

Permalink
Rename available_models to models
Browse files Browse the repository at this point in the history
  • Loading branch information
ahartel committed Feb 13, 2023
1 parent 06c97e9 commit 001615b
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions aleph_alpha_client/aleph_alpha_client.py
Original file line number Diff line number Diff line change
Expand Up @@ -943,7 +943,7 @@ def _build_json_body(
json_body["hosting"] = self.hosting
return json_body

def available_models(self):
def models(self):
"""
Queries all models which are currently available.
"""
Expand Down Expand Up @@ -1400,7 +1400,7 @@ def _build_json_body(
json_body["hosting"] = self.hosting
return json_body

async def available_models(self):
async def models(self):
"""
Queries all models which are currently available.
"""
Expand Down
4 changes: 2 additions & 2 deletions tests/test_clients.py
Original file line number Diff line number Diff line change
Expand Up @@ -65,13 +65,13 @@ async def test_nice_flag_on_async_client(httpserver: HTTPServer):

@pytest.mark.system_test
def test_available_models_sync_client(sync_client: Client, model_name: str):
models = sync_client.available_models()
models = sync_client.models()
assert model_name in [model["name"] for model in models]


@pytest.mark.system_test
async def test_available_models_async_client(
async_client: AsyncClient, model_name: str
):
models = await async_client.available_models()
models = await async_client.models()
assert model_name in [model["name"] for model in models]

0 comments on commit 001615b

Please sign in to comment.