diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 6b82df1..5100e6d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -19,7 +19,7 @@ jobs: runs-on: ${{ github.repository == 'stainless-sdks/coingecko-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - name: Install Rye run: | @@ -44,7 +44,7 @@ jobs: id-token: write runs-on: ${{ github.repository == 'stainless-sdks/coingecko-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }} steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - name: Install Rye run: | @@ -63,7 +63,7 @@ jobs: - name: Get GitHub OIDC Token if: github.repository == 'stainless-sdks/coingecko-python' id: github-oidc - uses: actions/github-script@v6 + uses: actions/github-script@v8 with: script: core.setOutput('github_token', await core.getIDToken()); @@ -81,7 +81,7 @@ jobs: runs-on: ${{ github.repository == 'stainless-sdks/coingecko-python' && 'depot-ubuntu-24.04' || 'ubuntu-latest' }} if: github.event_name == 'push' || github.event.pull_request.head.repo.fork steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - name: Install Rye run: | diff --git a/.github/workflows/publish-pypi.yml b/.github/workflows/publish-pypi.yml index 16b2b94..17a446e 100644 --- a/.github/workflows/publish-pypi.yml +++ b/.github/workflows/publish-pypi.yml @@ -14,7 +14,7 @@ jobs: runs-on: ubuntu-latest steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - name: Install Rye run: | diff --git a/.github/workflows/release-doctor.yml b/.github/workflows/release-doctor.yml index d8c14af..426bbe4 100644 --- a/.github/workflows/release-doctor.yml +++ b/.github/workflows/release-doctor.yml @@ -12,7 +12,7 @@ jobs: if: github.repository == 'coingecko/coingecko-python' && (github.event_name == 'push' || github.event_name == 'workflow_dispatch' || startsWith(github.head_ref, 'release-please') || github.head_ref == 'next') steps: - - uses: actions/checkout@v4 + - uses: actions/checkout@v6 - name: Check release environment run: | diff --git a/.release-please-manifest.json b/.release-please-manifest.json index de0960a..f94eeca 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "1.12.0" + ".": "1.13.0" } \ No newline at end of file diff --git a/.stats.yml b/.stats.yml index f25cd48..9370ce5 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ configured_endpoints: 84 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/coingecko%2Fcoingecko-a23494dedfc230f769076f4022de83a327d642db68ceadedf998921c66ff9310.yml -openapi_spec_hash: 0bcc6962d4ee8f39880019986e87e433 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/coingecko%2Fcoingecko-e88de4e81cdb0547e40a951e747c95e7a9647577d8bee0ce5c5b4643a939ed3f.yml +openapi_spec_hash: d3b574a0f909b96fd93f1f46a2f8efde config_hash: f101f417dba7f9352f7573639dd5938f diff --git a/CHANGELOG.md b/CHANGELOG.md index a7d363e..458ba75 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,39 @@ # Changelog +## 1.13.0 (2026-02-25) + +Full Changelog: [v1.12.0...v1.13.0](https://github.com/coingecko/coingecko-python/compare/v1.12.0...v1.13.0) + +### Features + +* **api:** api update ([0241244](https://github.com/coingecko/coingecko-python/commit/02412444ad3bbc58bbec8f16c4e3e18d84ac3969)) +* **api:** api update ([8436976](https://github.com/coingecko/coingecko-python/commit/84369760ef357df8e4feb0285263b7896d081948)) +* **client:** add custom JSON encoder for extended type support ([dad7856](https://github.com/coingecko/coingecko-python/commit/dad7856f521034641be1af22a9de396d5b3816ff)) +* **client:** add support for binary request streaming ([a9f1aa3](https://github.com/coingecko/coingecko-python/commit/a9f1aa33c8765610d03550e5721b0279d172d273)) +* **client:** support file upload requests ([9d2d8ee](https://github.com/coingecko/coingecko-python/commit/9d2d8ee494cfaf60ed0bcc9a7b6b4e7b0cff30d5)) + + +### Bug Fixes + +* **client:** loosen auth header validation ([eafba80](https://github.com/coingecko/coingecko-python/commit/eafba8079e34ec10de0153950de8d6637c1d422a)) +* **docs:** fix mcp installation instructions for remote servers ([62c08fb](https://github.com/coingecko/coingecko-python/commit/62c08fb291eab975560ce0d0e055a5b88fc7029d)) + + +### Chores + +* **ci:** upgrade `actions/github-script` ([4e83c98](https://github.com/coingecko/coingecko-python/commit/4e83c9866f46c4f1b695ac83e566e5d04fdbea77)) +* format all `api.md` files ([94bf810](https://github.com/coingecko/coingecko-python/commit/94bf810205db49812c2bbbe25f3018a2ac228170)) +* **internal:** add `--fix` argument to lint script ([0a4e127](https://github.com/coingecko/coingecko-python/commit/0a4e127596bee226b220890acc706e6782d553ab)) +* **internal:** bump dependencies ([369ba5d](https://github.com/coingecko/coingecko-python/commit/369ba5d99e285c3ac88ef80c193c7563769c36be)) +* **internal:** codegen related update ([cc420eb](https://github.com/coingecko/coingecko-python/commit/cc420ebc39f9ab254ef2be16bf065fc513fcd2d3)) +* **internal:** fix lint error on Python 3.14 ([9134bbc](https://github.com/coingecko/coingecko-python/commit/9134bbc5b7ca8c752e677aec2eb84fc1b627409f)) +* **internal:** update `actions/checkout` version ([f633c5e](https://github.com/coingecko/coingecko-python/commit/f633c5ef5aa1daf0ce6c05efd058571099e1cc06)) + + +### Documentation + +* prominently feature MCP server setup in root SDK readmes ([10cb284](https://github.com/coingecko/coingecko-python/commit/10cb284cf8300229a26c6816a737ba772870d7aa)) + ## 1.12.0 (2025-12-18) Full Changelog: [v1.11.3...v1.12.0](https://github.com/coingecko/coingecko-python/compare/v1.11.3...v1.12.0) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 1a268cf..df2591c 100644 --- a/CONTRIBUTING.md +++ b/CONTRIBUTING.md @@ -85,13 +85,6 @@ $ pip install ./path-to-wheel-file.whl ## Running tests -Most tests require you to [set up a mock server](https://github.com/stoplightio/prism) against the OpenAPI spec to run the tests. - -```sh -# you will need npm installed -$ npx prism mock path/to/your/openapi.yml -``` - ```sh $ ./scripts/test ``` diff --git a/LICENSE b/LICENSE index ce817c7..258ea35 100644 --- a/LICENSE +++ b/LICENSE @@ -186,7 +186,7 @@ same "printed page" as the copyright notice for easier identification within third-party archives. - Copyright 2025 Coingecko + Copyright 2026 Coingecko Licensed under the Apache License, Version 2.0 (the "License"); you may not use this file except in compliance with the License. diff --git a/README.md b/README.md index 6979668..ceab966 100644 --- a/README.md +++ b/README.md @@ -9,6 +9,15 @@ and offers both synchronous and asynchronous clients powered by [httpx](https:// It is generated with [Stainless](https://www.stainless.com/). +## MCP Server + +Use the Coingecko MCP Server to enable AI assistants to interact with this API, allowing them to explore endpoints, make test requests, and use documentation to help integrate this SDK into your application. + +[![Add to Cursor](https://cursor.com/deeplink/mcp-install-dark.svg)](https://cursor.com/en-US/install-mcp?name=%40coingecko%2Fcoingecko-mcp&config=eyJjb21tYW5kIjoibnB4IiwiYXJncyI6WyIteSIsIkBjb2luZ2Vja28vY29pbmdlY2tvLW1jcCJdLCJlbnYiOnsiQ09JTkdFQ0tPX1BST19BUElfS0VZIjoiTXkgUHJvIEFQSSBLZXkiLCJDT0lOR0VDS09fREVNT19BUElfS0VZIjoiTXkgRGVtbyBBUEkgS2V5In19) +[![Install in VS Code](https://img.shields.io/badge/_-Add_to_VS_Code-blue?style=for-the-badge&logo=data:image/svg%2bxml;base64,PHN2ZyB4bWxucz0iaHR0cDovL3d3dy53My5vcmcvMjAwMC9zdmciIGZpbGw9Im5vbmUiIHZpZXdCb3g9IjAgMCA0MCA0MCI+PHBhdGggZmlsbD0iI0VFRSIgZmlsbC1ydWxlPSJldmVub2RkIiBkPSJNMzAuMjM1IDM5Ljg4NGEyLjQ5MSAyLjQ5MSAwIDAgMS0xLjc4MS0uNzNMMTIuNyAyNC43OGwtMy40NiAyLjYyNC0zLjQwNiAyLjU4MmExLjY2NSAxLjY2NSAwIDAgMS0xLjA4Mi4zMzggMS42NjQgMS42NjQgMCAwIDEtMS4wNDYtLjQzMWwtMi4yLTJhMS42NjYgMS42NjYgMCAwIDEgMC0yLjQ2M0w3LjQ1OCAyMCA0LjY3IDE3LjQ1MyAxLjUwNyAxNC41N2ExLjY2NSAxLjY2NSAwIDAgMSAwLTIuNDYzbDIuMi0yYTEuNjY1IDEuNjY1IDAgMCAxIDIuMTMtLjA5N2w2Ljg2MyA1LjIwOUwyOC40NTIuODQ0YTIuNDg4IDIuNDg4IDAgMCAxIDEuODQxLS43MjljLjM1MS4wMDkuNjk5LjA5MSAxLjAxOS4yNDVsOC4yMzYgMy45NjFhMi41IDIuNSAwIDAgMSAxLjQxNSAyLjI1M3YuMDk5LS4wNDVWMzMuMzd2LS4wNDUuMDk1YTIuNTAxIDIuNTAxIDAgMCAxLTEuNDE2IDIuMjU3bC04LjIzNSAzLjk2MWEyLjQ5MiAyLjQ5MiAwIDAgMS0xLjA3Ny4yNDZabS43MTYtMjguOTQ3LTExLjk0OCA5LjA2MiAxMS45NTIgOS4wNjUtLjAwNC0xOC4xMjdaIi8+PC9zdmc+)](https://vscode.stainless.com/mcp/%7B%22name%22%3A%22%40coingecko%2Fcoingecko-mcp%22%2C%22command%22%3A%22npx%22%2C%22args%22%3A%5B%22-y%22%2C%22%40coingecko%2Fcoingecko-mcp%22%5D%2C%22env%22%3A%7B%22COINGECKO_PRO_API_KEY%22%3A%22My%20Pro%20API%20Key%22%2C%22COINGECKO_DEMO_API_KEY%22%3A%22My%20Demo%20API%20Key%22%7D%7D) + +> Note: You may need to set environment variables in your MCP client. + ## Documentation The REST API documentation can be found on [docs.coingecko.com](https://docs.coingecko.com). The full API of this library can be found in [api.md](api.md). diff --git a/api.md b/api.md index 8bd9490..78b0814 100644 --- a/api.md +++ b/api.md @@ -714,8 +714,8 @@ from coingecko_sdk.types import ( Methods: -- client.public_treasury.get_coin_id(coin_id, \*, entity) -> PublicTreasuryGetCoinIDResponse -- client.public_treasury.get_entity_id(entity_id) -> PublicTreasuryGetEntityIDResponse +- client.public_treasury.get_coin_id(coin_id, \*, entity, \*\*params) -> PublicTreasuryGetCoinIDResponse +- client.public_treasury.get_entity_id(entity_id, \*\*params) -> PublicTreasuryGetEntityIDResponse - client.public_treasury.get_holding_chart(coin_id, \*, entity_id, \*\*params) -> PublicTreasuryGetHoldingChartResponse - client.public_treasury.get_transaction_history(entity_id, \*\*params) -> PublicTreasuryGetTransactionHistoryResponse diff --git a/pyproject.toml b/pyproject.toml index 9ac0b5b..1b9f459 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "coingecko_sdk" -version = "1.12.0" +version = "1.13.0" description = "The official Python library for the coingecko API" dynamic = ["readme"] license = "Apache-2.0" @@ -69,7 +69,7 @@ format = { chain = [ # run formatting again to fix any inconsistencies when imports are stripped "format:ruff", ]} -"format:docs" = "python scripts/utils/ruffen-docs.py README.md api.md" +"format:docs" = "bash -c 'python scripts/utils/ruffen-docs.py README.md $(find . -type f -name api.md)'" "format:ruff" = "ruff format" "lint" = { chain = [ diff --git a/requirements-dev.lock b/requirements-dev.lock index 57b695c..68d96f0 100644 --- a/requirements-dev.lock +++ b/requirements-dev.lock @@ -12,14 +12,14 @@ -e file:. aiohappyeyeballs==2.6.1 # via aiohttp -aiohttp==3.13.2 +aiohttp==3.13.3 # via coingecko-sdk # via httpx-aiohttp aiosignal==1.4.0 # via aiohttp annotated-types==0.7.0 # via pydantic -anyio==4.12.0 +anyio==4.12.1 # via coingecko-sdk # via httpx argcomplete==3.6.3 @@ -31,7 +31,7 @@ attrs==25.4.0 # via nox backports-asyncio-runner==1.2.0 # via pytest-asyncio -certifi==2025.11.12 +certifi==2026.1.4 # via httpcore # via httpx colorlog==6.10.1 @@ -61,7 +61,7 @@ httpx==0.28.1 # via coingecko-sdk # via httpx-aiohttp # via respx -httpx-aiohttp==0.1.9 +httpx-aiohttp==0.1.12 # via coingecko-sdk humanize==4.13.0 # via nox @@ -69,7 +69,7 @@ idna==3.11 # via anyio # via httpx # via yarl -importlib-metadata==8.7.0 +importlib-metadata==8.7.1 iniconfig==2.1.0 # via pytest markdown-it-py==3.0.0 @@ -82,14 +82,14 @@ multidict==6.7.0 mypy==1.17.0 mypy-extensions==1.1.0 # via mypy -nodeenv==1.9.1 +nodeenv==1.10.0 # via pyright nox==2025.11.12 packaging==25.0 # via dependency-groups # via nox # via pytest -pathspec==0.12.1 +pathspec==1.0.3 # via mypy platformdirs==4.4.0 # via virtualenv @@ -115,13 +115,13 @@ python-dateutil==2.9.0.post0 # via time-machine respx==0.22.0 rich==14.2.0 -ruff==0.14.7 +ruff==0.14.13 six==1.17.0 # via python-dateutil sniffio==1.3.1 # via coingecko-sdk time-machine==2.19.0 -tomli==2.3.0 +tomli==2.4.0 # via dependency-groups # via mypy # via nox @@ -141,7 +141,7 @@ typing-extensions==4.15.0 # via virtualenv typing-inspection==0.4.2 # via pydantic -virtualenv==20.35.4 +virtualenv==20.36.1 # via nox yarl==1.22.0 # via aiohttp diff --git a/requirements.lock b/requirements.lock index 7657fcd..942e192 100644 --- a/requirements.lock +++ b/requirements.lock @@ -12,21 +12,21 @@ -e file:. aiohappyeyeballs==2.6.1 # via aiohttp -aiohttp==3.13.2 +aiohttp==3.13.3 # via coingecko-sdk # via httpx-aiohttp aiosignal==1.4.0 # via aiohttp annotated-types==0.7.0 # via pydantic -anyio==4.12.0 +anyio==4.12.1 # via coingecko-sdk # via httpx async-timeout==5.0.1 # via aiohttp attrs==25.4.0 # via aiohttp -certifi==2025.11.12 +certifi==2026.1.4 # via httpcore # via httpx distro==1.9.0 @@ -43,7 +43,7 @@ httpcore==1.0.9 httpx==0.28.1 # via coingecko-sdk # via httpx-aiohttp -httpx-aiohttp==0.1.9 +httpx-aiohttp==0.1.12 # via coingecko-sdk idna==3.11 # via anyio diff --git a/scripts/lint b/scripts/lint index c275f19..e33efb6 100755 --- a/scripts/lint +++ b/scripts/lint @@ -4,8 +4,13 @@ set -e cd "$(dirname "$0")/.." -echo "==> Running lints" -rye run lint +if [ "$1" = "--fix" ]; then + echo "==> Running lints with --fix" + rye run fix:ruff +else + echo "==> Running lints" + rye run lint +fi echo "==> Making sure it imports" rye run python -c 'import coingecko_sdk' diff --git a/scripts/mock b/scripts/mock deleted file mode 100755 index 0b28f6e..0000000 --- a/scripts/mock +++ /dev/null @@ -1,41 +0,0 @@ -#!/usr/bin/env bash - -set -e - -cd "$(dirname "$0")/.." - -if [[ -n "$1" && "$1" != '--'* ]]; then - URL="$1" - shift -else - URL="$(grep 'openapi_spec_url' .stats.yml | cut -d' ' -f2)" -fi - -# Check if the URL is empty -if [ -z "$URL" ]; then - echo "Error: No OpenAPI spec path/url provided or found in .stats.yml" - exit 1 -fi - -echo "==> Starting mock server with URL ${URL}" - -# Run prism mock on the given spec -if [ "$1" == "--daemon" ]; then - npm exec --package=@stainless-api/prism-cli@5.15.0 -- prism mock "$URL" &> .prism.log & - - # Wait for server to come online - echo -n "Waiting for server" - while ! grep -q "✖ fatal\|Prism is listening" ".prism.log" ; do - echo -n "." - sleep 0.1 - done - - if grep -q "✖ fatal" ".prism.log"; then - cat .prism.log - exit 1 - fi - - echo -else - npm exec --package=@stainless-api/prism-cli@5.15.0 -- prism mock "$URL" -fi diff --git a/scripts/test b/scripts/test index dbeda2d..39729d0 100755 --- a/scripts/test +++ b/scripts/test @@ -4,53 +4,7 @@ set -e cd "$(dirname "$0")/.." -RED='\033[0;31m' -GREEN='\033[0;32m' -YELLOW='\033[0;33m' -NC='\033[0m' # No Color -function prism_is_running() { - curl --silent "http://localhost:4010" >/dev/null 2>&1 -} - -kill_server_on_port() { - pids=$(lsof -t -i tcp:"$1" || echo "") - if [ "$pids" != "" ]; then - kill "$pids" - echo "Stopped $pids." - fi -} - -function is_overriding_api_base_url() { - [ -n "$TEST_API_BASE_URL" ] -} - -if ! is_overriding_api_base_url && ! prism_is_running ; then - # When we exit this script, make sure to kill the background mock server process - trap 'kill_server_on_port 4010' EXIT - - # Start the dev server - ./scripts/mock --daemon -fi - -if is_overriding_api_base_url ; then - echo -e "${GREEN}✔ Running tests against ${TEST_API_BASE_URL}${NC}" - echo -elif ! prism_is_running ; then - echo -e "${RED}ERROR:${NC} The test suite will not run without a mock Prism server" - echo -e "running against your OpenAPI spec." - echo - echo -e "To run the server, pass in the path or url of your OpenAPI" - echo -e "spec to the prism command:" - echo - echo -e " \$ ${YELLOW}npm exec --package=@stainless-api/prism-cli@5.15.0 -- prism mock path/to/your.openapi.yml${NC}" - echo - - exit 1 -else - echo -e "${GREEN}✔ Mock prism server is running with your OpenAPI spec${NC}" - echo -fi export DEFER_PYDANTIC_BUILD=false diff --git a/src/coingecko_sdk/_base_client.py b/src/coingecko_sdk/_base_client.py index ef929a6..7f93f2b 100644 --- a/src/coingecko_sdk/_base_client.py +++ b/src/coingecko_sdk/_base_client.py @@ -9,6 +9,7 @@ import inspect import logging import platform +import warnings import email.utils from types import TracebackType from random import random @@ -51,9 +52,11 @@ ResponseT, AnyMapping, PostParser, + BinaryTypes, RequestFiles, HttpxSendArgs, RequestOptions, + AsyncBinaryTypes, HttpxRequestFiles, ModelBuilderProtocol, not_given, @@ -83,6 +86,7 @@ APIConnectionError, APIResponseValidationError, ) +from ._utils._json import openapi_dumps log: logging.Logger = logging.getLogger(__name__) @@ -477,8 +481,19 @@ def _build_request( retries_taken: int = 0, ) -> httpx.Request: if log.isEnabledFor(logging.DEBUG): - log.debug("Request options: %s", model_dump(options, exclude_unset=True)) - + log.debug( + "Request options: %s", + model_dump( + options, + exclude_unset=True, + # Pydantic v1 can't dump every type we support in content, so we exclude it for now. + exclude={ + "content", + } + if PYDANTIC_V1 + else {}, + ), + ) kwargs: dict[str, Any] = {} json_data = options.json_data @@ -532,7 +547,18 @@ def _build_request( is_body_allowed = options.method.lower() != "get" if is_body_allowed: - kwargs["json"] = json_data if is_given(json_data) else None + if options.content is not None and json_data is not None: + raise TypeError("Passing both `content` and `json_data` is not supported") + if options.content is not None and files is not None: + raise TypeError("Passing both `content` and `files` is not supported") + if options.content is not None: + kwargs["content"] = options.content + elif isinstance(json_data, bytes): + kwargs["content"] = json_data + elif not files: + # Don't set content when JSON is sent as multipart/form-data, + # since httpx's content param overrides other body arguments + kwargs["content"] = openapi_dumps(json_data) if is_given(json_data) and json_data is not None else None kwargs["files"] = files else: headers.pop("Content-Type", None) @@ -1191,6 +1217,7 @@ def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: BinaryTypes | None = None, options: RequestOptions = {}, files: RequestFiles | None = None, stream: Literal[False] = False, @@ -1203,6 +1230,7 @@ def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: BinaryTypes | None = None, options: RequestOptions = {}, files: RequestFiles | None = None, stream: Literal[True], @@ -1216,6 +1244,7 @@ def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: BinaryTypes | None = None, options: RequestOptions = {}, files: RequestFiles | None = None, stream: bool, @@ -1228,13 +1257,25 @@ def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: BinaryTypes | None = None, options: RequestOptions = {}, files: RequestFiles | None = None, stream: bool = False, stream_cls: type[_StreamT] | None = None, ) -> ResponseT | _StreamT: + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if files is not None and content is not None: + raise TypeError("Passing both `files` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) opts = FinalRequestOptions.construct( - method="post", url=path, json_data=body, files=to_httpx_files(files), **options + method="post", url=path, json_data=body, content=content, files=to_httpx_files(files), **options ) return cast(ResponseT, self.request(cast_to, opts, stream=stream, stream_cls=stream_cls)) @@ -1244,11 +1285,23 @@ def patch( *, cast_to: Type[ResponseT], body: Body | None = None, + content: BinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, ) -> ResponseT: + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if files is not None and content is not None: + raise TypeError("Passing both `files` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) opts = FinalRequestOptions.construct( - method="patch", url=path, json_data=body, files=to_httpx_files(files), **options + method="patch", url=path, json_data=body, content=content, files=to_httpx_files(files), **options ) return self.request(cast_to, opts) @@ -1258,11 +1311,23 @@ def put( *, cast_to: Type[ResponseT], body: Body | None = None, + content: BinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, ) -> ResponseT: + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if files is not None and content is not None: + raise TypeError("Passing both `files` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) opts = FinalRequestOptions.construct( - method="put", url=path, json_data=body, files=to_httpx_files(files), **options + method="put", url=path, json_data=body, content=content, files=to_httpx_files(files), **options ) return self.request(cast_to, opts) @@ -1272,9 +1337,19 @@ def delete( *, cast_to: Type[ResponseT], body: Body | None = None, + content: BinaryTypes | None = None, options: RequestOptions = {}, ) -> ResponseT: - opts = FinalRequestOptions.construct(method="delete", url=path, json_data=body, **options) + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) + opts = FinalRequestOptions.construct(method="delete", url=path, json_data=body, content=content, **options) return self.request(cast_to, opts) def get_api_list( @@ -1714,6 +1789,7 @@ async def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: AsyncBinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, stream: Literal[False] = False, @@ -1726,6 +1802,7 @@ async def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: AsyncBinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, stream: Literal[True], @@ -1739,6 +1816,7 @@ async def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: AsyncBinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, stream: bool, @@ -1751,13 +1829,25 @@ async def post( *, cast_to: Type[ResponseT], body: Body | None = None, + content: AsyncBinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, stream: bool = False, stream_cls: type[_AsyncStreamT] | None = None, ) -> ResponseT | _AsyncStreamT: + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if files is not None and content is not None: + raise TypeError("Passing both `files` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) opts = FinalRequestOptions.construct( - method="post", url=path, json_data=body, files=await async_to_httpx_files(files), **options + method="post", url=path, json_data=body, content=content, files=await async_to_httpx_files(files), **options ) return await self.request(cast_to, opts, stream=stream, stream_cls=stream_cls) @@ -1767,11 +1857,28 @@ async def patch( *, cast_to: Type[ResponseT], body: Body | None = None, + content: AsyncBinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, ) -> ResponseT: + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if files is not None and content is not None: + raise TypeError("Passing both `files` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) opts = FinalRequestOptions.construct( - method="patch", url=path, json_data=body, files=await async_to_httpx_files(files), **options + method="patch", + url=path, + json_data=body, + content=content, + files=await async_to_httpx_files(files), + **options, ) return await self.request(cast_to, opts) @@ -1781,11 +1888,23 @@ async def put( *, cast_to: Type[ResponseT], body: Body | None = None, + content: AsyncBinaryTypes | None = None, files: RequestFiles | None = None, options: RequestOptions = {}, ) -> ResponseT: + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if files is not None and content is not None: + raise TypeError("Passing both `files` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) opts = FinalRequestOptions.construct( - method="put", url=path, json_data=body, files=await async_to_httpx_files(files), **options + method="put", url=path, json_data=body, content=content, files=await async_to_httpx_files(files), **options ) return await self.request(cast_to, opts) @@ -1795,9 +1914,19 @@ async def delete( *, cast_to: Type[ResponseT], body: Body | None = None, + content: AsyncBinaryTypes | None = None, options: RequestOptions = {}, ) -> ResponseT: - opts = FinalRequestOptions.construct(method="delete", url=path, json_data=body, **options) + if body is not None and content is not None: + raise TypeError("Passing both `body` and `content` is not supported") + if isinstance(body, bytes): + warnings.warn( + "Passing raw bytes as `body` is deprecated and will be removed in a future version. " + "Please pass raw bytes via the `content` parameter instead.", + DeprecationWarning, + stacklevel=2, + ) + opts = FinalRequestOptions.construct(method="delete", url=path, json_data=body, content=content, **options) return await self.request(cast_to, opts) def get_api_list( diff --git a/src/coingecko_sdk/_client.py b/src/coingecko_sdk/_client.py index 2b7a327..7d6faad 100644 --- a/src/coingecko_sdk/_client.py +++ b/src/coingecko_sdk/_client.py @@ -299,14 +299,10 @@ def default_headers(self) -> dict[str, str | Omit]: @override def _validate_headers(self, headers: Headers, custom_headers: Headers) -> None: - if self.pro_api_key and headers.get("x-cg-pro-api-key"): - return - if isinstance(custom_headers.get("x-cg-pro-api-key"), Omit): + if headers.get("x-cg-pro-api-key") or isinstance(custom_headers.get("x-cg-pro-api-key"), Omit): return - if self.demo_api_key and headers.get("x-cg-demo-api-key"): - return - if isinstance(custom_headers.get("x-cg-demo-api-key"), Omit): + if headers.get("x-cg-demo-api-key") or isinstance(custom_headers.get("x-cg-demo-api-key"), Omit): return raise TypeError( @@ -618,14 +614,10 @@ def default_headers(self) -> dict[str, str | Omit]: @override def _validate_headers(self, headers: Headers, custom_headers: Headers) -> None: - if self.pro_api_key and headers.get("x-cg-pro-api-key"): - return - if isinstance(custom_headers.get("x-cg-pro-api-key"), Omit): + if headers.get("x-cg-pro-api-key") or isinstance(custom_headers.get("x-cg-pro-api-key"), Omit): return - if self.demo_api_key and headers.get("x-cg-demo-api-key"): - return - if isinstance(custom_headers.get("x-cg-demo-api-key"), Omit): + if headers.get("x-cg-demo-api-key") or isinstance(custom_headers.get("x-cg-demo-api-key"), Omit): return raise TypeError( diff --git a/src/coingecko_sdk/_compat.py b/src/coingecko_sdk/_compat.py index bdef67f..786ff42 100644 --- a/src/coingecko_sdk/_compat.py +++ b/src/coingecko_sdk/_compat.py @@ -139,6 +139,7 @@ def model_dump( exclude_defaults: bool = False, warnings: bool = True, mode: Literal["json", "python"] = "python", + by_alias: bool | None = None, ) -> dict[str, Any]: if (not PYDANTIC_V1) or hasattr(model, "model_dump"): return model.model_dump( @@ -148,13 +149,12 @@ def model_dump( exclude_defaults=exclude_defaults, # warnings are not supported in Pydantic v1 warnings=True if PYDANTIC_V1 else warnings, + by_alias=by_alias, ) return cast( "dict[str, Any]", model.dict( # pyright: ignore[reportDeprecated, reportUnnecessaryCast] - exclude=exclude, - exclude_unset=exclude_unset, - exclude_defaults=exclude_defaults, + exclude=exclude, exclude_unset=exclude_unset, exclude_defaults=exclude_defaults, by_alias=bool(by_alias) ), ) diff --git a/src/coingecko_sdk/_files.py b/src/coingecko_sdk/_files.py index 715cc20..cc14c14 100644 --- a/src/coingecko_sdk/_files.py +++ b/src/coingecko_sdk/_files.py @@ -69,12 +69,12 @@ def _transform_file(file: FileTypes) -> HttpxFileTypes: return file if is_tuple_t(file): - return (file[0], _read_file_content(file[1]), *file[2:]) + return (file[0], read_file_content(file[1]), *file[2:]) raise TypeError(f"Expected file types input to be a FileContent type or to be a tuple") -def _read_file_content(file: FileContent) -> HttpxFileContent: +def read_file_content(file: FileContent) -> HttpxFileContent: if isinstance(file, os.PathLike): return pathlib.Path(file).read_bytes() return file @@ -111,12 +111,12 @@ async def _async_transform_file(file: FileTypes) -> HttpxFileTypes: return file if is_tuple_t(file): - return (file[0], await _async_read_file_content(file[1]), *file[2:]) + return (file[0], await async_read_file_content(file[1]), *file[2:]) raise TypeError(f"Expected file types input to be a FileContent type or to be a tuple") -async def _async_read_file_content(file: FileContent) -> HttpxFileContent: +async def async_read_file_content(file: FileContent) -> HttpxFileContent: if isinstance(file, os.PathLike): return await anyio.Path(file).read_bytes() diff --git a/src/coingecko_sdk/_models.py b/src/coingecko_sdk/_models.py index ca9500b..29070e0 100644 --- a/src/coingecko_sdk/_models.py +++ b/src/coingecko_sdk/_models.py @@ -3,7 +3,20 @@ import os import inspect import weakref -from typing import TYPE_CHECKING, Any, Type, Union, Generic, TypeVar, Callable, Optional, cast +from typing import ( + IO, + TYPE_CHECKING, + Any, + Type, + Union, + Generic, + TypeVar, + Callable, + Iterable, + Optional, + AsyncIterable, + cast, +) from datetime import date, datetime from typing_extensions import ( List, @@ -787,6 +800,7 @@ class FinalRequestOptionsInput(TypedDict, total=False): timeout: float | Timeout | None files: HttpxRequestFiles | None idempotency_key: str + content: Union[bytes, bytearray, IO[bytes], Iterable[bytes], AsyncIterable[bytes], None] json_data: Body extra_json: AnyMapping follow_redirects: bool @@ -805,6 +819,7 @@ class FinalRequestOptions(pydantic.BaseModel): post_parser: Union[Callable[[Any], Any], NotGiven] = NotGiven() follow_redirects: Union[bool, None] = None + content: Union[bytes, bytearray, IO[bytes], Iterable[bytes], AsyncIterable[bytes], None] = None # It should be noted that we cannot use `json` here as that would override # a BaseModel method in an incompatible fashion. json_data: Union[Body, None] = None diff --git a/src/coingecko_sdk/_response.py b/src/coingecko_sdk/_response.py index dfeaf34..0e544d3 100644 --- a/src/coingecko_sdk/_response.py +++ b/src/coingecko_sdk/_response.py @@ -152,6 +152,7 @@ def _parse(self, *, to: type[_T] | None = None) -> R | _T: ), response=self.http_response, client=cast(Any, self._client), + options=self._options, ), ) @@ -162,6 +163,7 @@ def _parse(self, *, to: type[_T] | None = None) -> R | _T: cast_to=extract_stream_chunk_type(self._stream_cls), response=self.http_response, client=cast(Any, self._client), + options=self._options, ), ) @@ -175,6 +177,7 @@ def _parse(self, *, to: type[_T] | None = None) -> R | _T: cast_to=cast_to, response=self.http_response, client=cast(Any, self._client), + options=self._options, ), ) diff --git a/src/coingecko_sdk/_streaming.py b/src/coingecko_sdk/_streaming.py index c727889..d7a9099 100644 --- a/src/coingecko_sdk/_streaming.py +++ b/src/coingecko_sdk/_streaming.py @@ -4,7 +4,7 @@ import json import inspect from types import TracebackType -from typing import TYPE_CHECKING, Any, Generic, TypeVar, Iterator, AsyncIterator, cast +from typing import TYPE_CHECKING, Any, Generic, TypeVar, Iterator, Optional, AsyncIterator, cast from typing_extensions import Self, Protocol, TypeGuard, override, get_origin, runtime_checkable import httpx @@ -13,6 +13,7 @@ if TYPE_CHECKING: from ._client import Coingecko, AsyncCoingecko + from ._models import FinalRequestOptions _T = TypeVar("_T") @@ -22,7 +23,7 @@ class Stream(Generic[_T]): """Provides the core interface to iterate over a synchronous stream response.""" response: httpx.Response - + _options: Optional[FinalRequestOptions] = None _decoder: SSEBytesDecoder def __init__( @@ -31,10 +32,12 @@ def __init__( cast_to: type[_T], response: httpx.Response, client: Coingecko, + options: Optional[FinalRequestOptions] = None, ) -> None: self.response = response self._cast_to = cast_to self._client = client + self._options = options self._decoder = client._make_sse_decoder() self._iterator = self.__stream__() @@ -85,7 +88,7 @@ class AsyncStream(Generic[_T]): """Provides the core interface to iterate over an asynchronous stream response.""" response: httpx.Response - + _options: Optional[FinalRequestOptions] = None _decoder: SSEDecoder | SSEBytesDecoder def __init__( @@ -94,10 +97,12 @@ def __init__( cast_to: type[_T], response: httpx.Response, client: AsyncCoingecko, + options: Optional[FinalRequestOptions] = None, ) -> None: self.response = response self._cast_to = cast_to self._client = client + self._options = options self._decoder = client._make_sse_decoder() self._iterator = self.__stream__() diff --git a/src/coingecko_sdk/_types.py b/src/coingecko_sdk/_types.py index 5bb7a15..e012547 100644 --- a/src/coingecko_sdk/_types.py +++ b/src/coingecko_sdk/_types.py @@ -13,9 +13,11 @@ Mapping, TypeVar, Callable, + Iterable, Iterator, Optional, Sequence, + AsyncIterable, ) from typing_extensions import ( Set, @@ -56,6 +58,13 @@ else: Base64FileInput = Union[IO[bytes], PathLike] FileContent = Union[IO[bytes], bytes, PathLike] # PathLike is not subscriptable in Python 3.8. + + +# Used for sending raw binary data / streaming data in request bodies +# e.g. for file uploads without multipart encoding +BinaryTypes = Union[bytes, bytearray, IO[bytes], Iterable[bytes]] +AsyncBinaryTypes = Union[bytes, bytearray, IO[bytes], AsyncIterable[bytes]] + FileTypes = Union[ # file (or bytes) FileContent, diff --git a/src/coingecko_sdk/_utils/_compat.py b/src/coingecko_sdk/_utils/_compat.py index dd70323..2c70b29 100644 --- a/src/coingecko_sdk/_utils/_compat.py +++ b/src/coingecko_sdk/_utils/_compat.py @@ -26,7 +26,7 @@ def is_union(tp: Optional[Type[Any]]) -> bool: else: import types - return tp is Union or tp is types.UnionType + return tp is Union or tp is types.UnionType # type: ignore[comparison-overlap] def is_typeddict(tp: Type[Any]) -> bool: diff --git a/src/coingecko_sdk/_utils/_json.py b/src/coingecko_sdk/_utils/_json.py new file mode 100644 index 0000000..6058421 --- /dev/null +++ b/src/coingecko_sdk/_utils/_json.py @@ -0,0 +1,35 @@ +import json +from typing import Any +from datetime import datetime +from typing_extensions import override + +import pydantic + +from .._compat import model_dump + + +def openapi_dumps(obj: Any) -> bytes: + """ + Serialize an object to UTF-8 encoded JSON bytes. + + Extends the standard json.dumps with support for additional types + commonly used in the SDK, such as `datetime`, `pydantic.BaseModel`, etc. + """ + return json.dumps( + obj, + cls=_CustomEncoder, + # Uses the same defaults as httpx's JSON serialization + ensure_ascii=False, + separators=(",", ":"), + allow_nan=False, + ).encode() + + +class _CustomEncoder(json.JSONEncoder): + @override + def default(self, o: Any) -> Any: + if isinstance(o, datetime): + return o.isoformat() + if isinstance(o, pydantic.BaseModel): + return model_dump(o, exclude_unset=True, mode="json", by_alias=True) + return super().default(o) diff --git a/src/coingecko_sdk/_version.py b/src/coingecko_sdk/_version.py index a618cb5..a04e2ca 100644 --- a/src/coingecko_sdk/_version.py +++ b/src/coingecko_sdk/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "coingecko_sdk" -__version__ = "1.12.0" # x-release-please-version +__version__ = "1.13.0" # x-release-please-version diff --git a/src/coingecko_sdk/resources/coins/markets.py b/src/coingecko_sdk/resources/coins/markets.py index 29268f6..0d1700a 100644 --- a/src/coingecko_sdk/resources/coins/markets.py +++ b/src/coingecko_sdk/resources/coins/markets.py @@ -49,6 +49,7 @@ def get( vs_currency: str, category: str | Omit = omit, ids: str | Omit = omit, + include_rehypothecated: bool | Omit = omit, include_tokens: Literal["top", "all"] | Omit = omit, locale: Literal[ "ar", @@ -139,6 +140,9 @@ def get( ids: coins' IDs, comma-separated if querying more than 1 coin. \\**refers to [`/coins/list`](/reference/coins-list). + include_rehypothecated: include rehypothecated tokens in results, default: false When true, returns + `market_cap_rank_with_rehypothecated` field + include_tokens: for `symbols` lookups, specify `all` to include all matching tokens Default `top` returns top-ranked tokens (by market cap or volume) @@ -181,6 +185,7 @@ def get( "vs_currency": vs_currency, "category": category, "ids": ids, + "include_rehypothecated": include_rehypothecated, "include_tokens": include_tokens, "locale": locale, "names": names, @@ -225,6 +230,7 @@ async def get( vs_currency: str, category: str | Omit = omit, ids: str | Omit = omit, + include_rehypothecated: bool | Omit = omit, include_tokens: Literal["top", "all"] | Omit = omit, locale: Literal[ "ar", @@ -315,6 +321,9 @@ async def get( ids: coins' IDs, comma-separated if querying more than 1 coin. \\**refers to [`/coins/list`](/reference/coins-list). + include_rehypothecated: include rehypothecated tokens in results, default: false When true, returns + `market_cap_rank_with_rehypothecated` field + include_tokens: for `symbols` lookups, specify `all` to include all matching tokens Default `top` returns top-ranked tokens (by market cap or volume) @@ -357,6 +366,7 @@ async def get( "vs_currency": vs_currency, "category": category, "ids": ids, + "include_rehypothecated": include_rehypothecated, "include_tokens": include_tokens, "locale": locale, "names": names, diff --git a/src/coingecko_sdk/resources/onchain/networks/tokens/pools.py b/src/coingecko_sdk/resources/onchain/networks/tokens/pools.py index 4d6b8b3..340236e 100644 --- a/src/coingecko_sdk/resources/onchain/networks/tokens/pools.py +++ b/src/coingecko_sdk/resources/onchain/networks/tokens/pools.py @@ -49,6 +49,7 @@ def get( *, network: str, include: str | Omit = omit, + include_gt_community_data: bool | Omit = omit, include_inactive_source: bool | Omit = omit, page: int | Omit = omit, sort: Literal["h24_volume_usd_liquidity_desc", "h24_tx_count_desc", "h24_volume_usd_desc"] | Omit = omit, @@ -67,6 +68,9 @@ def get( include: attributes to include, comma-separated if more than one to include Available values: `base_token`, `quote_token`, `dex` + include_gt_community_data: include GeckoTerminal community data (Sentiment votes, Suspicious reports) + Default value: false + include_inactive_source: include tokens from inactive pools using the most recent swap, default: false page: page through results Default value: 1 @@ -95,6 +99,7 @@ def get( query=maybe_transform( { "include": include, + "include_gt_community_data": include_gt_community_data, "include_inactive_source": include_inactive_source, "page": page, "sort": sort, @@ -132,6 +137,7 @@ async def get( *, network: str, include: str | Omit = omit, + include_gt_community_data: bool | Omit = omit, include_inactive_source: bool | Omit = omit, page: int | Omit = omit, sort: Literal["h24_volume_usd_liquidity_desc", "h24_tx_count_desc", "h24_volume_usd_desc"] | Omit = omit, @@ -150,6 +156,9 @@ async def get( include: attributes to include, comma-separated if more than one to include Available values: `base_token`, `quote_token`, `dex` + include_gt_community_data: include GeckoTerminal community data (Sentiment votes, Suspicious reports) + Default value: false + include_inactive_source: include tokens from inactive pools using the most recent swap, default: false page: page through results Default value: 1 @@ -178,6 +187,7 @@ async def get( query=await async_maybe_transform( { "include": include, + "include_gt_community_data": include_gt_community_data, "include_inactive_source": include_inactive_source, "page": page, "sort": sort, diff --git a/src/coingecko_sdk/resources/onchain/networks/tokens/top_holders.py b/src/coingecko_sdk/resources/onchain/networks/tokens/top_holders.py index ca5ca9c..34ebff3 100644 --- a/src/coingecko_sdk/resources/onchain/networks/tokens/top_holders.py +++ b/src/coingecko_sdk/resources/onchain/networks/tokens/top_holders.py @@ -47,6 +47,7 @@ def get( *, network: str, holders: str | Omit = omit, + include_pnl_details: bool | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. extra_headers: Headers | None = None, @@ -62,6 +63,8 @@ def get( holders: number of top token holders to return, you may use any integer or `max` Default value: 10 + include_pnl_details: include PnL details for token holders, default: false + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -81,7 +84,13 @@ def get( extra_query=extra_query, extra_body=extra_body, timeout=timeout, - query=maybe_transform({"holders": holders}, top_holder_get_params.TopHolderGetParams), + query=maybe_transform( + { + "holders": holders, + "include_pnl_details": include_pnl_details, + }, + top_holder_get_params.TopHolderGetParams, + ), ), cast_to=TopHolderGetResponse, ) @@ -113,6 +122,7 @@ async def get( *, network: str, holders: str | Omit = omit, + include_pnl_details: bool | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. extra_headers: Headers | None = None, @@ -128,6 +138,8 @@ async def get( holders: number of top token holders to return, you may use any integer or `max` Default value: 10 + include_pnl_details: include PnL details for token holders, default: false + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -147,7 +159,13 @@ async def get( extra_query=extra_query, extra_body=extra_body, timeout=timeout, - query=await async_maybe_transform({"holders": holders}, top_holder_get_params.TopHolderGetParams), + query=await async_maybe_transform( + { + "holders": holders, + "include_pnl_details": include_pnl_details, + }, + top_holder_get_params.TopHolderGetParams, + ), ), cast_to=TopHolderGetResponse, ) diff --git a/src/coingecko_sdk/resources/onchain/pools/megafilter.py b/src/coingecko_sdk/resources/onchain/pools/megafilter.py index fe36442..e2c41c6 100644 --- a/src/coingecko_sdk/resources/onchain/pools/megafilter.py +++ b/src/coingecko_sdk/resources/onchain/pools/megafilter.py @@ -63,6 +63,9 @@ def get( page: int | Omit = omit, pool_created_hour_max: float | Omit = omit, pool_created_hour_min: float | Omit = omit, + price_change_percentage_duration: Literal["5m", "1h", "6h", "24h"] | Omit = omit, + price_change_percentage_max: float | Omit = omit, + price_change_percentage_min: float | Omit = omit, reserve_in_usd_max: float | Omit = omit, reserve_in_usd_min: float | Omit = omit, sell_tax_percentage_max: float | Omit = omit, @@ -76,7 +79,9 @@ def get( "h6_trending", "h24_trending", "h24_tx_count_desc", + "h24_tx_count_asc", "h24_volume_usd_desc", + "h24_volume_usd_asc", "m5_price_change_percentage_asc", "h1_price_change_percentage_asc", "h6_price_change_percentage_asc", @@ -89,6 +94,8 @@ def get( "fdv_usd_desc", "reserve_in_usd_asc", "reserve_in_usd_desc", + "price_asc", + "price_desc", "pool_created_at_desc", ] | Omit = omit, @@ -146,6 +153,12 @@ def get( pool_created_hour_min: minimum pool age in hours + price_change_percentage_duration: duration for price change percentage metric + + price_change_percentage_max: maximum price change percentage + + price_change_percentage_min: minimum price change percentage + reserve_in_usd_max: maximum reserve in USD reserve_in_usd_min: minimum reserve in USD @@ -202,6 +215,9 @@ def get( "page": page, "pool_created_hour_max": pool_created_hour_max, "pool_created_hour_min": pool_created_hour_min, + "price_change_percentage_duration": price_change_percentage_duration, + "price_change_percentage_max": price_change_percentage_max, + "price_change_percentage_min": price_change_percentage_min, "reserve_in_usd_max": reserve_in_usd_max, "reserve_in_usd_min": reserve_in_usd_min, "sell_tax_percentage_max": sell_tax_percentage_max, @@ -261,6 +277,9 @@ async def get( page: int | Omit = omit, pool_created_hour_max: float | Omit = omit, pool_created_hour_min: float | Omit = omit, + price_change_percentage_duration: Literal["5m", "1h", "6h", "24h"] | Omit = omit, + price_change_percentage_max: float | Omit = omit, + price_change_percentage_min: float | Omit = omit, reserve_in_usd_max: float | Omit = omit, reserve_in_usd_min: float | Omit = omit, sell_tax_percentage_max: float | Omit = omit, @@ -274,7 +293,9 @@ async def get( "h6_trending", "h24_trending", "h24_tx_count_desc", + "h24_tx_count_asc", "h24_volume_usd_desc", + "h24_volume_usd_asc", "m5_price_change_percentage_asc", "h1_price_change_percentage_asc", "h6_price_change_percentage_asc", @@ -287,6 +308,8 @@ async def get( "fdv_usd_desc", "reserve_in_usd_asc", "reserve_in_usd_desc", + "price_asc", + "price_desc", "pool_created_at_desc", ] | Omit = omit, @@ -344,6 +367,12 @@ async def get( pool_created_hour_min: minimum pool age in hours + price_change_percentage_duration: duration for price change percentage metric + + price_change_percentage_max: maximum price change percentage + + price_change_percentage_min: minimum price change percentage + reserve_in_usd_max: maximum reserve in USD reserve_in_usd_min: minimum reserve in USD @@ -400,6 +429,9 @@ async def get( "page": page, "pool_created_hour_max": pool_created_hour_max, "pool_created_hour_min": pool_created_hour_min, + "price_change_percentage_duration": price_change_percentage_duration, + "price_change_percentage_max": price_change_percentage_max, + "price_change_percentage_min": price_change_percentage_min, "reserve_in_usd_max": reserve_in_usd_max, "reserve_in_usd_min": reserve_in_usd_min, "sell_tax_percentage_max": sell_tax_percentage_max, diff --git a/src/coingecko_sdk/resources/public_treasury.py b/src/coingecko_sdk/resources/public_treasury.py index 9052aff..dbbfec5 100644 --- a/src/coingecko_sdk/resources/public_treasury.py +++ b/src/coingecko_sdk/resources/public_treasury.py @@ -2,11 +2,17 @@ from __future__ import annotations +from typing import Any, cast from typing_extensions import Literal import httpx -from ..types import public_treasury_get_holding_chart_params, public_treasury_get_transaction_history_params +from ..types import ( + public_treasury_get_coin_id_params, + public_treasury_get_entity_id_params, + public_treasury_get_holding_chart_params, + public_treasury_get_transaction_history_params, +) from .._types import Body, Omit, Query, Headers, NotGiven, omit, not_given from .._utils import maybe_transform, async_maybe_transform from .._compat import cached_property @@ -51,6 +57,9 @@ def get_coin_id( coin_id: str, *, entity: Literal["companies", "governments"], + order: Literal["total_holdings_usd_desc", "total_holdings_usd_asc"] | Omit = omit, + page: int | Omit = omit, + per_page: int | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. extra_headers: Headers | None = None, @@ -63,6 +72,12 @@ def get_coin_id( holdings** by Coin ID Args: + order: Sort order for results + + page: Page number to return + + per_page: Number of results to return per page + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -75,18 +90,36 @@ def get_coin_id( raise ValueError(f"Expected a non-empty value for `entity` but received {entity!r}") if not coin_id: raise ValueError(f"Expected a non-empty value for `coin_id` but received {coin_id!r}") - return self._get( - f"/{entity}/public_treasury/{coin_id}", - options=make_request_options( - extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + return cast( + PublicTreasuryGetCoinIDResponse, + self._get( + f"/{entity}/public_treasury/{coin_id}", + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "order": order, + "page": page, + "per_page": per_page, + }, + public_treasury_get_coin_id_params.PublicTreasuryGetCoinIDParams, + ), + ), + cast_to=cast( + Any, PublicTreasuryGetCoinIDResponse + ), # Union types cannot be passed in as arguments in the type system ), - cast_to=PublicTreasuryGetCoinIDResponse, ) def get_entity_id( self, entity_id: str, *, + holding_amount_change: str | Omit = omit, + holding_change_percentage: str | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. extra_headers: Headers | None = None, @@ -99,6 +132,12 @@ def get_entity_id( holdings** by Entity ID Args: + holding_amount_change: include holding amount change for specified timeframes, comma-separated if + querying more than 1 timeframe Valid values: 7d, 14d, 30d, 90d, 1y, ytd + + holding_change_percentage: include holding change percentage for specified timeframes, comma-separated if + querying more than 1 timeframe Valid values: 7d, 14d, 30d, 90d, 1y, ytd + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -112,7 +151,17 @@ def get_entity_id( return self._get( f"/public_treasury/{entity_id}", options=make_request_options( - extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "holding_amount_change": holding_amount_change, + "holding_change_percentage": holding_change_percentage, + }, + public_treasury_get_entity_id_params.PublicTreasuryGetEntityIDParams, + ), ), cast_to=PublicTreasuryGetEntityIDResponse, ) @@ -265,6 +314,9 @@ async def get_coin_id( coin_id: str, *, entity: Literal["companies", "governments"], + order: Literal["total_holdings_usd_desc", "total_holdings_usd_asc"] | Omit = omit, + page: int | Omit = omit, + per_page: int | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. extra_headers: Headers | None = None, @@ -277,6 +329,12 @@ async def get_coin_id( holdings** by Coin ID Args: + order: Sort order for results + + page: Page number to return + + per_page: Number of results to return per page + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -289,18 +347,36 @@ async def get_coin_id( raise ValueError(f"Expected a non-empty value for `entity` but received {entity!r}") if not coin_id: raise ValueError(f"Expected a non-empty value for `coin_id` but received {coin_id!r}") - return await self._get( - f"/{entity}/public_treasury/{coin_id}", - options=make_request_options( - extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + return cast( + PublicTreasuryGetCoinIDResponse, + await self._get( + f"/{entity}/public_treasury/{coin_id}", + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=await async_maybe_transform( + { + "order": order, + "page": page, + "per_page": per_page, + }, + public_treasury_get_coin_id_params.PublicTreasuryGetCoinIDParams, + ), + ), + cast_to=cast( + Any, PublicTreasuryGetCoinIDResponse + ), # Union types cannot be passed in as arguments in the type system ), - cast_to=PublicTreasuryGetCoinIDResponse, ) async def get_entity_id( self, entity_id: str, *, + holding_amount_change: str | Omit = omit, + holding_change_percentage: str | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. # The extra values given here take precedence over values defined on the client or passed to this method. extra_headers: Headers | None = None, @@ -313,6 +389,12 @@ async def get_entity_id( holdings** by Entity ID Args: + holding_amount_change: include holding amount change for specified timeframes, comma-separated if + querying more than 1 timeframe Valid values: 7d, 14d, 30d, 90d, 1y, ytd + + holding_change_percentage: include holding change percentage for specified timeframes, comma-separated if + querying more than 1 timeframe Valid values: 7d, 14d, 30d, 90d, 1y, ytd + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -326,7 +408,17 @@ async def get_entity_id( return await self._get( f"/public_treasury/{entity_id}", options=make_request_options( - extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=await async_maybe_transform( + { + "holding_amount_change": holding_amount_change, + "holding_change_percentage": holding_change_percentage, + }, + public_treasury_get_entity_id_params.PublicTreasuryGetEntityIDParams, + ), ), cast_to=PublicTreasuryGetEntityIDResponse, ) diff --git a/src/coingecko_sdk/types/__init__.py b/src/coingecko_sdk/types/__init__.py index 98b32cd..c8b3d85 100644 --- a/src/coingecko_sdk/types/__init__.py +++ b/src/coingecko_sdk/types/__init__.py @@ -27,7 +27,9 @@ from .exchange_rate_get_response import ExchangeRateGetResponse as ExchangeRateGetResponse from .asset_platform_get_response import AssetPlatformGetResponse as AssetPlatformGetResponse from .token_list_get_all_json_response import TokenListGetAllJsonResponse as TokenListGetAllJsonResponse +from .public_treasury_get_coin_id_params import PublicTreasuryGetCoinIDParams as PublicTreasuryGetCoinIDParams from .public_treasury_get_coin_id_response import PublicTreasuryGetCoinIDResponse as PublicTreasuryGetCoinIDResponse +from .public_treasury_get_entity_id_params import PublicTreasuryGetEntityIDParams as PublicTreasuryGetEntityIDParams from .public_treasury_get_entity_id_response import ( PublicTreasuryGetEntityIDResponse as PublicTreasuryGetEntityIDResponse, ) diff --git a/src/coingecko_sdk/types/coin_get_id_response.py b/src/coingecko_sdk/types/coin_get_id_response.py index 82b1d95..c539c1c 100644 --- a/src/coingecko_sdk/types/coin_get_id_response.py +++ b/src/coingecko_sdk/types/coin_get_id_response.py @@ -566,6 +566,9 @@ class MarketData(BaseModel): market_cap_rank: Optional[float] = None """coin rank by market cap""" + market_cap_rank_with_rehypothecated: Optional[float] = None + """coin rank by market cap including rehypothecated tokens""" + max_supply: Optional[float] = None """coin max supply""" @@ -780,6 +783,9 @@ class CoinGetIDResponse(BaseModel): market_cap_rank: Optional[float] = None """coin rank by market cap""" + market_cap_rank_with_rehypothecated: Optional[float] = None + """coin rank by market cap including rehypothecated tokens""" + market_data: Optional[MarketData] = None """coin market data""" diff --git a/src/coingecko_sdk/types/coins/contract_get_response.py b/src/coingecko_sdk/types/coins/contract_get_response.py index 10cba95..22f252b 100644 --- a/src/coingecko_sdk/types/coins/contract_get_response.py +++ b/src/coingecko_sdk/types/coins/contract_get_response.py @@ -462,6 +462,9 @@ class MarketData(BaseModel): market_cap_rank: Optional[float] = None """coin rank by market cap""" + market_cap_rank_with_rehypothecated: Optional[float] = None + """coin rank by market cap including rehypothecated tokens""" + max_supply: Optional[float] = None """coin max supply""" @@ -670,6 +673,9 @@ class ContractGetResponse(BaseModel): market_cap_rank: Optional[float] = None """coin rank by market cap""" + market_cap_rank_with_rehypothecated: Optional[float] = None + """coin rank by market cap including rehypothecated tokens""" + market_data: Optional[MarketData] = None """coin market data""" diff --git a/src/coingecko_sdk/types/coins/market_get_params.py b/src/coingecko_sdk/types/coins/market_get_params.py index 65c3ee2..44ad188 100644 --- a/src/coingecko_sdk/types/coins/market_get_params.py +++ b/src/coingecko_sdk/types/coins/market_get_params.py @@ -26,6 +26,12 @@ class MarketGetParams(TypedDict, total=False): \\**refers to [`/coins/list`](/reference/coins-list). """ + include_rehypothecated: bool + """ + include rehypothecated tokens in results, default: false When true, returns + `market_cap_rank_with_rehypothecated` field + """ + include_tokens: Literal["top", "all"] """ for `symbols` lookups, specify `all` to include all matching tokens Default diff --git a/src/coingecko_sdk/types/coins/market_get_response.py b/src/coingecko_sdk/types/coins/market_get_response.py index 787862e..bdf0e7a 100644 --- a/src/coingecko_sdk/types/coins/market_get_response.py +++ b/src/coingecko_sdk/types/coins/market_get_response.py @@ -77,6 +77,9 @@ class MarketGetResponseItem(BaseModel): market_cap_rank: Optional[float] = None """coin rank by market cap""" + market_cap_rank_with_rehypothecated: Optional[float] = None + """coin rank by market cap including rehypothecated tokens""" + max_supply: Optional[float] = None """coin max supply""" diff --git a/src/coingecko_sdk/types/exchange_get_response.py b/src/coingecko_sdk/types/exchange_get_response.py index b40009f..a21ac31 100644 --- a/src/coingecko_sdk/types/exchange_get_response.py +++ b/src/coingecko_sdk/types/exchange_get_response.py @@ -21,7 +21,7 @@ class ExchangeGetResponse(BaseModel): """exchange trading incentive""" image: Optional[str] = None - """exchange image url""" + """exchange image URL""" name: Optional[str] = None """exchange name""" @@ -36,7 +36,7 @@ class ExchangeGetResponse(BaseModel): """exchange trust score rank""" url: Optional[str] = None - """exchange website url""" + """exchange website URL""" year_established: Optional[float] = None """exchange established year""" diff --git a/src/coingecko_sdk/types/global_get_response.py b/src/coingecko_sdk/types/global_get_response.py index 1a4fb5b..62e3a77 100644 --- a/src/coingecko_sdk/types/global_get_response.py +++ b/src/coingecko_sdk/types/global_get_response.py @@ -61,6 +61,9 @@ class Data(BaseModel): updated_at: Optional[float] = None + volume_change_percentage_24h_usd: Optional[float] = None + """cryptocurrencies volume change percentage in 24 hours in usd""" + class GlobalGetResponse(BaseModel): data: Optional[Data] = None diff --git a/src/coingecko_sdk/types/key_get_response.py b/src/coingecko_sdk/types/key_get_response.py index 6120166..0227be1 100644 --- a/src/coingecko_sdk/types/key_get_response.py +++ b/src/coingecko_sdk/types/key_get_response.py @@ -8,6 +8,18 @@ class KeyGetResponse(BaseModel): + api_key_monthly_call_credit: Optional[float] = None + """ + Specific monthly credit limit configured for the API key used to authenticate + this request + """ + + api_key_rate_limit_request_per_minute: Optional[float] = None + """ + Specific request per minute configured for the API key used to authenticate this + request + """ + current_remaining_monthly_calls: Optional[float] = None current_total_monthly_calls: Optional[float] = None diff --git a/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_params.py b/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_params.py index 28a06e9..7120807 100644 --- a/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_params.py +++ b/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_params.py @@ -16,6 +16,12 @@ class PoolGetParams(TypedDict, total=False): values: `base_token`, `quote_token`, `dex` """ + include_gt_community_data: bool + """ + include GeckoTerminal community data (Sentiment votes, Suspicious reports) + Default value: false + """ + include_inactive_source: bool """include tokens from inactive pools using the most recent swap, default: false""" diff --git a/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_response.py b/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_response.py index 65d6538..6c9dd0b 100644 --- a/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_response.py +++ b/src/coingecko_sdk/types/onchain/networks/tokens/pool_get_response.py @@ -127,6 +127,8 @@ class DataAttributes(BaseModel): base_token_price_usd: Optional[str] = None + community_sus_report: Optional[float] = None + fdv_usd: Optional[str] = None last_trade_timestamp: Optional[int] = None @@ -147,6 +149,10 @@ class DataAttributes(BaseModel): reserve_in_usd: Optional[str] = None + sentiment_vote_negative_percentage: Optional[float] = None + + sentiment_vote_positive_percentage: Optional[float] = None + transactions: Optional[DataAttributesTransactions] = None volume_usd: Optional[DataAttributesVolumeUsd] = None diff --git a/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_params.py b/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_params.py index 2a50461..aa976a8 100644 --- a/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_params.py +++ b/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_params.py @@ -15,3 +15,6 @@ class TopHolderGetParams(TypedDict, total=False): number of top token holders to return, you may use any integer or `max` Default value: 10 """ + + include_pnl_details: bool + """include PnL details for token holders, default: false""" diff --git a/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_response.py b/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_response.py index 6c86f82..67e709f 100644 --- a/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_response.py +++ b/src/coingecko_sdk/types/onchain/networks/tokens/top_holder_get_response.py @@ -12,12 +12,28 @@ class DataAttributesHolder(BaseModel): amount: Optional[str] = None + average_buy_price_usd: Optional[str] = None + + explorer_url: Optional[str] = None + label: Optional[str] = None percentage: Optional[str] = None rank: Optional[float] = None + realized_pnl_percentage: Optional[str] = None + + realized_pnl_usd: Optional[str] = None + + total_buy_count: Optional[float] = None + + total_sell_count: Optional[float] = None + + unrealized_pnl_percentage: Optional[str] = None + + unrealized_pnl_usd: Optional[str] = None + value: Optional[str] = None diff --git a/src/coingecko_sdk/types/onchain/pools/megafilter_get_params.py b/src/coingecko_sdk/types/onchain/pools/megafilter_get_params.py index da6986f..e42c03e 100644 --- a/src/coingecko_sdk/types/onchain/pools/megafilter_get_params.py +++ b/src/coingecko_sdk/types/onchain/pools/megafilter_get_params.py @@ -74,6 +74,15 @@ class MegafilterGetParams(TypedDict, total=False): pool_created_hour_min: float """minimum pool age in hours""" + price_change_percentage_duration: Literal["5m", "1h", "6h", "24h"] + """duration for price change percentage metric""" + + price_change_percentage_max: float + """maximum price change percentage""" + + price_change_percentage_min: float + """minimum price change percentage""" + reserve_in_usd_max: float """maximum reserve in USD""" @@ -101,7 +110,9 @@ class MegafilterGetParams(TypedDict, total=False): "h6_trending", "h24_trending", "h24_tx_count_desc", + "h24_tx_count_asc", "h24_volume_usd_desc", + "h24_volume_usd_asc", "m5_price_change_percentage_asc", "h1_price_change_percentage_asc", "h6_price_change_percentage_asc", @@ -114,6 +125,8 @@ class MegafilterGetParams(TypedDict, total=False): "fdv_usd_desc", "reserve_in_usd_asc", "reserve_in_usd_desc", + "price_asc", + "price_desc", "pool_created_at_desc", ] """sort the pools by field Default value: h6_trending""" diff --git a/src/coingecko_sdk/types/public_treasury_get_coin_id_params.py b/src/coingecko_sdk/types/public_treasury_get_coin_id_params.py new file mode 100644 index 0000000..20420b8 --- /dev/null +++ b/src/coingecko_sdk/types/public_treasury_get_coin_id_params.py @@ -0,0 +1,20 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Literal, Required, TypedDict + +__all__ = ["PublicTreasuryGetCoinIDParams"] + + +class PublicTreasuryGetCoinIDParams(TypedDict, total=False): + entity: Required[Literal["companies", "governments"]] + + order: Literal["total_holdings_usd_desc", "total_holdings_usd_asc"] + """Sort order for results""" + + page: int + """Page number to return""" + + per_page: int + """Number of results to return per page""" diff --git a/src/coingecko_sdk/types/public_treasury_get_coin_id_response.py b/src/coingecko_sdk/types/public_treasury_get_coin_id_response.py index a7fa796..ad65ae2 100644 --- a/src/coingecko_sdk/types/public_treasury_get_coin_id_response.py +++ b/src/coingecko_sdk/types/public_treasury_get_coin_id_response.py @@ -1,13 +1,20 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. -from typing import List, Optional +from typing import List, Union, Optional +from typing_extensions import TypeAlias from .._models import BaseModel -__all__ = ["PublicTreasuryGetCoinIDResponse", "Company"] +__all__ = [ + "PublicTreasuryGetCoinIDResponse", + "CompaniesTreasury", + "CompaniesTreasuryCompany", + "GovernmentsTreasury", + "GovernmentsTreasuryGovernment", +] -class Company(BaseModel): +class CompaniesTreasuryCompany(BaseModel): country: Optional[str] = None """company incorporated or government country""" @@ -27,17 +34,56 @@ class Company(BaseModel): """total entry value in usd""" total_holdings: Optional[float] = None - """total crypto holdings of company""" + """total crypto holdings""" -class PublicTreasuryGetCoinIDResponse(BaseModel): - companies: Optional[List[Company]] = None +class CompaniesTreasury(BaseModel): + companies: List[CompaniesTreasuryCompany] - market_cap_dominance: Optional[float] = None + market_cap_dominance: float """market cap dominance""" + total_holdings: float + """total crypto holdings of companies""" + + total_value_usd: float + """total crypto holdings value in usd""" + + +class GovernmentsTreasuryGovernment(BaseModel): + country: Optional[str] = None + """company incorporated or government country""" + + name: Optional[str] = None + """company or government name""" + + percentage_of_total_supply: Optional[float] = None + """percentage of total crypto supply""" + + symbol: Optional[str] = None + """company symbol""" + + total_current_value_usd: Optional[float] = None + """total current value of crypto holdings in usd""" + + total_entry_value_usd: Optional[float] = None + """total entry value in usd""" + total_holdings: Optional[float] = None - """total crypto holdings of companies or government""" + """total crypto holdings""" - total_value_usd: Optional[float] = None + +class GovernmentsTreasury(BaseModel): + governments: List[GovernmentsTreasuryGovernment] + + market_cap_dominance: float + """market cap dominance""" + + total_holdings: float + """total crypto holdings of governments""" + + total_value_usd: float """total crypto holdings value in usd""" + + +PublicTreasuryGetCoinIDResponse: TypeAlias = Union[CompaniesTreasury, GovernmentsTreasury] diff --git a/src/coingecko_sdk/types/public_treasury_get_entity_id_params.py b/src/coingecko_sdk/types/public_treasury_get_entity_id_params.py new file mode 100644 index 0000000..13bcbf9 --- /dev/null +++ b/src/coingecko_sdk/types/public_treasury_get_entity_id_params.py @@ -0,0 +1,21 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import TypedDict + +__all__ = ["PublicTreasuryGetEntityIDParams"] + + +class PublicTreasuryGetEntityIDParams(TypedDict, total=False): + holding_amount_change: str + """ + include holding amount change for specified timeframes, comma-separated if + querying more than 1 timeframe Valid values: 7d, 14d, 30d, 90d, 1y, ytd + """ + + holding_change_percentage: str + """ + include holding change percentage for specified timeframes, comma-separated if + querying more than 1 timeframe Valid values: 7d, 14d, 30d, 90d, 1y, ytd + """ diff --git a/src/coingecko_sdk/types/public_treasury_get_entity_id_response.py b/src/coingecko_sdk/types/public_treasury_get_entity_id_response.py index fbccd29..339c1cb 100644 --- a/src/coingecko_sdk/types/public_treasury_get_entity_id_response.py +++ b/src/coingecko_sdk/types/public_treasury_get_entity_id_response.py @@ -2,21 +2,94 @@ from typing import List, Optional +from pydantic import Field as FieldInfo + from .._models import BaseModel -__all__ = ["PublicTreasuryGetEntityIDResponse", "Holding"] +__all__ = [ + "PublicTreasuryGetEntityIDResponse", + "Holding", + "HoldingHoldingAmountChange", + "HoldingHoldingChangePercentage", +] + + +class HoldingHoldingAmountChange(BaseModel): + """ + holding amount changes over different timeframes (only present if holding_amount_change param is used) + """ + + api_14d: Optional[float] = FieldInfo(alias="14d", default=None) + + api_1y: Optional[float] = FieldInfo(alias="1y", default=None) + + api_30d: Optional[float] = FieldInfo(alias="30d", default=None) + + api_7d: Optional[float] = FieldInfo(alias="7d", default=None) + + api_90d: Optional[float] = FieldInfo(alias="90d", default=None) + + ytd: Optional[float] = None + + +class HoldingHoldingChangePercentage(BaseModel): + """ + holding change percentages over different timeframes (only present if holding_change_percentage param is used) + """ + + api_14d: Optional[float] = FieldInfo(alias="14d", default=None) + + api_1y: Optional[float] = FieldInfo(alias="1y", default=None) + + api_30d: Optional[float] = FieldInfo(alias="30d", default=None) + + api_7d: Optional[float] = FieldInfo(alias="7d", default=None) + + api_90d: Optional[float] = FieldInfo(alias="90d", default=None) + + ytd: Optional[float] = None class Holding(BaseModel): amount: Optional[int] = None """amount of the cryptocurrency held""" + amount_per_share: Optional[float] = None + """amount of cryptocurrency per share""" + + average_entry_value_usd: Optional[float] = None + """average entry cost per unit in USD""" + coin_id: Optional[str] = None """coin ID""" + current_value_usd: Optional[float] = None + """current value of holdings in USD""" + + entity_value_usd_percentage: Optional[float] = None + """percentage of entity's total treasury value""" + + holding_amount_change: Optional[HoldingHoldingAmountChange] = None + """ + holding amount changes over different timeframes (only present if + holding_amount_change param is used) + """ + + holding_change_percentage: Optional[HoldingHoldingChangePercentage] = None + """ + holding change percentages over different timeframes (only present if + holding_change_percentage param is used) + """ + percentage_of_total_supply: Optional[float] = None """percentage of total crypto supply""" + total_entry_value_usd: Optional[float] = None + """total entry cost/purchase value in USD""" + + unrealized_pnl: Optional[float] = None + """unrealized profit and loss for this holding""" + class PublicTreasuryGetEntityIDResponse(BaseModel): id: Optional[str] = None @@ -28,17 +101,29 @@ class PublicTreasuryGetEntityIDResponse(BaseModel): holdings: Optional[List[Holding]] = None """list of cryptocurrency assets held by the entity""" + m_nav: Optional[float] = None + """market to net asset value ratio""" + name: Optional[str] = None """entity name""" symbol: Optional[str] = None """stock market symbol for public company""" + total_asset_value_per_share_usd: Optional[float] = None + """total asset value per share in USD""" + + total_treasury_value_usd: Optional[float] = None + """total current value of all holdings in USD""" + twitter_screen_name: Optional[str] = None """official Twitter handle of the entity""" type: Optional[str] = None """entity type: company or government""" + unrealized_pnl: Optional[float] = None + """unrealized profit and loss (current value - total entry value)""" + website_url: Optional[str] = None """official website URL of the entity""" diff --git a/tests/api_resources/coins/contract/test_market_chart.py b/tests/api_resources/coins/contract/test_market_chart.py index bd59bd0..95bbf4d 100644 --- a/tests/api_resources/coins/contract/test_market_chart.py +++ b/tests/api_resources/coins/contract/test_market_chart.py @@ -20,7 +20,7 @@ class TestMarketChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: market_chart = client.coins.contract.market_chart.get( @@ -31,7 +31,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: market_chart = client.coins.contract.market_chart.get( @@ -44,7 +44,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.contract.market_chart.with_raw_response.get( @@ -59,7 +59,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: market_chart = response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.contract.market_chart.with_streaming_response.get( @@ -76,7 +76,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -95,7 +95,7 @@ def test_path_params_get(self, client: Coingecko) -> None: vs_currency="usd", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range(self, client: Coingecko) -> None: market_chart = client.coins.contract.market_chart.get_range( @@ -107,7 +107,7 @@ def test_method_get_range(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range_with_all_params(self, client: Coingecko) -> None: market_chart = client.coins.contract.market_chart.get_range( @@ -121,7 +121,7 @@ def test_method_get_range_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_range(self, client: Coingecko) -> None: response = client.coins.contract.market_chart.with_raw_response.get_range( @@ -137,7 +137,7 @@ def test_raw_response_get_range(self, client: Coingecko) -> None: market_chart = response.parse() assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_range(self, client: Coingecko) -> None: with client.coins.contract.market_chart.with_streaming_response.get_range( @@ -155,7 +155,7 @@ def test_streaming_response_get_range(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_range(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -182,7 +182,7 @@ class TestAsyncMarketChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.contract.market_chart.get( @@ -193,7 +193,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.contract.market_chart.get( @@ -206,7 +206,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.contract.market_chart.with_raw_response.get( @@ -221,7 +221,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: market_chart = await response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.contract.market_chart.with_streaming_response.get( @@ -238,7 +238,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -257,7 +257,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: vs_currency="usd", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.contract.market_chart.get_range( @@ -269,7 +269,7 @@ async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range_with_all_params(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.contract.market_chart.get_range( @@ -283,7 +283,7 @@ async def test_method_get_range_with_all_params(self, async_client: AsyncCoingec ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.contract.market_chart.with_raw_response.get_range( @@ -299,7 +299,7 @@ async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> Non market_chart = await response.parse() assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.contract.market_chart.with_streaming_response.get_range( @@ -317,7 +317,7 @@ async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_range(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/coins/test_categories.py b/tests/api_resources/coins/test_categories.py index b6ecd8c..642397f 100644 --- a/tests/api_resources/coins/test_categories.py +++ b/tests/api_resources/coins/test_categories.py @@ -17,13 +17,13 @@ class TestCategories: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: category = client.coins.categories.get() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: category = client.coins.categories.get( @@ -31,7 +31,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.categories.with_raw_response.get() @@ -41,7 +41,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: category = response.parse() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.categories.with_streaming_response.get() as response: @@ -53,13 +53,13 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list(self, client: Coingecko) -> None: category = client.coins.categories.get_list() assert_matches_type(CategoryGetListResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_list(self, client: Coingecko) -> None: response = client.coins.categories.with_raw_response.get_list() @@ -69,7 +69,7 @@ def test_raw_response_get_list(self, client: Coingecko) -> None: category = response.parse() assert_matches_type(CategoryGetListResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_list(self, client: Coingecko) -> None: with client.coins.categories.with_streaming_response.get_list() as response: @@ -87,13 +87,13 @@ class TestAsyncCategories: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: category = await async_client.coins.categories.get() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: category = await async_client.coins.categories.get( @@ -101,7 +101,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.categories.with_raw_response.get() @@ -111,7 +111,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: category = await response.parse() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.categories.with_streaming_response.get() as response: @@ -123,13 +123,13 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list(self, async_client: AsyncCoingecko) -> None: category = await async_client.coins.categories.get_list() assert_matches_type(CategoryGetListResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.categories.with_raw_response.get_list() @@ -139,7 +139,7 @@ async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None category = await response.parse() assert_matches_type(CategoryGetListResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_list(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.categories.with_streaming_response.get_list() as response: diff --git a/tests/api_resources/coins/test_circulating_supply_chart.py b/tests/api_resources/coins/test_circulating_supply_chart.py index ddaba9c..38ab5a5 100644 --- a/tests/api_resources/coins/test_circulating_supply_chart.py +++ b/tests/api_resources/coins/test_circulating_supply_chart.py @@ -20,7 +20,7 @@ class TestCirculatingSupplyChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: circulating_supply_chart = client.coins.circulating_supply_chart.get( @@ -29,7 +29,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(CirculatingSupplyChartGetResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: circulating_supply_chart = client.coins.circulating_supply_chart.get( @@ -39,7 +39,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(CirculatingSupplyChartGetResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.circulating_supply_chart.with_raw_response.get( @@ -52,7 +52,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: circulating_supply_chart = response.parse() assert_matches_type(CirculatingSupplyChartGetResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.circulating_supply_chart.with_streaming_response.get( @@ -67,7 +67,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -76,7 +76,7 @@ def test_path_params_get(self, client: Coingecko) -> None: days="days", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range(self, client: Coingecko) -> None: circulating_supply_chart = client.coins.circulating_supply_chart.get_range( @@ -86,7 +86,7 @@ def test_method_get_range(self, client: Coingecko) -> None: ) assert_matches_type(CirculatingSupplyChartGetRangeResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_range(self, client: Coingecko) -> None: response = client.coins.circulating_supply_chart.with_raw_response.get_range( @@ -100,7 +100,7 @@ def test_raw_response_get_range(self, client: Coingecko) -> None: circulating_supply_chart = response.parse() assert_matches_type(CirculatingSupplyChartGetRangeResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_range(self, client: Coingecko) -> None: with client.coins.circulating_supply_chart.with_streaming_response.get_range( @@ -116,7 +116,7 @@ def test_streaming_response_get_range(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_range(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -132,7 +132,7 @@ class TestAsyncCirculatingSupplyChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: circulating_supply_chart = await async_client.coins.circulating_supply_chart.get( @@ -141,7 +141,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(CirculatingSupplyChartGetResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: circulating_supply_chart = await async_client.coins.circulating_supply_chart.get( @@ -151,7 +151,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(CirculatingSupplyChartGetResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.circulating_supply_chart.with_raw_response.get( @@ -164,7 +164,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: circulating_supply_chart = await response.parse() assert_matches_type(CirculatingSupplyChartGetResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.circulating_supply_chart.with_streaming_response.get( @@ -179,7 +179,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -188,7 +188,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: days="days", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: circulating_supply_chart = await async_client.coins.circulating_supply_chart.get_range( @@ -198,7 +198,7 @@ async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(CirculatingSupplyChartGetRangeResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.circulating_supply_chart.with_raw_response.get_range( @@ -212,7 +212,7 @@ async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> Non circulating_supply_chart = await response.parse() assert_matches_type(CirculatingSupplyChartGetRangeResponse, circulating_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.circulating_supply_chart.with_streaming_response.get_range( @@ -228,7 +228,7 @@ async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_range(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/coins/test_contract.py b/tests/api_resources/coins/test_contract.py index 81e6a89..62c0708 100644 --- a/tests/api_resources/coins/test_contract.py +++ b/tests/api_resources/coins/test_contract.py @@ -17,7 +17,7 @@ class TestContract: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: contract = client.coins.contract.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(ContractGetResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.contract.with_raw_response.get( @@ -39,7 +39,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: contract = response.parse() assert_matches_type(ContractGetResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.contract.with_streaming_response.get( @@ -54,7 +54,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -75,7 +75,7 @@ class TestAsyncContract: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: contract = await async_client.coins.contract.get( @@ -84,7 +84,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(ContractGetResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.contract.with_raw_response.get( @@ -97,7 +97,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: contract = await response.parse() assert_matches_type(ContractGetResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.contract.with_streaming_response.get( @@ -112,7 +112,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/coins/test_history.py b/tests/api_resources/coins/test_history.py index 84f8ed4..7fc8d58 100644 --- a/tests/api_resources/coins/test_history.py +++ b/tests/api_resources/coins/test_history.py @@ -17,7 +17,7 @@ class TestHistory: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: history = client.coins.history.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(HistoryGetResponse, history, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: history = client.coins.history.get( @@ -36,7 +36,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(HistoryGetResponse, history, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.history.with_raw_response.get( @@ -49,7 +49,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: history = response.parse() assert_matches_type(HistoryGetResponse, history, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.history.with_streaming_response.get( @@ -64,7 +64,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -79,7 +79,7 @@ class TestAsyncHistory: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: history = await async_client.coins.history.get( @@ -88,7 +88,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(HistoryGetResponse, history, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: history = await async_client.coins.history.get( @@ -98,7 +98,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(HistoryGetResponse, history, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.history.with_raw_response.get( @@ -111,7 +111,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: history = await response.parse() assert_matches_type(HistoryGetResponse, history, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.history.with_streaming_response.get( @@ -126,7 +126,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/coins/test_list.py b/tests/api_resources/coins/test_list.py index e9b3651..4fd8cfb 100644 --- a/tests/api_resources/coins/test_list.py +++ b/tests/api_resources/coins/test_list.py @@ -17,13 +17,13 @@ class TestList: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: list_ = client.coins.list.get() assert_matches_type(ListGetResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: list_ = client.coins.list.get( @@ -32,7 +32,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(ListGetResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.list.with_raw_response.get() @@ -42,7 +42,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: list_ = response.parse() assert_matches_type(ListGetResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.list.with_streaming_response.get() as response: @@ -54,13 +54,13 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_new(self, client: Coingecko) -> None: list_ = client.coins.list.get_new() assert_matches_type(ListGetNewResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_new(self, client: Coingecko) -> None: response = client.coins.list.with_raw_response.get_new() @@ -70,7 +70,7 @@ def test_raw_response_get_new(self, client: Coingecko) -> None: list_ = response.parse() assert_matches_type(ListGetNewResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_new(self, client: Coingecko) -> None: with client.coins.list.with_streaming_response.get_new() as response: @@ -88,13 +88,13 @@ class TestAsyncList: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: list_ = await async_client.coins.list.get() assert_matches_type(ListGetResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: list_ = await async_client.coins.list.get( @@ -103,7 +103,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(ListGetResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.list.with_raw_response.get() @@ -113,7 +113,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: list_ = await response.parse() assert_matches_type(ListGetResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.list.with_streaming_response.get() as response: @@ -125,13 +125,13 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_new(self, async_client: AsyncCoingecko) -> None: list_ = await async_client.coins.list.get_new() assert_matches_type(ListGetNewResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_new(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.list.with_raw_response.get_new() @@ -141,7 +141,7 @@ async def test_raw_response_get_new(self, async_client: AsyncCoingecko) -> None: list_ = await response.parse() assert_matches_type(ListGetNewResponse, list_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_new(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.list.with_streaming_response.get_new() as response: diff --git a/tests/api_resources/coins/test_market_chart.py b/tests/api_resources/coins/test_market_chart.py index b0eef9c..170c3e1 100644 --- a/tests/api_resources/coins/test_market_chart.py +++ b/tests/api_resources/coins/test_market_chart.py @@ -20,7 +20,7 @@ class TestMarketChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: market_chart = client.coins.market_chart.get( @@ -30,7 +30,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: market_chart = client.coins.market_chart.get( @@ -42,7 +42,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.market_chart.with_raw_response.get( @@ -56,7 +56,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: market_chart = response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.market_chart.with_streaming_response.get( @@ -72,7 +72,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -82,7 +82,7 @@ def test_path_params_get(self, client: Coingecko) -> None: vs_currency="usd", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range(self, client: Coingecko) -> None: market_chart = client.coins.market_chart.get_range( @@ -93,7 +93,7 @@ def test_method_get_range(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range_with_all_params(self, client: Coingecko) -> None: market_chart = client.coins.market_chart.get_range( @@ -106,7 +106,7 @@ def test_method_get_range_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_range(self, client: Coingecko) -> None: response = client.coins.market_chart.with_raw_response.get_range( @@ -121,7 +121,7 @@ def test_raw_response_get_range(self, client: Coingecko) -> None: market_chart = response.parse() assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_range(self, client: Coingecko) -> None: with client.coins.market_chart.with_streaming_response.get_range( @@ -138,7 +138,7 @@ def test_streaming_response_get_range(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_range(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -155,7 +155,7 @@ class TestAsyncMarketChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.market_chart.get( @@ -165,7 +165,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.market_chart.get( @@ -177,7 +177,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.market_chart.with_raw_response.get( @@ -191,7 +191,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: market_chart = await response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.market_chart.with_streaming_response.get( @@ -207,7 +207,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -217,7 +217,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: vs_currency="usd", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.market_chart.get_range( @@ -228,7 +228,7 @@ async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range_with_all_params(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.coins.market_chart.get_range( @@ -241,7 +241,7 @@ async def test_method_get_range_with_all_params(self, async_client: AsyncCoingec ) assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.market_chart.with_raw_response.get_range( @@ -256,7 +256,7 @@ async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> Non market_chart = await response.parse() assert_matches_type(MarketChartGetRangeResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.market_chart.with_streaming_response.get_range( @@ -273,7 +273,7 @@ async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_range(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/coins/test_markets.py b/tests/api_resources/coins/test_markets.py index 39ccaac..31c09c7 100644 --- a/tests/api_resources/coins/test_markets.py +++ b/tests/api_resources/coins/test_markets.py @@ -17,7 +17,7 @@ class TestMarkets: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: market = client.coins.markets.get( @@ -25,13 +25,14 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(MarketGetResponse, market, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: market = client.coins.markets.get( vs_currency="usd", category="layer-1", ids="ids", + include_rehypothecated=True, include_tokens="top", locale="ar", names="names", @@ -45,7 +46,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MarketGetResponse, market, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.markets.with_raw_response.get( @@ -57,7 +58,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: market = response.parse() assert_matches_type(MarketGetResponse, market, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.markets.with_streaming_response.get( @@ -77,7 +78,7 @@ class TestAsyncMarkets: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: market = await async_client.coins.markets.get( @@ -85,13 +86,14 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketGetResponse, market, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: market = await async_client.coins.markets.get( vs_currency="usd", category="layer-1", ids="ids", + include_rehypothecated=True, include_tokens="top", locale="ar", names="names", @@ -105,7 +107,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(MarketGetResponse, market, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.markets.with_raw_response.get( @@ -117,7 +119,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: market = await response.parse() assert_matches_type(MarketGetResponse, market, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.markets.with_streaming_response.get( diff --git a/tests/api_resources/coins/test_ohlc.py b/tests/api_resources/coins/test_ohlc.py index a93dfd0..96c2b55 100644 --- a/tests/api_resources/coins/test_ohlc.py +++ b/tests/api_resources/coins/test_ohlc.py @@ -17,7 +17,7 @@ class TestOhlc: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: ohlc = client.coins.ohlc.get( @@ -27,7 +27,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(OhlcGetResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: ohlc = client.coins.ohlc.get( @@ -39,7 +39,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(OhlcGetResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.ohlc.with_raw_response.get( @@ -53,7 +53,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: ohlc = response.parse() assert_matches_type(OhlcGetResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.ohlc.with_streaming_response.get( @@ -69,7 +69,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -79,7 +79,7 @@ def test_path_params_get(self, client: Coingecko) -> None: vs_currency="usd", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range(self, client: Coingecko) -> None: ohlc = client.coins.ohlc.get_range( @@ -91,7 +91,7 @@ def test_method_get_range(self, client: Coingecko) -> None: ) assert_matches_type(OhlcGetRangeResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_range(self, client: Coingecko) -> None: response = client.coins.ohlc.with_raw_response.get_range( @@ -107,7 +107,7 @@ def test_raw_response_get_range(self, client: Coingecko) -> None: ohlc = response.parse() assert_matches_type(OhlcGetRangeResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_range(self, client: Coingecko) -> None: with client.coins.ohlc.with_streaming_response.get_range( @@ -125,7 +125,7 @@ def test_streaming_response_get_range(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_range(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -143,7 +143,7 @@ class TestAsyncOhlc: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: ohlc = await async_client.coins.ohlc.get( @@ -153,7 +153,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(OhlcGetResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: ohlc = await async_client.coins.ohlc.get( @@ -165,7 +165,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(OhlcGetResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.ohlc.with_raw_response.get( @@ -179,7 +179,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: ohlc = await response.parse() assert_matches_type(OhlcGetResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.ohlc.with_streaming_response.get( @@ -195,7 +195,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -205,7 +205,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: vs_currency="usd", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: ohlc = await async_client.coins.ohlc.get_range( @@ -217,7 +217,7 @@ async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(OhlcGetRangeResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.ohlc.with_raw_response.get_range( @@ -233,7 +233,7 @@ async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> Non ohlc = await response.parse() assert_matches_type(OhlcGetRangeResponse, ohlc, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.ohlc.with_streaming_response.get_range( @@ -251,7 +251,7 @@ async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_range(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/coins/test_tickers.py b/tests/api_resources/coins/test_tickers.py index 144f712..100230a 100644 --- a/tests/api_resources/coins/test_tickers.py +++ b/tests/api_resources/coins/test_tickers.py @@ -17,7 +17,7 @@ class TestTickers: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: ticker = client.coins.tickers.get( @@ -25,7 +25,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: ticker = client.coins.tickers.get( @@ -39,7 +39,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.tickers.with_raw_response.get( @@ -51,7 +51,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: ticker = response.parse() assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.tickers.with_streaming_response.get( @@ -65,7 +65,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -79,7 +79,7 @@ class TestAsyncTickers: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: ticker = await async_client.coins.tickers.get( @@ -87,7 +87,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: ticker = await async_client.coins.tickers.get( @@ -101,7 +101,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.tickers.with_raw_response.get( @@ -113,7 +113,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: ticker = await response.parse() assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.tickers.with_streaming_response.get( @@ -127,7 +127,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/coins/test_top_gainers_losers.py b/tests/api_resources/coins/test_top_gainers_losers.py index 23c8a21..3e66024 100644 --- a/tests/api_resources/coins/test_top_gainers_losers.py +++ b/tests/api_resources/coins/test_top_gainers_losers.py @@ -17,7 +17,7 @@ class TestTopGainersLosers: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: top_gainers_loser = client.coins.top_gainers_losers.get( @@ -25,7 +25,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TopGainersLoserGetResponse, top_gainers_loser, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: top_gainers_loser = client.coins.top_gainers_losers.get( @@ -36,7 +36,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TopGainersLoserGetResponse, top_gainers_loser, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.top_gainers_losers.with_raw_response.get( @@ -48,7 +48,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: top_gainers_loser = response.parse() assert_matches_type(TopGainersLoserGetResponse, top_gainers_loser, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.top_gainers_losers.with_streaming_response.get( @@ -68,7 +68,7 @@ class TestAsyncTopGainersLosers: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: top_gainers_loser = await async_client.coins.top_gainers_losers.get( @@ -76,7 +76,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TopGainersLoserGetResponse, top_gainers_loser, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: top_gainers_loser = await async_client.coins.top_gainers_losers.get( @@ -87,7 +87,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TopGainersLoserGetResponse, top_gainers_loser, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.top_gainers_losers.with_raw_response.get( @@ -99,7 +99,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: top_gainers_loser = await response.parse() assert_matches_type(TopGainersLoserGetResponse, top_gainers_loser, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.top_gainers_losers.with_streaming_response.get( diff --git a/tests/api_resources/coins/test_total_supply_chart.py b/tests/api_resources/coins/test_total_supply_chart.py index ee29418..acbc9e1 100644 --- a/tests/api_resources/coins/test_total_supply_chart.py +++ b/tests/api_resources/coins/test_total_supply_chart.py @@ -20,7 +20,7 @@ class TestTotalSupplyChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: total_supply_chart = client.coins.total_supply_chart.get( @@ -29,7 +29,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TotalSupplyChartGetResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: total_supply_chart = client.coins.total_supply_chart.get( @@ -39,7 +39,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TotalSupplyChartGetResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.coins.total_supply_chart.with_raw_response.get( @@ -52,7 +52,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: total_supply_chart = response.parse() assert_matches_type(TotalSupplyChartGetResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.coins.total_supply_chart.with_streaming_response.get( @@ -67,7 +67,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -76,7 +76,7 @@ def test_path_params_get(self, client: Coingecko) -> None: days="days", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range(self, client: Coingecko) -> None: total_supply_chart = client.coins.total_supply_chart.get_range( @@ -86,7 +86,7 @@ def test_method_get_range(self, client: Coingecko) -> None: ) assert_matches_type(TotalSupplyChartGetRangeResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_range(self, client: Coingecko) -> None: response = client.coins.total_supply_chart.with_raw_response.get_range( @@ -100,7 +100,7 @@ def test_raw_response_get_range(self, client: Coingecko) -> None: total_supply_chart = response.parse() assert_matches_type(TotalSupplyChartGetRangeResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_range(self, client: Coingecko) -> None: with client.coins.total_supply_chart.with_streaming_response.get_range( @@ -116,7 +116,7 @@ def test_streaming_response_get_range(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_range(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -132,7 +132,7 @@ class TestAsyncTotalSupplyChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: total_supply_chart = await async_client.coins.total_supply_chart.get( @@ -141,7 +141,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TotalSupplyChartGetResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: total_supply_chart = await async_client.coins.total_supply_chart.get( @@ -151,7 +151,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TotalSupplyChartGetResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.total_supply_chart.with_raw_response.get( @@ -164,7 +164,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: total_supply_chart = await response.parse() assert_matches_type(TotalSupplyChartGetResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.total_supply_chart.with_streaming_response.get( @@ -179,7 +179,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -188,7 +188,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: days="days", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: total_supply_chart = await async_client.coins.total_supply_chart.get_range( @@ -198,7 +198,7 @@ async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TotalSupplyChartGetRangeResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.total_supply_chart.with_raw_response.get_range( @@ -212,7 +212,7 @@ async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> Non total_supply_chart = await response.parse() assert_matches_type(TotalSupplyChartGetRangeResponse, total_supply_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.total_supply_chart.with_streaming_response.get_range( @@ -228,7 +228,7 @@ async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_range(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/derivatives/test_exchanges.py b/tests/api_resources/derivatives/test_exchanges.py index 64d90f6..99a61bf 100644 --- a/tests/api_resources/derivatives/test_exchanges.py +++ b/tests/api_resources/derivatives/test_exchanges.py @@ -21,13 +21,13 @@ class TestExchanges: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: exchange = client.derivatives.exchanges.get() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: exchange = client.derivatives.exchanges.get( @@ -37,7 +37,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.derivatives.exchanges.with_raw_response.get() @@ -47,7 +47,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: exchange = response.parse() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.derivatives.exchanges.with_streaming_response.get() as response: @@ -59,7 +59,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id(self, client: Coingecko) -> None: exchange = client.derivatives.exchanges.get_id( @@ -67,7 +67,7 @@ def test_method_get_id(self, client: Coingecko) -> None: ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id_with_all_params(self, client: Coingecko) -> None: exchange = client.derivatives.exchanges.get_id( @@ -76,7 +76,7 @@ def test_method_get_id_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_id(self, client: Coingecko) -> None: response = client.derivatives.exchanges.with_raw_response.get_id( @@ -88,7 +88,7 @@ def test_raw_response_get_id(self, client: Coingecko) -> None: exchange = response.parse() assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_id(self, client: Coingecko) -> None: with client.derivatives.exchanges.with_streaming_response.get_id( @@ -102,7 +102,7 @@ def test_streaming_response_get_id(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_id(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -110,13 +110,13 @@ def test_path_params_get_id(self, client: Coingecko) -> None: id="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list(self, client: Coingecko) -> None: exchange = client.derivatives.exchanges.get_list() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_list(self, client: Coingecko) -> None: response = client.derivatives.exchanges.with_raw_response.get_list() @@ -126,7 +126,7 @@ def test_raw_response_get_list(self, client: Coingecko) -> None: exchange = response.parse() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_list(self, client: Coingecko) -> None: with client.derivatives.exchanges.with_streaming_response.get_list() as response: @@ -144,13 +144,13 @@ class TestAsyncExchanges: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.derivatives.exchanges.get() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.derivatives.exchanges.get( @@ -160,7 +160,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.derivatives.exchanges.with_raw_response.get() @@ -170,7 +170,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: exchange = await response.parse() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.derivatives.exchanges.with_streaming_response.get() as response: @@ -182,7 +182,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.derivatives.exchanges.get_id( @@ -190,7 +190,7 @@ async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.derivatives.exchanges.get_id( @@ -199,7 +199,7 @@ async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: response = await async_client.derivatives.exchanges.with_raw_response.get_id( @@ -211,7 +211,7 @@ async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: exchange = await response.parse() assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> None: async with async_client.derivatives.exchanges.with_streaming_response.get_id( @@ -225,7 +225,7 @@ async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -233,13 +233,13 @@ async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: id="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.derivatives.exchanges.get_list() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None: response = await async_client.derivatives.exchanges.with_raw_response.get_list() @@ -249,7 +249,7 @@ async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None exchange = await response.parse() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_list(self, async_client: AsyncCoingecko) -> None: async with async_client.derivatives.exchanges.with_streaming_response.get_list() as response: diff --git a/tests/api_resources/exchanges/test_tickers.py b/tests/api_resources/exchanges/test_tickers.py index c74126d..6814b4c 100644 --- a/tests/api_resources/exchanges/test_tickers.py +++ b/tests/api_resources/exchanges/test_tickers.py @@ -17,7 +17,7 @@ class TestTickers: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: ticker = client.exchanges.tickers.get( @@ -25,7 +25,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: ticker = client.exchanges.tickers.get( @@ -39,7 +39,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.exchanges.tickers.with_raw_response.get( @@ -51,7 +51,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: ticker = response.parse() assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.exchanges.tickers.with_streaming_response.get( @@ -65,7 +65,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -79,7 +79,7 @@ class TestAsyncTickers: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: ticker = await async_client.exchanges.tickers.get( @@ -87,7 +87,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: ticker = await async_client.exchanges.tickers.get( @@ -101,7 +101,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.exchanges.tickers.with_raw_response.get( @@ -113,7 +113,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: ticker = await response.parse() assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.exchanges.tickers.with_streaming_response.get( @@ -127,7 +127,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/exchanges/test_volume_chart.py b/tests/api_resources/exchanges/test_volume_chart.py index f0c9b4b..3fe01cf 100644 --- a/tests/api_resources/exchanges/test_volume_chart.py +++ b/tests/api_resources/exchanges/test_volume_chart.py @@ -20,7 +20,7 @@ class TestVolumeChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: volume_chart = client.exchanges.volume_chart.get( @@ -29,7 +29,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(VolumeChartGetResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.exchanges.volume_chart.with_raw_response.get( @@ -42,7 +42,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: volume_chart = response.parse() assert_matches_type(VolumeChartGetResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.exchanges.volume_chart.with_streaming_response.get( @@ -57,7 +57,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -66,7 +66,7 @@ def test_path_params_get(self, client: Coingecko) -> None: days="1", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_range(self, client: Coingecko) -> None: volume_chart = client.exchanges.volume_chart.get_range( @@ -76,7 +76,7 @@ def test_method_get_range(self, client: Coingecko) -> None: ) assert_matches_type(VolumeChartGetRangeResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_range(self, client: Coingecko) -> None: response = client.exchanges.volume_chart.with_raw_response.get_range( @@ -90,7 +90,7 @@ def test_raw_response_get_range(self, client: Coingecko) -> None: volume_chart = response.parse() assert_matches_type(VolumeChartGetRangeResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_range(self, client: Coingecko) -> None: with client.exchanges.volume_chart.with_streaming_response.get_range( @@ -106,7 +106,7 @@ def test_streaming_response_get_range(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_range(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -122,7 +122,7 @@ class TestAsyncVolumeChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: volume_chart = await async_client.exchanges.volume_chart.get( @@ -131,7 +131,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(VolumeChartGetResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.exchanges.volume_chart.with_raw_response.get( @@ -144,7 +144,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: volume_chart = await response.parse() assert_matches_type(VolumeChartGetResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.exchanges.volume_chart.with_streaming_response.get( @@ -159,7 +159,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -168,7 +168,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: days="1", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: volume_chart = await async_client.exchanges.volume_chart.get_range( @@ -178,7 +178,7 @@ async def test_method_get_range(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(VolumeChartGetRangeResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> None: response = await async_client.exchanges.volume_chart.with_raw_response.get_range( @@ -192,7 +192,7 @@ async def test_raw_response_get_range(self, async_client: AsyncCoingecko) -> Non volume_chart = await response.parse() assert_matches_type(VolumeChartGetRangeResponse, volume_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) -> None: async with async_client.exchanges.volume_chart.with_streaming_response.get_range( @@ -208,7 +208,7 @@ async def test_streaming_response_get_range(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_range(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/global_/test_decentralized_finance_defi.py b/tests/api_resources/global_/test_decentralized_finance_defi.py index 1901076..0f72b86 100644 --- a/tests/api_resources/global_/test_decentralized_finance_defi.py +++ b/tests/api_resources/global_/test_decentralized_finance_defi.py @@ -17,13 +17,13 @@ class TestDecentralizedFinanceDefi: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: decentralized_finance_defi = client.global_.decentralized_finance_defi.get() assert_matches_type(DecentralizedFinanceDefiGetResponse, decentralized_finance_defi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.global_.decentralized_finance_defi.with_raw_response.get() @@ -33,7 +33,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: decentralized_finance_defi = response.parse() assert_matches_type(DecentralizedFinanceDefiGetResponse, decentralized_finance_defi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.global_.decentralized_finance_defi.with_streaming_response.get() as response: @@ -51,13 +51,13 @@ class TestAsyncDecentralizedFinanceDefi: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: decentralized_finance_defi = await async_client.global_.decentralized_finance_defi.get() assert_matches_type(DecentralizedFinanceDefiGetResponse, decentralized_finance_defi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.global_.decentralized_finance_defi.with_raw_response.get() @@ -67,7 +67,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: decentralized_finance_defi = await response.parse() assert_matches_type(DecentralizedFinanceDefiGetResponse, decentralized_finance_defi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.global_.decentralized_finance_defi.with_streaming_response.get() as response: diff --git a/tests/api_resources/global_/test_market_cap_chart.py b/tests/api_resources/global_/test_market_cap_chart.py index 90d3d73..61491a4 100644 --- a/tests/api_resources/global_/test_market_cap_chart.py +++ b/tests/api_resources/global_/test_market_cap_chart.py @@ -17,7 +17,7 @@ class TestMarketCapChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: market_cap_chart = client.global_.market_cap_chart.get( @@ -25,7 +25,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(MarketCapChartGetResponse, market_cap_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: market_cap_chart = client.global_.market_cap_chart.get( @@ -34,7 +34,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MarketCapChartGetResponse, market_cap_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.global_.market_cap_chart.with_raw_response.get( @@ -46,7 +46,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: market_cap_chart = response.parse() assert_matches_type(MarketCapChartGetResponse, market_cap_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.global_.market_cap_chart.with_streaming_response.get( @@ -66,7 +66,7 @@ class TestAsyncMarketCapChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: market_cap_chart = await async_client.global_.market_cap_chart.get( @@ -74,7 +74,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketCapChartGetResponse, market_cap_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: market_cap_chart = await async_client.global_.market_cap_chart.get( @@ -83,7 +83,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(MarketCapChartGetResponse, market_cap_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.global_.market_cap_chart.with_raw_response.get( @@ -95,7 +95,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: market_cap_chart = await response.parse() assert_matches_type(MarketCapChartGetResponse, market_cap_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.global_.market_cap_chart.with_streaming_response.get( diff --git a/tests/api_resources/nfts/contract/test_market_chart.py b/tests/api_resources/nfts/contract/test_market_chart.py index 8e95af5..3d9f6a0 100644 --- a/tests/api_resources/nfts/contract/test_market_chart.py +++ b/tests/api_resources/nfts/contract/test_market_chart.py @@ -17,7 +17,7 @@ class TestMarketChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: market_chart = client.nfts.contract.market_chart.get( @@ -27,7 +27,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.nfts.contract.market_chart.with_raw_response.get( @@ -41,7 +41,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: market_chart = response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.nfts.contract.market_chart.with_streaming_response.get( @@ -57,7 +57,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `asset_platform_id` but received ''"): @@ -80,7 +80,7 @@ class TestAsyncMarketChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.nfts.contract.market_chart.get( @@ -90,7 +90,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.nfts.contract.market_chart.with_raw_response.get( @@ -104,7 +104,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: market_chart = await response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.nfts.contract.market_chart.with_streaming_response.get( @@ -120,7 +120,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `asset_platform_id` but received ''"): diff --git a/tests/api_resources/nfts/test_contract.py b/tests/api_resources/nfts/test_contract.py index 21f93ab..734dd18 100644 --- a/tests/api_resources/nfts/test_contract.py +++ b/tests/api_resources/nfts/test_contract.py @@ -17,7 +17,7 @@ class TestContract: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_contract_address(self, client: Coingecko) -> None: contract = client.nfts.contract.get_contract_address( @@ -26,7 +26,7 @@ def test_method_get_contract_address(self, client: Coingecko) -> None: ) assert_matches_type(ContractGetContractAddressResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_contract_address(self, client: Coingecko) -> None: response = client.nfts.contract.with_raw_response.get_contract_address( @@ -39,7 +39,7 @@ def test_raw_response_get_contract_address(self, client: Coingecko) -> None: contract = response.parse() assert_matches_type(ContractGetContractAddressResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_contract_address(self, client: Coingecko) -> None: with client.nfts.contract.with_streaming_response.get_contract_address( @@ -54,7 +54,7 @@ def test_streaming_response_get_contract_address(self, client: Coingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_contract_address(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `asset_platform_id` but received ''"): @@ -75,7 +75,7 @@ class TestAsyncContract: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_contract_address(self, async_client: AsyncCoingecko) -> None: contract = await async_client.nfts.contract.get_contract_address( @@ -84,7 +84,7 @@ async def test_method_get_contract_address(self, async_client: AsyncCoingecko) - ) assert_matches_type(ContractGetContractAddressResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_contract_address(self, async_client: AsyncCoingecko) -> None: response = await async_client.nfts.contract.with_raw_response.get_contract_address( @@ -97,7 +97,7 @@ async def test_raw_response_get_contract_address(self, async_client: AsyncCoinge contract = await response.parse() assert_matches_type(ContractGetContractAddressResponse, contract, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_contract_address(self, async_client: AsyncCoingecko) -> None: async with async_client.nfts.contract.with_streaming_response.get_contract_address( @@ -112,7 +112,7 @@ async def test_streaming_response_get_contract_address(self, async_client: Async assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_contract_address(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `asset_platform_id` but received ''"): diff --git a/tests/api_resources/nfts/test_market_chart.py b/tests/api_resources/nfts/test_market_chart.py index 4a08803..30334d8 100644 --- a/tests/api_resources/nfts/test_market_chart.py +++ b/tests/api_resources/nfts/test_market_chart.py @@ -17,7 +17,7 @@ class TestMarketChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: market_chart = client.nfts.market_chart.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.nfts.market_chart.with_raw_response.get( @@ -39,7 +39,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: market_chart = response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.nfts.market_chart.with_streaming_response.get( @@ -54,7 +54,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -69,7 +69,7 @@ class TestAsyncMarketChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: market_chart = await async_client.nfts.market_chart.get( @@ -78,7 +78,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.nfts.market_chart.with_raw_response.get( @@ -91,7 +91,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: market_chart = await response.parse() assert_matches_type(MarketChartGetResponse, market_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.nfts.market_chart.with_streaming_response.get( @@ -106,7 +106,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/nfts/test_tickers.py b/tests/api_resources/nfts/test_tickers.py index 3c89b3e..9fbbb1d 100644 --- a/tests/api_resources/nfts/test_tickers.py +++ b/tests/api_resources/nfts/test_tickers.py @@ -17,7 +17,7 @@ class TestTickers: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: ticker = client.nfts.tickers.get( @@ -25,7 +25,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.nfts.tickers.with_raw_response.get( @@ -37,7 +37,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: ticker = response.parse() assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.nfts.tickers.with_streaming_response.get( @@ -51,7 +51,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -65,7 +65,7 @@ class TestAsyncTickers: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: ticker = await async_client.nfts.tickers.get( @@ -73,7 +73,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.nfts.tickers.with_raw_response.get( @@ -85,7 +85,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: ticker = await response.parse() assert_matches_type(TickerGetResponse, ticker, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.nfts.tickers.with_streaming_response.get( @@ -99,7 +99,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/onchain/networks/pools/test_info.py b/tests/api_resources/onchain/networks/pools/test_info.py index fb00f4f..6c28a0a 100644 --- a/tests/api_resources/onchain/networks/pools/test_info.py +++ b/tests/api_resources/onchain/networks/pools/test_info.py @@ -17,7 +17,7 @@ class TestInfo: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: info = client.onchain.networks.pools.info.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: info = client.onchain.networks.pools.info.get( @@ -36,7 +36,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.pools.info.with_raw_response.get( @@ -49,7 +49,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: info = response.parse() assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.pools.info.with_streaming_response.get( @@ -64,7 +64,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -85,7 +85,7 @@ class TestAsyncInfo: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: info = await async_client.onchain.networks.pools.info.get( @@ -94,7 +94,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: info = await async_client.onchain.networks.pools.info.get( @@ -104,7 +104,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.pools.info.with_raw_response.get( @@ -117,7 +117,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: info = await response.parse() assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.pools.info.with_streaming_response.get( @@ -132,7 +132,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/pools/test_multi.py b/tests/api_resources/onchain/networks/pools/test_multi.py index a8eb06f..1d44ba5 100644 --- a/tests/api_resources/onchain/networks/pools/test_multi.py +++ b/tests/api_resources/onchain/networks/pools/test_multi.py @@ -17,7 +17,7 @@ class TestMulti: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_addresses(self, client: Coingecko) -> None: multi = client.onchain.networks.pools.multi.get_addresses( @@ -26,7 +26,7 @@ def test_method_get_addresses(self, client: Coingecko) -> None: ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_addresses_with_all_params(self, client: Coingecko) -> None: multi = client.onchain.networks.pools.multi.get_addresses( @@ -38,7 +38,7 @@ def test_method_get_addresses_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_addresses(self, client: Coingecko) -> None: response = client.onchain.networks.pools.multi.with_raw_response.get_addresses( @@ -51,7 +51,7 @@ def test_raw_response_get_addresses(self, client: Coingecko) -> None: multi = response.parse() assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_addresses(self, client: Coingecko) -> None: with client.onchain.networks.pools.multi.with_streaming_response.get_addresses( @@ -66,7 +66,7 @@ def test_streaming_response_get_addresses(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_addresses(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -87,7 +87,7 @@ class TestAsyncMulti: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_addresses(self, async_client: AsyncCoingecko) -> None: multi = await async_client.onchain.networks.pools.multi.get_addresses( @@ -96,7 +96,7 @@ async def test_method_get_addresses(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_addresses_with_all_params(self, async_client: AsyncCoingecko) -> None: multi = await async_client.onchain.networks.pools.multi.get_addresses( @@ -108,7 +108,7 @@ async def test_method_get_addresses_with_all_params(self, async_client: AsyncCoi ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_addresses(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.pools.multi.with_raw_response.get_addresses( @@ -121,7 +121,7 @@ async def test_raw_response_get_addresses(self, async_client: AsyncCoingecko) -> multi = await response.parse() assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_addresses(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.pools.multi.with_streaming_response.get_addresses( @@ -136,7 +136,7 @@ async def test_streaming_response_get_addresses(self, async_client: AsyncCoingec assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_addresses(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/pools/test_ohlcv.py b/tests/api_resources/onchain/networks/pools/test_ohlcv.py index eb0eca9..69b37e3 100644 --- a/tests/api_resources/onchain/networks/pools/test_ohlcv.py +++ b/tests/api_resources/onchain/networks/pools/test_ohlcv.py @@ -17,7 +17,7 @@ class TestOhlcv: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_timeframe(self, client: Coingecko) -> None: ohlcv = client.onchain.networks.pools.ohlcv.get_timeframe( @@ -27,7 +27,7 @@ def test_method_get_timeframe(self, client: Coingecko) -> None: ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_timeframe_with_all_params(self, client: Coingecko) -> None: ohlcv = client.onchain.networks.pools.ohlcv.get_timeframe( @@ -43,7 +43,7 @@ def test_method_get_timeframe_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_timeframe(self, client: Coingecko) -> None: response = client.onchain.networks.pools.ohlcv.with_raw_response.get_timeframe( @@ -57,7 +57,7 @@ def test_raw_response_get_timeframe(self, client: Coingecko) -> None: ohlcv = response.parse() assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_timeframe(self, client: Coingecko) -> None: with client.onchain.networks.pools.ohlcv.with_streaming_response.get_timeframe( @@ -73,7 +73,7 @@ def test_streaming_response_get_timeframe(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_timeframe(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -96,7 +96,7 @@ class TestAsyncOhlcv: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_timeframe(self, async_client: AsyncCoingecko) -> None: ohlcv = await async_client.onchain.networks.pools.ohlcv.get_timeframe( @@ -106,7 +106,7 @@ async def test_method_get_timeframe(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_timeframe_with_all_params(self, async_client: AsyncCoingecko) -> None: ohlcv = await async_client.onchain.networks.pools.ohlcv.get_timeframe( @@ -122,7 +122,7 @@ async def test_method_get_timeframe_with_all_params(self, async_client: AsyncCoi ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_timeframe(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.pools.ohlcv.with_raw_response.get_timeframe( @@ -136,7 +136,7 @@ async def test_raw_response_get_timeframe(self, async_client: AsyncCoingecko) -> ohlcv = await response.parse() assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_timeframe(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.pools.ohlcv.with_streaming_response.get_timeframe( @@ -152,7 +152,7 @@ async def test_streaming_response_get_timeframe(self, async_client: AsyncCoingec assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_timeframe(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/pools/test_trades.py b/tests/api_resources/onchain/networks/pools/test_trades.py index 042efce..dffd89e 100644 --- a/tests/api_resources/onchain/networks/pools/test_trades.py +++ b/tests/api_resources/onchain/networks/pools/test_trades.py @@ -17,7 +17,7 @@ class TestTrades: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: trade = client.onchain.networks.pools.trades.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: trade = client.onchain.networks.pools.trades.get( @@ -37,7 +37,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.pools.trades.with_raw_response.get( @@ -50,7 +50,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: trade = response.parse() assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.pools.trades.with_streaming_response.get( @@ -65,7 +65,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -86,7 +86,7 @@ class TestAsyncTrades: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: trade = await async_client.onchain.networks.pools.trades.get( @@ -95,7 +95,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: trade = await async_client.onchain.networks.pools.trades.get( @@ -106,7 +106,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.pools.trades.with_raw_response.get( @@ -119,7 +119,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: trade = await response.parse() assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.pools.trades.with_streaming_response.get( @@ -134,7 +134,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/test_dexes.py b/tests/api_resources/onchain/networks/test_dexes.py index 63225c1..5bc3c78 100644 --- a/tests/api_resources/onchain/networks/test_dexes.py +++ b/tests/api_resources/onchain/networks/test_dexes.py @@ -20,7 +20,7 @@ class TestDexes: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: dex = client.onchain.networks.dexes.get( @@ -28,7 +28,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(DexGetResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: dex = client.onchain.networks.dexes.get( @@ -37,7 +37,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(DexGetResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.dexes.with_raw_response.get( @@ -49,7 +49,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: dex = response.parse() assert_matches_type(DexGetResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.dexes.with_streaming_response.get( @@ -63,7 +63,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -71,7 +71,7 @@ def test_path_params_get(self, client: Coingecko) -> None: network="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_pools(self, client: Coingecko) -> None: dex = client.onchain.networks.dexes.get_pools( @@ -80,7 +80,7 @@ def test_method_get_pools(self, client: Coingecko) -> None: ) assert_matches_type(DexGetPoolsResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_pools_with_all_params(self, client: Coingecko) -> None: dex = client.onchain.networks.dexes.get_pools( @@ -93,7 +93,7 @@ def test_method_get_pools_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(DexGetPoolsResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_pools(self, client: Coingecko) -> None: response = client.onchain.networks.dexes.with_raw_response.get_pools( @@ -106,7 +106,7 @@ def test_raw_response_get_pools(self, client: Coingecko) -> None: dex = response.parse() assert_matches_type(DexGetPoolsResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_pools(self, client: Coingecko) -> None: with client.onchain.networks.dexes.with_streaming_response.get_pools( @@ -121,7 +121,7 @@ def test_streaming_response_get_pools(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_pools(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -142,7 +142,7 @@ class TestAsyncDexes: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: dex = await async_client.onchain.networks.dexes.get( @@ -150,7 +150,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(DexGetResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: dex = await async_client.onchain.networks.dexes.get( @@ -159,7 +159,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(DexGetResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.dexes.with_raw_response.get( @@ -171,7 +171,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: dex = await response.parse() assert_matches_type(DexGetResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.dexes.with_streaming_response.get( @@ -185,7 +185,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -193,7 +193,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: network="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_pools(self, async_client: AsyncCoingecko) -> None: dex = await async_client.onchain.networks.dexes.get_pools( @@ -202,7 +202,7 @@ async def test_method_get_pools(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(DexGetPoolsResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_pools_with_all_params(self, async_client: AsyncCoingecko) -> None: dex = await async_client.onchain.networks.dexes.get_pools( @@ -215,7 +215,7 @@ async def test_method_get_pools_with_all_params(self, async_client: AsyncCoingec ) assert_matches_type(DexGetPoolsResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_pools(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.dexes.with_raw_response.get_pools( @@ -228,7 +228,7 @@ async def test_raw_response_get_pools(self, async_client: AsyncCoingecko) -> Non dex = await response.parse() assert_matches_type(DexGetPoolsResponse, dex, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_pools(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.dexes.with_streaming_response.get_pools( @@ -243,7 +243,7 @@ async def test_streaming_response_get_pools(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_pools(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/test_new_pools.py b/tests/api_resources/onchain/networks/test_new_pools.py index 14b86ba..561f9c5 100644 --- a/tests/api_resources/onchain/networks/test_new_pools.py +++ b/tests/api_resources/onchain/networks/test_new_pools.py @@ -20,13 +20,13 @@ class TestNewPools: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: new_pool = client.onchain.networks.new_pools.get() assert_matches_type(NewPoolGetResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: new_pool = client.onchain.networks.new_pools.get( @@ -36,7 +36,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(NewPoolGetResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.new_pools.with_raw_response.get() @@ -46,7 +46,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: new_pool = response.parse() assert_matches_type(NewPoolGetResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.new_pools.with_streaming_response.get() as response: @@ -58,7 +58,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_network(self, client: Coingecko) -> None: new_pool = client.onchain.networks.new_pools.get_network( @@ -66,7 +66,7 @@ def test_method_get_network(self, client: Coingecko) -> None: ) assert_matches_type(NewPoolGetNetworkResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_network_with_all_params(self, client: Coingecko) -> None: new_pool = client.onchain.networks.new_pools.get_network( @@ -77,7 +77,7 @@ def test_method_get_network_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(NewPoolGetNetworkResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_network(self, client: Coingecko) -> None: response = client.onchain.networks.new_pools.with_raw_response.get_network( @@ -89,7 +89,7 @@ def test_raw_response_get_network(self, client: Coingecko) -> None: new_pool = response.parse() assert_matches_type(NewPoolGetNetworkResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_network(self, client: Coingecko) -> None: with client.onchain.networks.new_pools.with_streaming_response.get_network( @@ -103,7 +103,7 @@ def test_streaming_response_get_network(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_network(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -117,13 +117,13 @@ class TestAsyncNewPools: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: new_pool = await async_client.onchain.networks.new_pools.get() assert_matches_type(NewPoolGetResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: new_pool = await async_client.onchain.networks.new_pools.get( @@ -133,7 +133,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(NewPoolGetResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.new_pools.with_raw_response.get() @@ -143,7 +143,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: new_pool = await response.parse() assert_matches_type(NewPoolGetResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.new_pools.with_streaming_response.get() as response: @@ -155,7 +155,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_network(self, async_client: AsyncCoingecko) -> None: new_pool = await async_client.onchain.networks.new_pools.get_network( @@ -163,7 +163,7 @@ async def test_method_get_network(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(NewPoolGetNetworkResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_network_with_all_params(self, async_client: AsyncCoingecko) -> None: new_pool = await async_client.onchain.networks.new_pools.get_network( @@ -174,7 +174,7 @@ async def test_method_get_network_with_all_params(self, async_client: AsyncCoing ) assert_matches_type(NewPoolGetNetworkResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_network(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.new_pools.with_raw_response.get_network( @@ -186,7 +186,7 @@ async def test_raw_response_get_network(self, async_client: AsyncCoingecko) -> N new_pool = await response.parse() assert_matches_type(NewPoolGetNetworkResponse, new_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_network(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.new_pools.with_streaming_response.get_network( @@ -200,7 +200,7 @@ async def test_streaming_response_get_network(self, async_client: AsyncCoingecko assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_network(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/test_pools.py b/tests/api_resources/onchain/networks/test_pools.py index 1b4f250..ae7b137 100644 --- a/tests/api_resources/onchain/networks/test_pools.py +++ b/tests/api_resources/onchain/networks/test_pools.py @@ -20,7 +20,7 @@ class TestPools: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: pool = client.onchain.networks.pools.get( @@ -28,7 +28,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: pool = client.onchain.networks.pools.get( @@ -40,7 +40,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.pools.with_raw_response.get( @@ -52,7 +52,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: pool = response.parse() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.pools.with_streaming_response.get( @@ -66,7 +66,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -74,7 +74,7 @@ def test_path_params_get(self, client: Coingecko) -> None: network="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_address(self, client: Coingecko) -> None: pool = client.onchain.networks.pools.get_address( @@ -83,7 +83,7 @@ def test_method_get_address(self, client: Coingecko) -> None: ) assert_matches_type(PoolGetAddressResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_address_with_all_params(self, client: Coingecko) -> None: pool = client.onchain.networks.pools.get_address( @@ -95,7 +95,7 @@ def test_method_get_address_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(PoolGetAddressResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_address(self, client: Coingecko) -> None: response = client.onchain.networks.pools.with_raw_response.get_address( @@ -108,7 +108,7 @@ def test_raw_response_get_address(self, client: Coingecko) -> None: pool = response.parse() assert_matches_type(PoolGetAddressResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_address(self, client: Coingecko) -> None: with client.onchain.networks.pools.with_streaming_response.get_address( @@ -123,7 +123,7 @@ def test_streaming_response_get_address(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_address(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -144,7 +144,7 @@ class TestAsyncPools: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.networks.pools.get( @@ -152,7 +152,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.networks.pools.get( @@ -164,7 +164,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.pools.with_raw_response.get( @@ -176,7 +176,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: pool = await response.parse() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.pools.with_streaming_response.get( @@ -190,7 +190,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -198,7 +198,7 @@ async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: network="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_address(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.networks.pools.get_address( @@ -207,7 +207,7 @@ async def test_method_get_address(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(PoolGetAddressResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_address_with_all_params(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.networks.pools.get_address( @@ -219,7 +219,7 @@ async def test_method_get_address_with_all_params(self, async_client: AsyncCoing ) assert_matches_type(PoolGetAddressResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_address(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.pools.with_raw_response.get_address( @@ -232,7 +232,7 @@ async def test_raw_response_get_address(self, async_client: AsyncCoingecko) -> N pool = await response.parse() assert_matches_type(PoolGetAddressResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_address(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.pools.with_streaming_response.get_address( @@ -247,7 +247,7 @@ async def test_streaming_response_get_address(self, async_client: AsyncCoingecko assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_address(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/test_tokens.py b/tests/api_resources/onchain/networks/test_tokens.py index 8981964..8b2f5cb 100644 --- a/tests/api_resources/onchain/networks/test_tokens.py +++ b/tests/api_resources/onchain/networks/test_tokens.py @@ -17,7 +17,7 @@ class TestTokens: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_address(self, client: Coingecko) -> None: token = client.onchain.networks.tokens.get_address( @@ -26,7 +26,7 @@ def test_method_get_address(self, client: Coingecko) -> None: ) assert_matches_type(TokenGetAddressResponse, token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_address_with_all_params(self, client: Coingecko) -> None: token = client.onchain.networks.tokens.get_address( @@ -38,7 +38,7 @@ def test_method_get_address_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TokenGetAddressResponse, token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_address(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.with_raw_response.get_address( @@ -51,7 +51,7 @@ def test_raw_response_get_address(self, client: Coingecko) -> None: token = response.parse() assert_matches_type(TokenGetAddressResponse, token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_address(self, client: Coingecko) -> None: with client.onchain.networks.tokens.with_streaming_response.get_address( @@ -66,7 +66,7 @@ def test_streaming_response_get_address(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_address(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -87,7 +87,7 @@ class TestAsyncTokens: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_address(self, async_client: AsyncCoingecko) -> None: token = await async_client.onchain.networks.tokens.get_address( @@ -96,7 +96,7 @@ async def test_method_get_address(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TokenGetAddressResponse, token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_address_with_all_params(self, async_client: AsyncCoingecko) -> None: token = await async_client.onchain.networks.tokens.get_address( @@ -108,7 +108,7 @@ async def test_method_get_address_with_all_params(self, async_client: AsyncCoing ) assert_matches_type(TokenGetAddressResponse, token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_address(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.with_raw_response.get_address( @@ -121,7 +121,7 @@ async def test_raw_response_get_address(self, async_client: AsyncCoingecko) -> N token = await response.parse() assert_matches_type(TokenGetAddressResponse, token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_address(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.with_streaming_response.get_address( @@ -136,7 +136,7 @@ async def test_streaming_response_get_address(self, async_client: AsyncCoingecko assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_address(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/test_trending_pools.py b/tests/api_resources/onchain/networks/test_trending_pools.py index 06bcf9d..4174ccb 100644 --- a/tests/api_resources/onchain/networks/test_trending_pools.py +++ b/tests/api_resources/onchain/networks/test_trending_pools.py @@ -20,13 +20,13 @@ class TestTrendingPools: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: trending_pool = client.onchain.networks.trending_pools.get() assert_matches_type(TrendingPoolGetResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: trending_pool = client.onchain.networks.trending_pools.get( @@ -37,7 +37,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TrendingPoolGetResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.trending_pools.with_raw_response.get() @@ -47,7 +47,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: trending_pool = response.parse() assert_matches_type(TrendingPoolGetResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.trending_pools.with_streaming_response.get() as response: @@ -59,7 +59,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_network(self, client: Coingecko) -> None: trending_pool = client.onchain.networks.trending_pools.get_network( @@ -67,7 +67,7 @@ def test_method_get_network(self, client: Coingecko) -> None: ) assert_matches_type(TrendingPoolGetNetworkResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_network_with_all_params(self, client: Coingecko) -> None: trending_pool = client.onchain.networks.trending_pools.get_network( @@ -79,7 +79,7 @@ def test_method_get_network_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TrendingPoolGetNetworkResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_network(self, client: Coingecko) -> None: response = client.onchain.networks.trending_pools.with_raw_response.get_network( @@ -91,7 +91,7 @@ def test_raw_response_get_network(self, client: Coingecko) -> None: trending_pool = response.parse() assert_matches_type(TrendingPoolGetNetworkResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_network(self, client: Coingecko) -> None: with client.onchain.networks.trending_pools.with_streaming_response.get_network( @@ -105,7 +105,7 @@ def test_streaming_response_get_network(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_network(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -119,13 +119,13 @@ class TestAsyncTrendingPools: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: trending_pool = await async_client.onchain.networks.trending_pools.get() assert_matches_type(TrendingPoolGetResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: trending_pool = await async_client.onchain.networks.trending_pools.get( @@ -136,7 +136,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TrendingPoolGetResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.trending_pools.with_raw_response.get() @@ -146,7 +146,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: trending_pool = await response.parse() assert_matches_type(TrendingPoolGetResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.trending_pools.with_streaming_response.get() as response: @@ -158,7 +158,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_network(self, async_client: AsyncCoingecko) -> None: trending_pool = await async_client.onchain.networks.trending_pools.get_network( @@ -166,7 +166,7 @@ async def test_method_get_network(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TrendingPoolGetNetworkResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_network_with_all_params(self, async_client: AsyncCoingecko) -> None: trending_pool = await async_client.onchain.networks.trending_pools.get_network( @@ -178,7 +178,7 @@ async def test_method_get_network_with_all_params(self, async_client: AsyncCoing ) assert_matches_type(TrendingPoolGetNetworkResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_network(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.trending_pools.with_raw_response.get_network( @@ -190,7 +190,7 @@ async def test_raw_response_get_network(self, async_client: AsyncCoingecko) -> N trending_pool = await response.parse() assert_matches_type(TrendingPoolGetNetworkResponse, trending_pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_network(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.trending_pools.with_streaming_response.get_network( @@ -204,7 +204,7 @@ async def test_streaming_response_get_network(self, async_client: AsyncCoingecko assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_network(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_holders_chart.py b/tests/api_resources/onchain/networks/tokens/test_holders_chart.py index ca90159..797b1d6 100644 --- a/tests/api_resources/onchain/networks/tokens/test_holders_chart.py +++ b/tests/api_resources/onchain/networks/tokens/test_holders_chart.py @@ -17,7 +17,7 @@ class TestHoldersChart: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: holders_chart = client.onchain.networks.tokens.holders_chart.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(HoldersChartGetResponse, holders_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: holders_chart = client.onchain.networks.tokens.holders_chart.get( @@ -36,7 +36,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(HoldersChartGetResponse, holders_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.holders_chart.with_raw_response.get( @@ -49,7 +49,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: holders_chart = response.parse() assert_matches_type(HoldersChartGetResponse, holders_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.tokens.holders_chart.with_streaming_response.get( @@ -64,7 +64,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -85,7 +85,7 @@ class TestAsyncHoldersChart: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: holders_chart = await async_client.onchain.networks.tokens.holders_chart.get( @@ -94,7 +94,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(HoldersChartGetResponse, holders_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: holders_chart = await async_client.onchain.networks.tokens.holders_chart.get( @@ -104,7 +104,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(HoldersChartGetResponse, holders_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.holders_chart.with_raw_response.get( @@ -117,7 +117,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: holders_chart = await response.parse() assert_matches_type(HoldersChartGetResponse, holders_chart, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.holders_chart.with_streaming_response.get( @@ -132,7 +132,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_info.py b/tests/api_resources/onchain/networks/tokens/test_info.py index 0d70f44..bd9f7b5 100644 --- a/tests/api_resources/onchain/networks/tokens/test_info.py +++ b/tests/api_resources/onchain/networks/tokens/test_info.py @@ -17,7 +17,7 @@ class TestInfo: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: info = client.onchain.networks.tokens.info.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.info.with_raw_response.get( @@ -39,7 +39,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: info = response.parse() assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.tokens.info.with_streaming_response.get( @@ -54,7 +54,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -75,7 +75,7 @@ class TestAsyncInfo: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: info = await async_client.onchain.networks.tokens.info.get( @@ -84,7 +84,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.info.with_raw_response.get( @@ -97,7 +97,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: info = await response.parse() assert_matches_type(InfoGetResponse, info, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.info.with_streaming_response.get( @@ -112,7 +112,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_multi.py b/tests/api_resources/onchain/networks/tokens/test_multi.py index 756ba80..c2637f8 100644 --- a/tests/api_resources/onchain/networks/tokens/test_multi.py +++ b/tests/api_resources/onchain/networks/tokens/test_multi.py @@ -17,7 +17,7 @@ class TestMulti: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_addresses(self, client: Coingecko) -> None: multi = client.onchain.networks.tokens.multi.get_addresses( @@ -26,7 +26,7 @@ def test_method_get_addresses(self, client: Coingecko) -> None: ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_addresses_with_all_params(self, client: Coingecko) -> None: multi = client.onchain.networks.tokens.multi.get_addresses( @@ -38,7 +38,7 @@ def test_method_get_addresses_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_addresses(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.multi.with_raw_response.get_addresses( @@ -51,7 +51,7 @@ def test_raw_response_get_addresses(self, client: Coingecko) -> None: multi = response.parse() assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_addresses(self, client: Coingecko) -> None: with client.onchain.networks.tokens.multi.with_streaming_response.get_addresses( @@ -66,7 +66,7 @@ def test_streaming_response_get_addresses(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_addresses(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -87,7 +87,7 @@ class TestAsyncMulti: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_addresses(self, async_client: AsyncCoingecko) -> None: multi = await async_client.onchain.networks.tokens.multi.get_addresses( @@ -96,7 +96,7 @@ async def test_method_get_addresses(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_addresses_with_all_params(self, async_client: AsyncCoingecko) -> None: multi = await async_client.onchain.networks.tokens.multi.get_addresses( @@ -108,7 +108,7 @@ async def test_method_get_addresses_with_all_params(self, async_client: AsyncCoi ) assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_addresses(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.multi.with_raw_response.get_addresses( @@ -121,7 +121,7 @@ async def test_raw_response_get_addresses(self, async_client: AsyncCoingecko) -> multi = await response.parse() assert_matches_type(MultiGetAddressesResponse, multi, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_addresses(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.multi.with_streaming_response.get_addresses( @@ -136,7 +136,7 @@ async def test_streaming_response_get_addresses(self, async_client: AsyncCoingec assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_addresses(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_ohlcv.py b/tests/api_resources/onchain/networks/tokens/test_ohlcv.py index c92e5a7..8483280 100644 --- a/tests/api_resources/onchain/networks/tokens/test_ohlcv.py +++ b/tests/api_resources/onchain/networks/tokens/test_ohlcv.py @@ -17,7 +17,7 @@ class TestOhlcv: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_timeframe(self, client: Coingecko) -> None: ohlcv = client.onchain.networks.tokens.ohlcv.get_timeframe( @@ -27,7 +27,7 @@ def test_method_get_timeframe(self, client: Coingecko) -> None: ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_timeframe_with_all_params(self, client: Coingecko) -> None: ohlcv = client.onchain.networks.tokens.ohlcv.get_timeframe( @@ -43,7 +43,7 @@ def test_method_get_timeframe_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_timeframe(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.ohlcv.with_raw_response.get_timeframe( @@ -57,7 +57,7 @@ def test_raw_response_get_timeframe(self, client: Coingecko) -> None: ohlcv = response.parse() assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_timeframe(self, client: Coingecko) -> None: with client.onchain.networks.tokens.ohlcv.with_streaming_response.get_timeframe( @@ -73,7 +73,7 @@ def test_streaming_response_get_timeframe(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_timeframe(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -96,7 +96,7 @@ class TestAsyncOhlcv: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_timeframe(self, async_client: AsyncCoingecko) -> None: ohlcv = await async_client.onchain.networks.tokens.ohlcv.get_timeframe( @@ -106,7 +106,7 @@ async def test_method_get_timeframe(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_timeframe_with_all_params(self, async_client: AsyncCoingecko) -> None: ohlcv = await async_client.onchain.networks.tokens.ohlcv.get_timeframe( @@ -122,7 +122,7 @@ async def test_method_get_timeframe_with_all_params(self, async_client: AsyncCoi ) assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_timeframe(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.ohlcv.with_raw_response.get_timeframe( @@ -136,7 +136,7 @@ async def test_raw_response_get_timeframe(self, async_client: AsyncCoingecko) -> ohlcv = await response.parse() assert_matches_type(OhlcvGetTimeframeResponse, ohlcv, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_timeframe(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.ohlcv.with_streaming_response.get_timeframe( @@ -152,7 +152,7 @@ async def test_streaming_response_get_timeframe(self, async_client: AsyncCoingec assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_timeframe(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_pools.py b/tests/api_resources/onchain/networks/tokens/test_pools.py index d569925..3674593 100644 --- a/tests/api_resources/onchain/networks/tokens/test_pools.py +++ b/tests/api_resources/onchain/networks/tokens/test_pools.py @@ -17,7 +17,7 @@ class TestPools: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: pool = client.onchain.networks.tokens.pools.get( @@ -26,20 +26,21 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: pool = client.onchain.networks.tokens.pools.get( token_address="0xdac17f958d2ee523a2206206994597c13d831ec7", network="eth", include="include", + include_gt_community_data=True, include_inactive_source=True, page=0, sort="h24_volume_usd_liquidity_desc", ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.pools.with_raw_response.get( @@ -52,7 +53,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: pool = response.parse() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.tokens.pools.with_streaming_response.get( @@ -67,7 +68,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -88,7 +89,7 @@ class TestAsyncPools: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.networks.tokens.pools.get( @@ -97,20 +98,21 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.networks.tokens.pools.get( token_address="0xdac17f958d2ee523a2206206994597c13d831ec7", network="eth", include="include", + include_gt_community_data=True, include_inactive_source=True, page=0, sort="h24_volume_usd_liquidity_desc", ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.pools.with_raw_response.get( @@ -123,7 +125,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: pool = await response.parse() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.pools.with_streaming_response.get( @@ -138,7 +140,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_top_holders.py b/tests/api_resources/onchain/networks/tokens/test_top_holders.py index e68efd9..96f0e35 100644 --- a/tests/api_resources/onchain/networks/tokens/test_top_holders.py +++ b/tests/api_resources/onchain/networks/tokens/test_top_holders.py @@ -17,7 +17,7 @@ class TestTopHolders: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: top_holder = client.onchain.networks.tokens.top_holders.get( @@ -26,17 +26,18 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TopHolderGetResponse, top_holder, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: top_holder = client.onchain.networks.tokens.top_holders.get( address="0x6921b130d297cc43754afba22e5eac0fbf8db75b", network="base", holders="holders", + include_pnl_details=True, ) assert_matches_type(TopHolderGetResponse, top_holder, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.top_holders.with_raw_response.get( @@ -49,7 +50,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: top_holder = response.parse() assert_matches_type(TopHolderGetResponse, top_holder, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.tokens.top_holders.with_streaming_response.get( @@ -64,7 +65,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -85,7 +86,7 @@ class TestAsyncTopHolders: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: top_holder = await async_client.onchain.networks.tokens.top_holders.get( @@ -94,17 +95,18 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TopHolderGetResponse, top_holder, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: top_holder = await async_client.onchain.networks.tokens.top_holders.get( address="0x6921b130d297cc43754afba22e5eac0fbf8db75b", network="base", holders="holders", + include_pnl_details=True, ) assert_matches_type(TopHolderGetResponse, top_holder, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.top_holders.with_raw_response.get( @@ -117,7 +119,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: top_holder = await response.parse() assert_matches_type(TopHolderGetResponse, top_holder, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.top_holders.with_streaming_response.get( @@ -132,7 +134,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_top_traders.py b/tests/api_resources/onchain/networks/tokens/test_top_traders.py index 7a42679..f891cd5 100644 --- a/tests/api_resources/onchain/networks/tokens/test_top_traders.py +++ b/tests/api_resources/onchain/networks/tokens/test_top_traders.py @@ -17,7 +17,7 @@ class TestTopTraders: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: top_trader = client.onchain.networks.tokens.top_traders.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TopTraderGetResponse, top_trader, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: top_trader = client.onchain.networks.tokens.top_traders.get( @@ -38,7 +38,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TopTraderGetResponse, top_trader, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.top_traders.with_raw_response.get( @@ -51,7 +51,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: top_trader = response.parse() assert_matches_type(TopTraderGetResponse, top_trader, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.tokens.top_traders.with_streaming_response.get( @@ -66,7 +66,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network_id` but received ''"): @@ -87,7 +87,7 @@ class TestAsyncTopTraders: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: top_trader = await async_client.onchain.networks.tokens.top_traders.get( @@ -96,7 +96,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TopTraderGetResponse, top_trader, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: top_trader = await async_client.onchain.networks.tokens.top_traders.get( @@ -108,7 +108,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TopTraderGetResponse, top_trader, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.top_traders.with_raw_response.get( @@ -121,7 +121,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: top_trader = await response.parse() assert_matches_type(TopTraderGetResponse, top_trader, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.top_traders.with_streaming_response.get( @@ -136,7 +136,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network_id` but received ''"): diff --git a/tests/api_resources/onchain/networks/tokens/test_trades.py b/tests/api_resources/onchain/networks/tokens/test_trades.py index d1eaa68..0177c4e 100644 --- a/tests/api_resources/onchain/networks/tokens/test_trades.py +++ b/tests/api_resources/onchain/networks/tokens/test_trades.py @@ -17,7 +17,7 @@ class TestTrades: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: trade = client.onchain.networks.tokens.trades.get( @@ -26,7 +26,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: trade = client.onchain.networks.tokens.trades.get( @@ -36,7 +36,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.tokens.trades.with_raw_response.get( @@ -49,7 +49,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: trade = response.parse() assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.tokens.trades.with_streaming_response.get( @@ -64,7 +64,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -85,7 +85,7 @@ class TestAsyncTrades: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: trade = await async_client.onchain.networks.tokens.trades.get( @@ -94,7 +94,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: trade = await async_client.onchain.networks.tokens.trades.get( @@ -104,7 +104,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.tokens.trades.with_raw_response.get( @@ -117,7 +117,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: trade = await response.parse() assert_matches_type(TradeGetResponse, trade, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.tokens.trades.with_streaming_response.get( @@ -132,7 +132,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/pools/test_megafilter.py b/tests/api_resources/onchain/pools/test_megafilter.py index dd2c2ec..5b794bf 100644 --- a/tests/api_resources/onchain/pools/test_megafilter.py +++ b/tests/api_resources/onchain/pools/test_megafilter.py @@ -17,13 +17,13 @@ class TestMegafilter: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: megafilter = client.onchain.pools.megafilter.get() assert_matches_type(MegafilterGetResponse, megafilter, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: megafilter = client.onchain.pools.megafilter.get( @@ -44,6 +44,9 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: page=0, pool_created_hour_max=0, pool_created_hour_min=0, + price_change_percentage_duration="5m", + price_change_percentage_max=0, + price_change_percentage_min=0, reserve_in_usd_max=0, reserve_in_usd_min=0, sell_tax_percentage_max=0, @@ -58,7 +61,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(MegafilterGetResponse, megafilter, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.pools.megafilter.with_raw_response.get() @@ -68,7 +71,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: megafilter = response.parse() assert_matches_type(MegafilterGetResponse, megafilter, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.pools.megafilter.with_streaming_response.get() as response: @@ -86,13 +89,13 @@ class TestAsyncMegafilter: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: megafilter = await async_client.onchain.pools.megafilter.get() assert_matches_type(MegafilterGetResponse, megafilter, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: megafilter = await async_client.onchain.pools.megafilter.get( @@ -113,6 +116,9 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> page=0, pool_created_hour_max=0, pool_created_hour_min=0, + price_change_percentage_duration="5m", + price_change_percentage_max=0, + price_change_percentage_min=0, reserve_in_usd_max=0, reserve_in_usd_min=0, sell_tax_percentage_max=0, @@ -127,7 +133,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(MegafilterGetResponse, megafilter, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.pools.megafilter.with_raw_response.get() @@ -137,7 +143,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: megafilter = await response.parse() assert_matches_type(MegafilterGetResponse, megafilter, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.pools.megafilter.with_streaming_response.get() as response: diff --git a/tests/api_resources/onchain/pools/test_trending_search.py b/tests/api_resources/onchain/pools/test_trending_search.py index 107bcae..6e04081 100644 --- a/tests/api_resources/onchain/pools/test_trending_search.py +++ b/tests/api_resources/onchain/pools/test_trending_search.py @@ -17,13 +17,13 @@ class TestTrendingSearch: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: trending_search = client.onchain.pools.trending_search.get() assert_matches_type(TrendingSearchGetResponse, trending_search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: trending_search = client.onchain.pools.trending_search.get( @@ -32,7 +32,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TrendingSearchGetResponse, trending_search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.pools.trending_search.with_raw_response.get() @@ -42,7 +42,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: trending_search = response.parse() assert_matches_type(TrendingSearchGetResponse, trending_search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.pools.trending_search.with_streaming_response.get() as response: @@ -60,13 +60,13 @@ class TestAsyncTrendingSearch: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: trending_search = await async_client.onchain.pools.trending_search.get() assert_matches_type(TrendingSearchGetResponse, trending_search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: trending_search = await async_client.onchain.pools.trending_search.get( @@ -75,7 +75,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TrendingSearchGetResponse, trending_search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.pools.trending_search.with_raw_response.get() @@ -85,7 +85,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: trending_search = await response.parse() assert_matches_type(TrendingSearchGetResponse, trending_search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.pools.trending_search.with_streaming_response.get() as response: diff --git a/tests/api_resources/onchain/search/test_pools.py b/tests/api_resources/onchain/search/test_pools.py index 4a5f69c..e960d12 100644 --- a/tests/api_resources/onchain/search/test_pools.py +++ b/tests/api_resources/onchain/search/test_pools.py @@ -17,13 +17,13 @@ class TestPools: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: pool = client.onchain.search.pools.get() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: pool = client.onchain.search.pools.get( @@ -34,7 +34,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.search.pools.with_raw_response.get() @@ -44,7 +44,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: pool = response.parse() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.search.pools.with_streaming_response.get() as response: @@ -62,13 +62,13 @@ class TestAsyncPools: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.search.pools.get() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: pool = await async_client.onchain.search.pools.get( @@ -79,7 +79,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.search.pools.with_raw_response.get() @@ -89,7 +89,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: pool = await response.parse() assert_matches_type(PoolGetResponse, pool, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.search.pools.with_streaming_response.get() as response: diff --git a/tests/api_resources/onchain/simple/networks/test_token_price.py b/tests/api_resources/onchain/simple/networks/test_token_price.py index d8bcc3f..943fa31 100644 --- a/tests/api_resources/onchain/simple/networks/test_token_price.py +++ b/tests/api_resources/onchain/simple/networks/test_token_price.py @@ -17,7 +17,7 @@ class TestTokenPrice: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_addresses(self, client: Coingecko) -> None: token_price = client.onchain.simple.networks.token_price.get_addresses( @@ -26,7 +26,7 @@ def test_method_get_addresses(self, client: Coingecko) -> None: ) assert_matches_type(TokenPriceGetAddressesResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_addresses_with_all_params(self, client: Coingecko) -> None: token_price = client.onchain.simple.networks.token_price.get_addresses( @@ -41,7 +41,7 @@ def test_method_get_addresses_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TokenPriceGetAddressesResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_addresses(self, client: Coingecko) -> None: response = client.onchain.simple.networks.token_price.with_raw_response.get_addresses( @@ -54,7 +54,7 @@ def test_raw_response_get_addresses(self, client: Coingecko) -> None: token_price = response.parse() assert_matches_type(TokenPriceGetAddressesResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_addresses(self, client: Coingecko) -> None: with client.onchain.simple.networks.token_price.with_streaming_response.get_addresses( @@ -69,7 +69,7 @@ def test_streaming_response_get_addresses(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_addresses(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): @@ -90,7 +90,7 @@ class TestAsyncTokenPrice: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_addresses(self, async_client: AsyncCoingecko) -> None: token_price = await async_client.onchain.simple.networks.token_price.get_addresses( @@ -99,7 +99,7 @@ async def test_method_get_addresses(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TokenPriceGetAddressesResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_addresses_with_all_params(self, async_client: AsyncCoingecko) -> None: token_price = await async_client.onchain.simple.networks.token_price.get_addresses( @@ -114,7 +114,7 @@ async def test_method_get_addresses_with_all_params(self, async_client: AsyncCoi ) assert_matches_type(TokenPriceGetAddressesResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_addresses(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.simple.networks.token_price.with_raw_response.get_addresses( @@ -127,7 +127,7 @@ async def test_raw_response_get_addresses(self, async_client: AsyncCoingecko) -> token_price = await response.parse() assert_matches_type(TokenPriceGetAddressesResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_addresses(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.simple.networks.token_price.with_streaming_response.get_addresses( @@ -142,7 +142,7 @@ async def test_streaming_response_get_addresses(self, async_client: AsyncCoingec assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_addresses(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `network` but received ''"): diff --git a/tests/api_resources/onchain/test_categories.py b/tests/api_resources/onchain/test_categories.py index fde216f..5082825 100644 --- a/tests/api_resources/onchain/test_categories.py +++ b/tests/api_resources/onchain/test_categories.py @@ -20,13 +20,13 @@ class TestCategories: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: category = client.onchain.categories.get() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: category = client.onchain.categories.get( @@ -35,7 +35,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.categories.with_raw_response.get() @@ -45,7 +45,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: category = response.parse() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.categories.with_streaming_response.get() as response: @@ -57,7 +57,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_pools(self, client: Coingecko) -> None: category = client.onchain.categories.get_pools( @@ -65,7 +65,7 @@ def test_method_get_pools(self, client: Coingecko) -> None: ) assert_matches_type(CategoryGetPoolsResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_pools_with_all_params(self, client: Coingecko) -> None: category = client.onchain.categories.get_pools( @@ -76,7 +76,7 @@ def test_method_get_pools_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(CategoryGetPoolsResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_pools(self, client: Coingecko) -> None: response = client.onchain.categories.with_raw_response.get_pools( @@ -88,7 +88,7 @@ def test_raw_response_get_pools(self, client: Coingecko) -> None: category = response.parse() assert_matches_type(CategoryGetPoolsResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_pools(self, client: Coingecko) -> None: with client.onchain.categories.with_streaming_response.get_pools( @@ -102,7 +102,7 @@ def test_streaming_response_get_pools(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_pools(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `category_id` but received ''"): @@ -116,13 +116,13 @@ class TestAsyncCategories: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: category = await async_client.onchain.categories.get() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: category = await async_client.onchain.categories.get( @@ -131,7 +131,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.categories.with_raw_response.get() @@ -141,7 +141,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: category = await response.parse() assert_matches_type(CategoryGetResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.categories.with_streaming_response.get() as response: @@ -153,7 +153,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_pools(self, async_client: AsyncCoingecko) -> None: category = await async_client.onchain.categories.get_pools( @@ -161,7 +161,7 @@ async def test_method_get_pools(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(CategoryGetPoolsResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_pools_with_all_params(self, async_client: AsyncCoingecko) -> None: category = await async_client.onchain.categories.get_pools( @@ -172,7 +172,7 @@ async def test_method_get_pools_with_all_params(self, async_client: AsyncCoingec ) assert_matches_type(CategoryGetPoolsResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_pools(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.categories.with_raw_response.get_pools( @@ -184,7 +184,7 @@ async def test_raw_response_get_pools(self, async_client: AsyncCoingecko) -> Non category = await response.parse() assert_matches_type(CategoryGetPoolsResponse, category, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_pools(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.categories.with_streaming_response.get_pools( @@ -198,7 +198,7 @@ async def test_streaming_response_get_pools(self, async_client: AsyncCoingecko) assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_pools(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `category_id` but received ''"): diff --git a/tests/api_resources/onchain/test_networks.py b/tests/api_resources/onchain/test_networks.py index e9ec87b..a0e9ee2 100644 --- a/tests/api_resources/onchain/test_networks.py +++ b/tests/api_resources/onchain/test_networks.py @@ -17,13 +17,13 @@ class TestNetworks: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: network = client.onchain.networks.get() assert_matches_type(NetworkGetResponse, network, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: network = client.onchain.networks.get( @@ -31,7 +31,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(NetworkGetResponse, network, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.networks.with_raw_response.get() @@ -41,7 +41,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: network = response.parse() assert_matches_type(NetworkGetResponse, network, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.networks.with_streaming_response.get() as response: @@ -59,13 +59,13 @@ class TestAsyncNetworks: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: network = await async_client.onchain.networks.get() assert_matches_type(NetworkGetResponse, network, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: network = await async_client.onchain.networks.get( @@ -73,7 +73,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(NetworkGetResponse, network, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.networks.with_raw_response.get() @@ -83,7 +83,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: network = await response.parse() assert_matches_type(NetworkGetResponse, network, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.networks.with_streaming_response.get() as response: diff --git a/tests/api_resources/onchain/tokens/test_info_recently_updated.py b/tests/api_resources/onchain/tokens/test_info_recently_updated.py index 641d330..af18050 100644 --- a/tests/api_resources/onchain/tokens/test_info_recently_updated.py +++ b/tests/api_resources/onchain/tokens/test_info_recently_updated.py @@ -17,13 +17,13 @@ class TestInfoRecentlyUpdated: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: info_recently_updated = client.onchain.tokens.info_recently_updated.get() assert_matches_type(InfoRecentlyUpdatedGetResponse, info_recently_updated, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: info_recently_updated = client.onchain.tokens.info_recently_updated.get( @@ -32,7 +32,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(InfoRecentlyUpdatedGetResponse, info_recently_updated, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.onchain.tokens.info_recently_updated.with_raw_response.get() @@ -42,7 +42,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: info_recently_updated = response.parse() assert_matches_type(InfoRecentlyUpdatedGetResponse, info_recently_updated, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.onchain.tokens.info_recently_updated.with_streaming_response.get() as response: @@ -60,13 +60,13 @@ class TestAsyncInfoRecentlyUpdated: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: info_recently_updated = await async_client.onchain.tokens.info_recently_updated.get() assert_matches_type(InfoRecentlyUpdatedGetResponse, info_recently_updated, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: info_recently_updated = await async_client.onchain.tokens.info_recently_updated.get( @@ -75,7 +75,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(InfoRecentlyUpdatedGetResponse, info_recently_updated, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.onchain.tokens.info_recently_updated.with_raw_response.get() @@ -85,7 +85,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: info_recently_updated = await response.parse() assert_matches_type(InfoRecentlyUpdatedGetResponse, info_recently_updated, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.onchain.tokens.info_recently_updated.with_streaming_response.get() as response: diff --git a/tests/api_resources/search/test_trending.py b/tests/api_resources/search/test_trending.py index 555399e..63f78a8 100644 --- a/tests/api_resources/search/test_trending.py +++ b/tests/api_resources/search/test_trending.py @@ -17,13 +17,13 @@ class TestTrending: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: trending = client.search.trending.get() assert_matches_type(TrendingGetResponse, trending, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: trending = client.search.trending.get( @@ -31,7 +31,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TrendingGetResponse, trending, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.search.trending.with_raw_response.get() @@ -41,7 +41,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: trending = response.parse() assert_matches_type(TrendingGetResponse, trending, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.search.trending.with_streaming_response.get() as response: @@ -59,13 +59,13 @@ class TestAsyncTrending: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: trending = await async_client.search.trending.get() assert_matches_type(TrendingGetResponse, trending, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: trending = await async_client.search.trending.get( @@ -73,7 +73,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(TrendingGetResponse, trending, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.search.trending.with_raw_response.get() @@ -83,7 +83,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: trending = await response.parse() assert_matches_type(TrendingGetResponse, trending, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.search.trending.with_streaming_response.get() as response: diff --git a/tests/api_resources/simple/test_price.py b/tests/api_resources/simple/test_price.py index 567d0a1..ddc4dbc 100644 --- a/tests/api_resources/simple/test_price.py +++ b/tests/api_resources/simple/test_price.py @@ -17,7 +17,7 @@ class TestPrice: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: price = client.simple.price.get( @@ -25,7 +25,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(PriceGetResponse, price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: price = client.simple.price.get( @@ -42,7 +42,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(PriceGetResponse, price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.simple.price.with_raw_response.get( @@ -54,7 +54,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: price = response.parse() assert_matches_type(PriceGetResponse, price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.simple.price.with_streaming_response.get( @@ -74,7 +74,7 @@ class TestAsyncPrice: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: price = await async_client.simple.price.get( @@ -82,7 +82,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(PriceGetResponse, price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: price = await async_client.simple.price.get( @@ -99,7 +99,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(PriceGetResponse, price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.simple.price.with_raw_response.get( @@ -111,7 +111,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: price = await response.parse() assert_matches_type(PriceGetResponse, price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.simple.price.with_streaming_response.get( diff --git a/tests/api_resources/simple/test_supported_vs_currencies.py b/tests/api_resources/simple/test_supported_vs_currencies.py index 5ad3c9e..d128a0a 100644 --- a/tests/api_resources/simple/test_supported_vs_currencies.py +++ b/tests/api_resources/simple/test_supported_vs_currencies.py @@ -17,13 +17,13 @@ class TestSupportedVsCurrencies: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: supported_vs_currency = client.simple.supported_vs_currencies.get() assert_matches_type(SupportedVsCurrencyGetResponse, supported_vs_currency, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.simple.supported_vs_currencies.with_raw_response.get() @@ -33,7 +33,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: supported_vs_currency = response.parse() assert_matches_type(SupportedVsCurrencyGetResponse, supported_vs_currency, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.simple.supported_vs_currencies.with_streaming_response.get() as response: @@ -51,13 +51,13 @@ class TestAsyncSupportedVsCurrencies: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: supported_vs_currency = await async_client.simple.supported_vs_currencies.get() assert_matches_type(SupportedVsCurrencyGetResponse, supported_vs_currency, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.simple.supported_vs_currencies.with_raw_response.get() @@ -67,7 +67,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: supported_vs_currency = await response.parse() assert_matches_type(SupportedVsCurrencyGetResponse, supported_vs_currency, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.simple.supported_vs_currencies.with_streaming_response.get() as response: diff --git a/tests/api_resources/simple/test_token_price.py b/tests/api_resources/simple/test_token_price.py index c7a4ef8..45e610f 100644 --- a/tests/api_resources/simple/test_token_price.py +++ b/tests/api_resources/simple/test_token_price.py @@ -17,7 +17,7 @@ class TestTokenPrice: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id(self, client: Coingecko) -> None: token_price = client.simple.token_price.get_id( @@ -27,7 +27,7 @@ def test_method_get_id(self, client: Coingecko) -> None: ) assert_matches_type(TokenPriceGetIDResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id_with_all_params(self, client: Coingecko) -> None: token_price = client.simple.token_price.get_id( @@ -42,7 +42,7 @@ def test_method_get_id_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(TokenPriceGetIDResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_id(self, client: Coingecko) -> None: response = client.simple.token_price.with_raw_response.get_id( @@ -56,7 +56,7 @@ def test_raw_response_get_id(self, client: Coingecko) -> None: token_price = response.parse() assert_matches_type(TokenPriceGetIDResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_id(self, client: Coingecko) -> None: with client.simple.token_price.with_streaming_response.get_id( @@ -72,7 +72,7 @@ def test_streaming_response_get_id(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_id(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -88,7 +88,7 @@ class TestAsyncTokenPrice: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: token_price = await async_client.simple.token_price.get_id( @@ -98,7 +98,7 @@ async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TokenPriceGetIDResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) -> None: token_price = await async_client.simple.token_price.get_id( @@ -113,7 +113,7 @@ async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) ) assert_matches_type(TokenPriceGetIDResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: response = await async_client.simple.token_price.with_raw_response.get_id( @@ -127,7 +127,7 @@ async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: token_price = await response.parse() assert_matches_type(TokenPriceGetIDResponse, token_price, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> None: async with async_client.simple.token_price.with_streaming_response.get_id( @@ -143,7 +143,7 @@ async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/test_asset_platforms.py b/tests/api_resources/test_asset_platforms.py index 4fa989b..215ee8c 100644 --- a/tests/api_resources/test_asset_platforms.py +++ b/tests/api_resources/test_asset_platforms.py @@ -17,13 +17,13 @@ class TestAssetPlatforms: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: asset_platform = client.asset_platforms.get() assert_matches_type(AssetPlatformGetResponse, asset_platform, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: asset_platform = client.asset_platforms.get( @@ -31,7 +31,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(AssetPlatformGetResponse, asset_platform, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.asset_platforms.with_raw_response.get() @@ -41,7 +41,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: asset_platform = response.parse() assert_matches_type(AssetPlatformGetResponse, asset_platform, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.asset_platforms.with_streaming_response.get() as response: @@ -59,13 +59,13 @@ class TestAsyncAssetPlatforms: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: asset_platform = await async_client.asset_platforms.get() assert_matches_type(AssetPlatformGetResponse, asset_platform, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: asset_platform = await async_client.asset_platforms.get( @@ -73,7 +73,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(AssetPlatformGetResponse, asset_platform, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.asset_platforms.with_raw_response.get() @@ -83,7 +83,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: asset_platform = await response.parse() assert_matches_type(AssetPlatformGetResponse, asset_platform, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.asset_platforms.with_streaming_response.get() as response: diff --git a/tests/api_resources/test_coins.py b/tests/api_resources/test_coins.py index 15d63c5..8cbf47e 100644 --- a/tests/api_resources/test_coins.py +++ b/tests/api_resources/test_coins.py @@ -17,7 +17,7 @@ class TestCoins: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id(self, client: Coingecko) -> None: coin = client.coins.get_id( @@ -25,7 +25,7 @@ def test_method_get_id(self, client: Coingecko) -> None: ) assert_matches_type(CoinGetIDResponse, coin, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id_with_all_params(self, client: Coingecko) -> None: coin = client.coins.get_id( @@ -41,7 +41,7 @@ def test_method_get_id_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(CoinGetIDResponse, coin, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_id(self, client: Coingecko) -> None: response = client.coins.with_raw_response.get_id( @@ -53,7 +53,7 @@ def test_raw_response_get_id(self, client: Coingecko) -> None: coin = response.parse() assert_matches_type(CoinGetIDResponse, coin, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_id(self, client: Coingecko) -> None: with client.coins.with_streaming_response.get_id( @@ -67,7 +67,7 @@ def test_streaming_response_get_id(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_id(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -81,7 +81,7 @@ class TestAsyncCoins: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: coin = await async_client.coins.get_id( @@ -89,7 +89,7 @@ async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(CoinGetIDResponse, coin, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) -> None: coin = await async_client.coins.get_id( @@ -105,7 +105,7 @@ async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) ) assert_matches_type(CoinGetIDResponse, coin, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: response = await async_client.coins.with_raw_response.get_id( @@ -117,7 +117,7 @@ async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: coin = await response.parse() assert_matches_type(CoinGetIDResponse, coin, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> None: async with async_client.coins.with_streaming_response.get_id( @@ -131,7 +131,7 @@ async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): diff --git a/tests/api_resources/test_derivatives.py b/tests/api_resources/test_derivatives.py index c39267e..3b0dcc4 100644 --- a/tests/api_resources/test_derivatives.py +++ b/tests/api_resources/test_derivatives.py @@ -17,13 +17,13 @@ class TestDerivatives: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: derivative = client.derivatives.get() assert_matches_type(DerivativeGetResponse, derivative, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.derivatives.with_raw_response.get() @@ -33,7 +33,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: derivative = response.parse() assert_matches_type(DerivativeGetResponse, derivative, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.derivatives.with_streaming_response.get() as response: @@ -51,13 +51,13 @@ class TestAsyncDerivatives: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: derivative = await async_client.derivatives.get() assert_matches_type(DerivativeGetResponse, derivative, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.derivatives.with_raw_response.get() @@ -67,7 +67,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: derivative = await response.parse() assert_matches_type(DerivativeGetResponse, derivative, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.derivatives.with_streaming_response.get() as response: diff --git a/tests/api_resources/test_entities.py b/tests/api_resources/test_entities.py index bc81871..3b5b64e 100644 --- a/tests/api_resources/test_entities.py +++ b/tests/api_resources/test_entities.py @@ -17,13 +17,13 @@ class TestEntities: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list(self, client: Coingecko) -> None: entity = client.entities.get_list() assert_matches_type(EntityGetListResponse, entity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list_with_all_params(self, client: Coingecko) -> None: entity = client.entities.get_list( @@ -33,7 +33,7 @@ def test_method_get_list_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(EntityGetListResponse, entity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_list(self, client: Coingecko) -> None: response = client.entities.with_raw_response.get_list() @@ -43,7 +43,7 @@ def test_raw_response_get_list(self, client: Coingecko) -> None: entity = response.parse() assert_matches_type(EntityGetListResponse, entity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_list(self, client: Coingecko) -> None: with client.entities.with_streaming_response.get_list() as response: @@ -61,13 +61,13 @@ class TestAsyncEntities: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list(self, async_client: AsyncCoingecko) -> None: entity = await async_client.entities.get_list() assert_matches_type(EntityGetListResponse, entity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list_with_all_params(self, async_client: AsyncCoingecko) -> None: entity = await async_client.entities.get_list( @@ -77,7 +77,7 @@ async def test_method_get_list_with_all_params(self, async_client: AsyncCoingeck ) assert_matches_type(EntityGetListResponse, entity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None: response = await async_client.entities.with_raw_response.get_list() @@ -87,7 +87,7 @@ async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None entity = await response.parse() assert_matches_type(EntityGetListResponse, entity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_list(self, async_client: AsyncCoingecko) -> None: async with async_client.entities.with_streaming_response.get_list() as response: diff --git a/tests/api_resources/test_exchange_rates.py b/tests/api_resources/test_exchange_rates.py index 7cf749c..526b75a 100644 --- a/tests/api_resources/test_exchange_rates.py +++ b/tests/api_resources/test_exchange_rates.py @@ -17,13 +17,13 @@ class TestExchangeRates: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: exchange_rate = client.exchange_rates.get() assert_matches_type(ExchangeRateGetResponse, exchange_rate, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.exchange_rates.with_raw_response.get() @@ -33,7 +33,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: exchange_rate = response.parse() assert_matches_type(ExchangeRateGetResponse, exchange_rate, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.exchange_rates.with_streaming_response.get() as response: @@ -51,13 +51,13 @@ class TestAsyncExchangeRates: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: exchange_rate = await async_client.exchange_rates.get() assert_matches_type(ExchangeRateGetResponse, exchange_rate, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.exchange_rates.with_raw_response.get() @@ -67,7 +67,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: exchange_rate = await response.parse() assert_matches_type(ExchangeRateGetResponse, exchange_rate, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.exchange_rates.with_streaming_response.get() as response: diff --git a/tests/api_resources/test_exchanges.py b/tests/api_resources/test_exchanges.py index 7ed1d1f..1ee4141 100644 --- a/tests/api_resources/test_exchanges.py +++ b/tests/api_resources/test_exchanges.py @@ -21,13 +21,13 @@ class TestExchanges: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: exchange = client.exchanges.get() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_with_all_params(self, client: Coingecko) -> None: exchange = client.exchanges.get( @@ -36,7 +36,7 @@ def test_method_get_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.exchanges.with_raw_response.get() @@ -46,7 +46,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: exchange = response.parse() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.exchanges.with_streaming_response.get() as response: @@ -58,7 +58,7 @@ def test_streaming_response_get(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id(self, client: Coingecko) -> None: exchange = client.exchanges.get_id( @@ -66,7 +66,7 @@ def test_method_get_id(self, client: Coingecko) -> None: ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id_with_all_params(self, client: Coingecko) -> None: exchange = client.exchanges.get_id( @@ -75,7 +75,7 @@ def test_method_get_id_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_id(self, client: Coingecko) -> None: response = client.exchanges.with_raw_response.get_id( @@ -87,7 +87,7 @@ def test_raw_response_get_id(self, client: Coingecko) -> None: exchange = response.parse() assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_id(self, client: Coingecko) -> None: with client.exchanges.with_streaming_response.get_id( @@ -101,7 +101,7 @@ def test_streaming_response_get_id(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_id(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -109,13 +109,13 @@ def test_path_params_get_id(self, client: Coingecko) -> None: id="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list(self, client: Coingecko) -> None: exchange = client.exchanges.get_list() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list_with_all_params(self, client: Coingecko) -> None: exchange = client.exchanges.get_list( @@ -123,7 +123,7 @@ def test_method_get_list_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_list(self, client: Coingecko) -> None: response = client.exchanges.with_raw_response.get_list() @@ -133,7 +133,7 @@ def test_raw_response_get_list(self, client: Coingecko) -> None: exchange = response.parse() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_list(self, client: Coingecko) -> None: with client.exchanges.with_streaming_response.get_list() as response: @@ -151,13 +151,13 @@ class TestAsyncExchanges: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.exchanges.get() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.exchanges.get( @@ -166,7 +166,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncCoingecko) -> ) assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.exchanges.with_raw_response.get() @@ -176,7 +176,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: exchange = await response.parse() assert_matches_type(ExchangeGetResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.exchanges.with_streaming_response.get() as response: @@ -188,7 +188,7 @@ async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> Non assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.exchanges.get_id( @@ -196,7 +196,7 @@ async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.exchanges.get_id( @@ -205,7 +205,7 @@ async def test_method_get_id_with_all_params(self, async_client: AsyncCoingecko) ) assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: response = await async_client.exchanges.with_raw_response.get_id( @@ -217,7 +217,7 @@ async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: exchange = await response.parse() assert_matches_type(ExchangeGetIDResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> None: async with async_client.exchanges.with_streaming_response.get_id( @@ -231,7 +231,7 @@ async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -239,13 +239,13 @@ async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: id="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.exchanges.get_list() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list_with_all_params(self, async_client: AsyncCoingecko) -> None: exchange = await async_client.exchanges.get_list( @@ -253,7 +253,7 @@ async def test_method_get_list_with_all_params(self, async_client: AsyncCoingeck ) assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None: response = await async_client.exchanges.with_raw_response.get_list() @@ -263,7 +263,7 @@ async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None exchange = await response.parse() assert_matches_type(ExchangeGetListResponse, exchange, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_list(self, async_client: AsyncCoingecko) -> None: async with async_client.exchanges.with_streaming_response.get_list() as response: diff --git a/tests/api_resources/test_global_.py b/tests/api_resources/test_global_.py index 2adea9c..8640bf6 100644 --- a/tests/api_resources/test_global_.py +++ b/tests/api_resources/test_global_.py @@ -17,13 +17,13 @@ class TestGlobal: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: global_ = client.global_.get() assert_matches_type(GlobalGetResponse, global_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.global_.with_raw_response.get() @@ -33,7 +33,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: global_ = response.parse() assert_matches_type(GlobalGetResponse, global_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.global_.with_streaming_response.get() as response: @@ -51,13 +51,13 @@ class TestAsyncGlobal: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: global_ = await async_client.global_.get() assert_matches_type(GlobalGetResponse, global_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.global_.with_raw_response.get() @@ -67,7 +67,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: global_ = await response.parse() assert_matches_type(GlobalGetResponse, global_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.global_.with_streaming_response.get() as response: diff --git a/tests/api_resources/test_key.py b/tests/api_resources/test_key.py index 6aa3aca..c9f799e 100644 --- a/tests/api_resources/test_key.py +++ b/tests/api_resources/test_key.py @@ -17,13 +17,13 @@ class TestKey: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: key = client.key.get() assert_matches_type(KeyGetResponse, key, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.key.with_raw_response.get() @@ -33,7 +33,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: key = response.parse() assert_matches_type(KeyGetResponse, key, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.key.with_streaming_response.get() as response: @@ -51,13 +51,13 @@ class TestAsyncKey: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: key = await async_client.key.get() assert_matches_type(KeyGetResponse, key, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.key.with_raw_response.get() @@ -67,7 +67,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: key = await response.parse() assert_matches_type(KeyGetResponse, key, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.key.with_streaming_response.get() as response: diff --git a/tests/api_resources/test_nfts.py b/tests/api_resources/test_nfts.py index b6779a6..a6406c1 100644 --- a/tests/api_resources/test_nfts.py +++ b/tests/api_resources/test_nfts.py @@ -21,7 +21,7 @@ class TestNFTs: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_id(self, client: Coingecko) -> None: nft = client.nfts.get_id( @@ -29,7 +29,7 @@ def test_method_get_id(self, client: Coingecko) -> None: ) assert_matches_type(NFTGetIDResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_id(self, client: Coingecko) -> None: response = client.nfts.with_raw_response.get_id( @@ -41,7 +41,7 @@ def test_raw_response_get_id(self, client: Coingecko) -> None: nft = response.parse() assert_matches_type(NFTGetIDResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_id(self, client: Coingecko) -> None: with client.nfts.with_streaming_response.get_id( @@ -55,7 +55,7 @@ def test_streaming_response_get_id(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_id(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -63,13 +63,13 @@ def test_path_params_get_id(self, client: Coingecko) -> None: "", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list(self, client: Coingecko) -> None: nft = client.nfts.get_list() assert_matches_type(NFTGetListResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_list_with_all_params(self, client: Coingecko) -> None: nft = client.nfts.get_list( @@ -79,7 +79,7 @@ def test_method_get_list_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(NFTGetListResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_list(self, client: Coingecko) -> None: response = client.nfts.with_raw_response.get_list() @@ -89,7 +89,7 @@ def test_raw_response_get_list(self, client: Coingecko) -> None: nft = response.parse() assert_matches_type(NFTGetListResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_list(self, client: Coingecko) -> None: with client.nfts.with_streaming_response.get_list() as response: @@ -101,13 +101,13 @@ def test_streaming_response_get_list(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_markets(self, client: Coingecko) -> None: nft = client.nfts.get_markets() assert_matches_type(NFTGetMarketsResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_markets_with_all_params(self, client: Coingecko) -> None: nft = client.nfts.get_markets( @@ -118,7 +118,7 @@ def test_method_get_markets_with_all_params(self, client: Coingecko) -> None: ) assert_matches_type(NFTGetMarketsResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_markets(self, client: Coingecko) -> None: response = client.nfts.with_raw_response.get_markets() @@ -128,7 +128,7 @@ def test_raw_response_get_markets(self, client: Coingecko) -> None: nft = response.parse() assert_matches_type(NFTGetMarketsResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_markets(self, client: Coingecko) -> None: with client.nfts.with_streaming_response.get_markets() as response: @@ -146,7 +146,7 @@ class TestAsyncNFTs: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: nft = await async_client.nfts.get_id( @@ -154,7 +154,7 @@ async def test_method_get_id(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(NFTGetIDResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: response = await async_client.nfts.with_raw_response.get_id( @@ -166,7 +166,7 @@ async def test_raw_response_get_id(self, async_client: AsyncCoingecko) -> None: nft = await response.parse() assert_matches_type(NFTGetIDResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> None: async with async_client.nfts.with_streaming_response.get_id( @@ -180,7 +180,7 @@ async def test_streaming_response_get_id(self, async_client: AsyncCoingecko) -> assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `id` but received ''"): @@ -188,13 +188,13 @@ async def test_path_params_get_id(self, async_client: AsyncCoingecko) -> None: "", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list(self, async_client: AsyncCoingecko) -> None: nft = await async_client.nfts.get_list() assert_matches_type(NFTGetListResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_list_with_all_params(self, async_client: AsyncCoingecko) -> None: nft = await async_client.nfts.get_list( @@ -204,7 +204,7 @@ async def test_method_get_list_with_all_params(self, async_client: AsyncCoingeck ) assert_matches_type(NFTGetListResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None: response = await async_client.nfts.with_raw_response.get_list() @@ -214,7 +214,7 @@ async def test_raw_response_get_list(self, async_client: AsyncCoingecko) -> None nft = await response.parse() assert_matches_type(NFTGetListResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_list(self, async_client: AsyncCoingecko) -> None: async with async_client.nfts.with_streaming_response.get_list() as response: @@ -226,13 +226,13 @@ async def test_streaming_response_get_list(self, async_client: AsyncCoingecko) - assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_markets(self, async_client: AsyncCoingecko) -> None: nft = await async_client.nfts.get_markets() assert_matches_type(NFTGetMarketsResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_markets_with_all_params(self, async_client: AsyncCoingecko) -> None: nft = await async_client.nfts.get_markets( @@ -243,7 +243,7 @@ async def test_method_get_markets_with_all_params(self, async_client: AsyncCoing ) assert_matches_type(NFTGetMarketsResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_markets(self, async_client: AsyncCoingecko) -> None: response = await async_client.nfts.with_raw_response.get_markets() @@ -253,7 +253,7 @@ async def test_raw_response_get_markets(self, async_client: AsyncCoingecko) -> N nft = await response.parse() assert_matches_type(NFTGetMarketsResponse, nft, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_markets(self, async_client: AsyncCoingecko) -> None: async with async_client.nfts.with_streaming_response.get_markets() as response: diff --git a/tests/api_resources/test_ping.py b/tests/api_resources/test_ping.py index 4a001fa..30f8b2d 100644 --- a/tests/api_resources/test_ping.py +++ b/tests/api_resources/test_ping.py @@ -17,13 +17,13 @@ class TestPing: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: ping = client.ping.get() assert_matches_type(PingGetResponse, ping, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.ping.with_raw_response.get() @@ -33,7 +33,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: ping = response.parse() assert_matches_type(PingGetResponse, ping, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.ping.with_streaming_response.get() as response: @@ -51,13 +51,13 @@ class TestAsyncPing: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: ping = await async_client.ping.get() assert_matches_type(PingGetResponse, ping, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.ping.with_raw_response.get() @@ -67,7 +67,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: ping = await response.parse() assert_matches_type(PingGetResponse, ping, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.ping.with_streaming_response.get() as response: diff --git a/tests/api_resources/test_public_treasury.py b/tests/api_resources/test_public_treasury.py index 51a23c4..2c2d2d2 100644 --- a/tests/api_resources/test_public_treasury.py +++ b/tests/api_resources/test_public_treasury.py @@ -22,7 +22,7 @@ class TestPublicTreasury: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_coin_id(self, client: Coingecko) -> None: public_treasury = client.public_treasury.get_coin_id( @@ -31,7 +31,19 @@ def test_method_get_coin_id(self, client: Coingecko) -> None: ) assert_matches_type(PublicTreasuryGetCoinIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_get_coin_id_with_all_params(self, client: Coingecko) -> None: + public_treasury = client.public_treasury.get_coin_id( + coin_id="bitcoin", + entity="companies", + order="total_holdings_usd_desc", + page=1, + per_page=250, + ) + assert_matches_type(PublicTreasuryGetCoinIDResponse, public_treasury, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_coin_id(self, client: Coingecko) -> None: response = client.public_treasury.with_raw_response.get_coin_id( @@ -44,7 +56,7 @@ def test_raw_response_get_coin_id(self, client: Coingecko) -> None: public_treasury = response.parse() assert_matches_type(PublicTreasuryGetCoinIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_coin_id(self, client: Coingecko) -> None: with client.public_treasury.with_streaming_response.get_coin_id( @@ -59,7 +71,7 @@ def test_streaming_response_get_coin_id(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_coin_id(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `coin_id` but received ''"): @@ -68,19 +80,29 @@ def test_path_params_get_coin_id(self, client: Coingecko) -> None: entity="companies", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_entity_id(self, client: Coingecko) -> None: public_treasury = client.public_treasury.get_entity_id( - "strategy", + entity_id="strategy", ) assert_matches_type(PublicTreasuryGetEntityIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_get_entity_id_with_all_params(self, client: Coingecko) -> None: + public_treasury = client.public_treasury.get_entity_id( + entity_id="strategy", + holding_amount_change="holding_amount_change", + holding_change_percentage="holding_change_percentage", + ) + assert_matches_type(PublicTreasuryGetEntityIDResponse, public_treasury, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_entity_id(self, client: Coingecko) -> None: response = client.public_treasury.with_raw_response.get_entity_id( - "strategy", + entity_id="strategy", ) assert response.is_closed is True @@ -88,11 +110,11 @@ def test_raw_response_get_entity_id(self, client: Coingecko) -> None: public_treasury = response.parse() assert_matches_type(PublicTreasuryGetEntityIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_entity_id(self, client: Coingecko) -> None: with client.public_treasury.with_streaming_response.get_entity_id( - "strategy", + entity_id="strategy", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -102,15 +124,15 @@ def test_streaming_response_get_entity_id(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_entity_id(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `entity_id` but received ''"): client.public_treasury.with_raw_response.get_entity_id( - "", + entity_id="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_holding_chart(self, client: Coingecko) -> None: public_treasury = client.public_treasury.get_holding_chart( @@ -120,7 +142,7 @@ def test_method_get_holding_chart(self, client: Coingecko) -> None: ) assert_matches_type(PublicTreasuryGetHoldingChartResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_holding_chart_with_all_params(self, client: Coingecko) -> None: public_treasury = client.public_treasury.get_holding_chart( @@ -131,7 +153,7 @@ def test_method_get_holding_chart_with_all_params(self, client: Coingecko) -> No ) assert_matches_type(PublicTreasuryGetHoldingChartResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_holding_chart(self, client: Coingecko) -> None: response = client.public_treasury.with_raw_response.get_holding_chart( @@ -145,7 +167,7 @@ def test_raw_response_get_holding_chart(self, client: Coingecko) -> None: public_treasury = response.parse() assert_matches_type(PublicTreasuryGetHoldingChartResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_holding_chart(self, client: Coingecko) -> None: with client.public_treasury.with_streaming_response.get_holding_chart( @@ -161,7 +183,7 @@ def test_streaming_response_get_holding_chart(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_holding_chart(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `entity_id` but received ''"): @@ -178,7 +200,7 @@ def test_path_params_get_holding_chart(self, client: Coingecko) -> None: days="days", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_transaction_history(self, client: Coingecko) -> None: public_treasury = client.public_treasury.get_transaction_history( @@ -186,7 +208,7 @@ def test_method_get_transaction_history(self, client: Coingecko) -> None: ) assert_matches_type(PublicTreasuryGetTransactionHistoryResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_transaction_history_with_all_params(self, client: Coingecko) -> None: public_treasury = client.public_treasury.get_transaction_history( @@ -198,7 +220,7 @@ def test_method_get_transaction_history_with_all_params(self, client: Coingecko) ) assert_matches_type(PublicTreasuryGetTransactionHistoryResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_transaction_history(self, client: Coingecko) -> None: response = client.public_treasury.with_raw_response.get_transaction_history( @@ -210,7 +232,7 @@ def test_raw_response_get_transaction_history(self, client: Coingecko) -> None: public_treasury = response.parse() assert_matches_type(PublicTreasuryGetTransactionHistoryResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_transaction_history(self, client: Coingecko) -> None: with client.public_treasury.with_streaming_response.get_transaction_history( @@ -224,7 +246,7 @@ def test_streaming_response_get_transaction_history(self, client: Coingecko) -> assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_transaction_history(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `entity_id` but received ''"): @@ -238,7 +260,7 @@ class TestAsyncPublicTreasury: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_coin_id(self, async_client: AsyncCoingecko) -> None: public_treasury = await async_client.public_treasury.get_coin_id( @@ -247,7 +269,19 @@ async def test_method_get_coin_id(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(PublicTreasuryGetCoinIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_get_coin_id_with_all_params(self, async_client: AsyncCoingecko) -> None: + public_treasury = await async_client.public_treasury.get_coin_id( + coin_id="bitcoin", + entity="companies", + order="total_holdings_usd_desc", + page=1, + per_page=250, + ) + assert_matches_type(PublicTreasuryGetCoinIDResponse, public_treasury, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_coin_id(self, async_client: AsyncCoingecko) -> None: response = await async_client.public_treasury.with_raw_response.get_coin_id( @@ -260,7 +294,7 @@ async def test_raw_response_get_coin_id(self, async_client: AsyncCoingecko) -> N public_treasury = await response.parse() assert_matches_type(PublicTreasuryGetCoinIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_coin_id(self, async_client: AsyncCoingecko) -> None: async with async_client.public_treasury.with_streaming_response.get_coin_id( @@ -275,7 +309,7 @@ async def test_streaming_response_get_coin_id(self, async_client: AsyncCoingecko assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_coin_id(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `coin_id` but received ''"): @@ -284,19 +318,29 @@ async def test_path_params_get_coin_id(self, async_client: AsyncCoingecko) -> No entity="companies", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_entity_id(self, async_client: AsyncCoingecko) -> None: public_treasury = await async_client.public_treasury.get_entity_id( - "strategy", + entity_id="strategy", ) assert_matches_type(PublicTreasuryGetEntityIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_get_entity_id_with_all_params(self, async_client: AsyncCoingecko) -> None: + public_treasury = await async_client.public_treasury.get_entity_id( + entity_id="strategy", + holding_amount_change="holding_amount_change", + holding_change_percentage="holding_change_percentage", + ) + assert_matches_type(PublicTreasuryGetEntityIDResponse, public_treasury, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_entity_id(self, async_client: AsyncCoingecko) -> None: response = await async_client.public_treasury.with_raw_response.get_entity_id( - "strategy", + entity_id="strategy", ) assert response.is_closed is True @@ -304,11 +348,11 @@ async def test_raw_response_get_entity_id(self, async_client: AsyncCoingecko) -> public_treasury = await response.parse() assert_matches_type(PublicTreasuryGetEntityIDResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_entity_id(self, async_client: AsyncCoingecko) -> None: async with async_client.public_treasury.with_streaming_response.get_entity_id( - "strategy", + entity_id="strategy", ) as response: assert not response.is_closed assert response.http_request.headers.get("X-Stainless-Lang") == "python" @@ -318,15 +362,15 @@ async def test_streaming_response_get_entity_id(self, async_client: AsyncCoingec assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_entity_id(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `entity_id` but received ''"): await async_client.public_treasury.with_raw_response.get_entity_id( - "", + entity_id="", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_holding_chart(self, async_client: AsyncCoingecko) -> None: public_treasury = await async_client.public_treasury.get_holding_chart( @@ -336,7 +380,7 @@ async def test_method_get_holding_chart(self, async_client: AsyncCoingecko) -> N ) assert_matches_type(PublicTreasuryGetHoldingChartResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_holding_chart_with_all_params(self, async_client: AsyncCoingecko) -> None: public_treasury = await async_client.public_treasury.get_holding_chart( @@ -347,7 +391,7 @@ async def test_method_get_holding_chart_with_all_params(self, async_client: Asyn ) assert_matches_type(PublicTreasuryGetHoldingChartResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_holding_chart(self, async_client: AsyncCoingecko) -> None: response = await async_client.public_treasury.with_raw_response.get_holding_chart( @@ -361,7 +405,7 @@ async def test_raw_response_get_holding_chart(self, async_client: AsyncCoingecko public_treasury = await response.parse() assert_matches_type(PublicTreasuryGetHoldingChartResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_holding_chart(self, async_client: AsyncCoingecko) -> None: async with async_client.public_treasury.with_streaming_response.get_holding_chart( @@ -377,7 +421,7 @@ async def test_streaming_response_get_holding_chart(self, async_client: AsyncCoi assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_holding_chart(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `entity_id` but received ''"): @@ -394,7 +438,7 @@ async def test_path_params_get_holding_chart(self, async_client: AsyncCoingecko) days="days", ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_transaction_history(self, async_client: AsyncCoingecko) -> None: public_treasury = await async_client.public_treasury.get_transaction_history( @@ -402,7 +446,7 @@ async def test_method_get_transaction_history(self, async_client: AsyncCoingecko ) assert_matches_type(PublicTreasuryGetTransactionHistoryResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_transaction_history_with_all_params(self, async_client: AsyncCoingecko) -> None: public_treasury = await async_client.public_treasury.get_transaction_history( @@ -414,7 +458,7 @@ async def test_method_get_transaction_history_with_all_params(self, async_client ) assert_matches_type(PublicTreasuryGetTransactionHistoryResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_transaction_history(self, async_client: AsyncCoingecko) -> None: response = await async_client.public_treasury.with_raw_response.get_transaction_history( @@ -426,7 +470,7 @@ async def test_raw_response_get_transaction_history(self, async_client: AsyncCoi public_treasury = await response.parse() assert_matches_type(PublicTreasuryGetTransactionHistoryResponse, public_treasury, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_transaction_history(self, async_client: AsyncCoingecko) -> None: async with async_client.public_treasury.with_streaming_response.get_transaction_history( @@ -440,7 +484,7 @@ async def test_streaming_response_get_transaction_history(self, async_client: As assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_transaction_history(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `entity_id` but received ''"): diff --git a/tests/api_resources/test_search.py b/tests/api_resources/test_search.py index 30c6864..486b198 100644 --- a/tests/api_resources/test_search.py +++ b/tests/api_resources/test_search.py @@ -17,7 +17,7 @@ class TestSearch: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get(self, client: Coingecko) -> None: search = client.search.get( @@ -25,7 +25,7 @@ def test_method_get(self, client: Coingecko) -> None: ) assert_matches_type(SearchGetResponse, search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get(self, client: Coingecko) -> None: response = client.search.with_raw_response.get( @@ -37,7 +37,7 @@ def test_raw_response_get(self, client: Coingecko) -> None: search = response.parse() assert_matches_type(SearchGetResponse, search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get(self, client: Coingecko) -> None: with client.search.with_streaming_response.get( @@ -57,7 +57,7 @@ class TestAsyncSearch: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get(self, async_client: AsyncCoingecko) -> None: search = await async_client.search.get( @@ -65,7 +65,7 @@ async def test_method_get(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(SearchGetResponse, search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: response = await async_client.search.with_raw_response.get( @@ -77,7 +77,7 @@ async def test_raw_response_get(self, async_client: AsyncCoingecko) -> None: search = await response.parse() assert_matches_type(SearchGetResponse, search, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get(self, async_client: AsyncCoingecko) -> None: async with async_client.search.with_streaming_response.get( diff --git a/tests/api_resources/test_token_lists.py b/tests/api_resources/test_token_lists.py index d7dd187..f4432a9 100644 --- a/tests/api_resources/test_token_lists.py +++ b/tests/api_resources/test_token_lists.py @@ -17,7 +17,7 @@ class TestTokenLists: parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_all_json(self, client: Coingecko) -> None: token_list = client.token_lists.get_all_json( @@ -25,7 +25,7 @@ def test_method_get_all_json(self, client: Coingecko) -> None: ) assert_matches_type(TokenListGetAllJsonResponse, token_list, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_get_all_json(self, client: Coingecko) -> None: response = client.token_lists.with_raw_response.get_all_json( @@ -37,7 +37,7 @@ def test_raw_response_get_all_json(self, client: Coingecko) -> None: token_list = response.parse() assert_matches_type(TokenListGetAllJsonResponse, token_list, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_get_all_json(self, client: Coingecko) -> None: with client.token_lists.with_streaming_response.get_all_json( @@ -51,7 +51,7 @@ def test_streaming_response_get_all_json(self, client: Coingecko) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_path_params_get_all_json(self, client: Coingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `asset_platform_id` but received ''"): @@ -65,7 +65,7 @@ class TestAsyncTokenLists: "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_get_all_json(self, async_client: AsyncCoingecko) -> None: token_list = await async_client.token_lists.get_all_json( @@ -73,7 +73,7 @@ async def test_method_get_all_json(self, async_client: AsyncCoingecko) -> None: ) assert_matches_type(TokenListGetAllJsonResponse, token_list, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_get_all_json(self, async_client: AsyncCoingecko) -> None: response = await async_client.token_lists.with_raw_response.get_all_json( @@ -85,7 +85,7 @@ async def test_raw_response_get_all_json(self, async_client: AsyncCoingecko) -> token_list = await response.parse() assert_matches_type(TokenListGetAllJsonResponse, token_list, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_get_all_json(self, async_client: AsyncCoingecko) -> None: async with async_client.token_lists.with_streaming_response.get_all_json( @@ -99,7 +99,7 @@ async def test_streaming_response_get_all_json(self, async_client: AsyncCoingeck assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_path_params_get_all_json(self, async_client: AsyncCoingecko) -> None: with pytest.raises(ValueError, match=r"Expected a non-empty value for `asset_platform_id` but received ''"): diff --git a/tests/test_client.py b/tests/test_client.py index d99422b..2a5c5cc 100644 --- a/tests/test_client.py +++ b/tests/test_client.py @@ -8,10 +8,11 @@ import json import asyncio import inspect +import dataclasses import tracemalloc -from typing import Any, Union, cast +from typing import Any, Union, TypeVar, Callable, Iterable, Iterator, Optional, Coroutine, cast from unittest import mock -from typing_extensions import Literal +from typing_extensions import Literal, AsyncIterator, override import httpx import pytest @@ -36,6 +37,7 @@ from .utils import update_env +T = TypeVar("T") base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010") pro_api_key = "My Pro API Key" @@ -50,6 +52,57 @@ def _low_retry_timeout(*_args: Any, **_kwargs: Any) -> float: return 0.1 +def mirror_request_content(request: httpx.Request) -> httpx.Response: + return httpx.Response(200, content=request.content) + + +# note: we can't use the httpx.MockTransport class as it consumes the request +# body itself, which means we can't test that the body is read lazily +class MockTransport(httpx.BaseTransport, httpx.AsyncBaseTransport): + def __init__( + self, + handler: Callable[[httpx.Request], httpx.Response] + | Callable[[httpx.Request], Coroutine[Any, Any, httpx.Response]], + ) -> None: + self.handler = handler + + @override + def handle_request( + self, + request: httpx.Request, + ) -> httpx.Response: + assert not inspect.iscoroutinefunction(self.handler), "handler must not be a coroutine function" + assert inspect.isfunction(self.handler), "handler must be a function" + return self.handler(request) + + @override + async def handle_async_request( + self, + request: httpx.Request, + ) -> httpx.Response: + assert inspect.iscoroutinefunction(self.handler), "handler must be a coroutine function" + return await self.handler(request) + + +@dataclasses.dataclass +class Counter: + value: int = 0 + + +def _make_sync_iterator(iterable: Iterable[T], counter: Optional[Counter] = None) -> Iterator[T]: + for item in iterable: + if counter: + counter.value += 1 + yield item + + +async def _make_async_iterator(iterable: Iterable[T], counter: Optional[Counter] = None) -> AsyncIterator[T]: + for item in iterable: + if counter: + counter.value += 1 + yield item + + def _get_open_connections(client: Coingecko | AsyncCoingecko) -> int: transport = client._client._transport assert isinstance(transport, httpx.HTTPTransport) or isinstance(transport, httpx.AsyncHTTPTransport) @@ -520,6 +573,70 @@ def test_multipart_repeating_array(self, client: Coingecko) -> None: b"", ] + @pytest.mark.respx(base_url=base_url) + def test_binary_content_upload(self, respx_mock: MockRouter, client: Coingecko) -> None: + respx_mock.post("/upload").mock(side_effect=mirror_request_content) + + file_content = b"Hello, this is a test file." + + response = client.post( + "/upload", + content=file_content, + cast_to=httpx.Response, + options={"headers": {"Content-Type": "application/octet-stream"}}, + ) + + assert response.status_code == 200 + assert response.request.headers["Content-Type"] == "application/octet-stream" + assert response.content == file_content + + def test_binary_content_upload_with_iterator(self) -> None: + file_content = b"Hello, this is a test file." + counter = Counter() + iterator = _make_sync_iterator([file_content], counter=counter) + + def mock_handler(request: httpx.Request) -> httpx.Response: + assert counter.value == 0, "the request body should not have been read" + return httpx.Response(200, content=request.read()) + + with Coingecko( + base_url=base_url, + pro_api_key=pro_api_key, + _strict_response_validation=True, + http_client=httpx.Client(transport=MockTransport(handler=mock_handler)), + ) as client: + response = client.post( + "/upload", + content=iterator, + cast_to=httpx.Response, + options={"headers": {"Content-Type": "application/octet-stream"}}, + ) + + assert response.status_code == 200 + assert response.request.headers["Content-Type"] == "application/octet-stream" + assert response.content == file_content + assert counter.value == 1 + + @pytest.mark.respx(base_url=base_url) + def test_binary_content_upload_with_body_is_deprecated(self, respx_mock: MockRouter, client: Coingecko) -> None: + respx_mock.post("/upload").mock(side_effect=mirror_request_content) + + file_content = b"Hello, this is a test file." + + with pytest.deprecated_call( + match="Passing raw bytes as `body` is deprecated and will be removed in a future version. Please pass raw bytes via the `content` parameter instead." + ): + response = client.post( + "/upload", + body=file_content, + cast_to=httpx.Response, + options={"headers": {"Content-Type": "application/octet-stream"}}, + ) + + assert response.status_code == 200 + assert response.request.headers["Content-Type"] == "application/octet-stream" + assert response.content == file_content + @pytest.mark.respx(base_url=base_url) def test_basic_union_response(self, respx_mock: MockRouter, client: Coingecko) -> None: class Model1(BaseModel): @@ -877,6 +994,14 @@ def retry_handler(_request: httpx.Request) -> httpx.Response: def test_proxy_environment_variables(self, monkeypatch: pytest.MonkeyPatch) -> None: # Test that the proxy environment variables are set correctly monkeypatch.setenv("HTTPS_PROXY", "https://example.org") + # Delete in case our environment has any proxy env vars set + monkeypatch.delenv("HTTP_PROXY", raising=False) + monkeypatch.delenv("ALL_PROXY", raising=False) + monkeypatch.delenv("NO_PROXY", raising=False) + monkeypatch.delenv("http_proxy", raising=False) + monkeypatch.delenv("https_proxy", raising=False) + monkeypatch.delenv("all_proxy", raising=False) + monkeypatch.delenv("no_proxy", raising=False) client = DefaultHttpxClient() @@ -1386,6 +1511,72 @@ def test_multipart_repeating_array(self, async_client: AsyncCoingecko) -> None: b"", ] + @pytest.mark.respx(base_url=base_url) + async def test_binary_content_upload(self, respx_mock: MockRouter, async_client: AsyncCoingecko) -> None: + respx_mock.post("/upload").mock(side_effect=mirror_request_content) + + file_content = b"Hello, this is a test file." + + response = await async_client.post( + "/upload", + content=file_content, + cast_to=httpx.Response, + options={"headers": {"Content-Type": "application/octet-stream"}}, + ) + + assert response.status_code == 200 + assert response.request.headers["Content-Type"] == "application/octet-stream" + assert response.content == file_content + + async def test_binary_content_upload_with_asynciterator(self) -> None: + file_content = b"Hello, this is a test file." + counter = Counter() + iterator = _make_async_iterator([file_content], counter=counter) + + async def mock_handler(request: httpx.Request) -> httpx.Response: + assert counter.value == 0, "the request body should not have been read" + return httpx.Response(200, content=await request.aread()) + + async with AsyncCoingecko( + base_url=base_url, + pro_api_key=pro_api_key, + _strict_response_validation=True, + http_client=httpx.AsyncClient(transport=MockTransport(handler=mock_handler)), + ) as client: + response = await client.post( + "/upload", + content=iterator, + cast_to=httpx.Response, + options={"headers": {"Content-Type": "application/octet-stream"}}, + ) + + assert response.status_code == 200 + assert response.request.headers["Content-Type"] == "application/octet-stream" + assert response.content == file_content + assert counter.value == 1 + + @pytest.mark.respx(base_url=base_url) + async def test_binary_content_upload_with_body_is_deprecated( + self, respx_mock: MockRouter, async_client: AsyncCoingecko + ) -> None: + respx_mock.post("/upload").mock(side_effect=mirror_request_content) + + file_content = b"Hello, this is a test file." + + with pytest.deprecated_call( + match="Passing raw bytes as `body` is deprecated and will be removed in a future version. Please pass raw bytes via the `content` parameter instead." + ): + response = await async_client.post( + "/upload", + body=file_content, + cast_to=httpx.Response, + options={"headers": {"Content-Type": "application/octet-stream"}}, + ) + + assert response.status_code == 200 + assert response.request.headers["Content-Type"] == "application/octet-stream" + assert response.content == file_content + @pytest.mark.respx(base_url=base_url) async def test_basic_union_response(self, respx_mock: MockRouter, async_client: AsyncCoingecko) -> None: class Model1(BaseModel): @@ -1756,6 +1947,14 @@ async def test_get_platform(self) -> None: async def test_proxy_environment_variables(self, monkeypatch: pytest.MonkeyPatch) -> None: # Test that the proxy environment variables are set correctly monkeypatch.setenv("HTTPS_PROXY", "https://example.org") + # Delete in case our environment has any proxy env vars set + monkeypatch.delenv("HTTP_PROXY", raising=False) + monkeypatch.delenv("ALL_PROXY", raising=False) + monkeypatch.delenv("NO_PROXY", raising=False) + monkeypatch.delenv("http_proxy", raising=False) + monkeypatch.delenv("https_proxy", raising=False) + monkeypatch.delenv("all_proxy", raising=False) + monkeypatch.delenv("no_proxy", raising=False) client = DefaultAsyncHttpxClient() diff --git a/tests/test_utils/test_json.py b/tests/test_utils/test_json.py new file mode 100644 index 0000000..5f24def --- /dev/null +++ b/tests/test_utils/test_json.py @@ -0,0 +1,126 @@ +from __future__ import annotations + +import datetime +from typing import Union + +import pydantic + +from coingecko_sdk import _compat +from coingecko_sdk._utils._json import openapi_dumps + + +class TestOpenapiDumps: + def test_basic(self) -> None: + data = {"key": "value", "number": 42} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"key":"value","number":42}' + + def test_datetime_serialization(self) -> None: + dt = datetime.datetime(2023, 1, 1, 12, 0, 0) + data = {"datetime": dt} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"datetime":"2023-01-01T12:00:00"}' + + def test_pydantic_model_serialization(self) -> None: + class User(pydantic.BaseModel): + first_name: str + last_name: str + age: int + + model_instance = User(first_name="John", last_name="Kramer", age=83) + data = {"model": model_instance} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"first_name":"John","last_name":"Kramer","age":83}}' + + def test_pydantic_model_with_default_values(self) -> None: + class User(pydantic.BaseModel): + name: str + role: str = "user" + active: bool = True + score: int = 0 + + model_instance = User(name="Alice") + data = {"model": model_instance} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"name":"Alice"}}' + + def test_pydantic_model_with_default_values_overridden(self) -> None: + class User(pydantic.BaseModel): + name: str + role: str = "user" + active: bool = True + + model_instance = User(name="Bob", role="admin", active=False) + data = {"model": model_instance} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"name":"Bob","role":"admin","active":false}}' + + def test_pydantic_model_with_alias(self) -> None: + class User(pydantic.BaseModel): + first_name: str = pydantic.Field(alias="firstName") + last_name: str = pydantic.Field(alias="lastName") + + model_instance = User(firstName="John", lastName="Doe") + data = {"model": model_instance} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"firstName":"John","lastName":"Doe"}}' + + def test_pydantic_model_with_alias_and_default(self) -> None: + class User(pydantic.BaseModel): + user_name: str = pydantic.Field(alias="userName") + user_role: str = pydantic.Field(default="member", alias="userRole") + is_active: bool = pydantic.Field(default=True, alias="isActive") + + model_instance = User(userName="charlie") + data = {"model": model_instance} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"userName":"charlie"}}' + + model_with_overrides = User(userName="diana", userRole="admin", isActive=False) + data = {"model": model_with_overrides} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"userName":"diana","userRole":"admin","isActive":false}}' + + def test_pydantic_model_with_nested_models_and_defaults(self) -> None: + class Address(pydantic.BaseModel): + street: str + city: str = "Unknown" + + class User(pydantic.BaseModel): + name: str + address: Address + verified: bool = False + + if _compat.PYDANTIC_V1: + # to handle forward references in Pydantic v1 + User.update_forward_refs(**locals()) # type: ignore[reportDeprecated] + + address = Address(street="123 Main St") + user = User(name="Diana", address=address) + data = {"user": user} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"user":{"name":"Diana","address":{"street":"123 Main St"}}}' + + address_with_city = Address(street="456 Oak Ave", city="Boston") + user_verified = User(name="Eve", address=address_with_city, verified=True) + data = {"user": user_verified} + json_bytes = openapi_dumps(data) + assert ( + json_bytes == b'{"user":{"name":"Eve","address":{"street":"456 Oak Ave","city":"Boston"},"verified":true}}' + ) + + def test_pydantic_model_with_optional_fields(self) -> None: + class User(pydantic.BaseModel): + name: str + email: Union[str, None] + phone: Union[str, None] + + model_with_none = User(name="Eve", email=None, phone=None) + data = {"model": model_with_none} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"name":"Eve","email":null,"phone":null}}' + + model_with_values = User(name="Frank", email="frank@example.com", phone=None) + data = {"model": model_with_values} + json_bytes = openapi_dumps(data) + assert json_bytes == b'{"model":{"name":"Frank","email":"frank@example.com","phone":null}}'