diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml index 9e99d03c..5468db5d 100644 --- a/.github/workflows/ci.yml +++ b/.github/workflows/ci.yml @@ -61,14 +61,18 @@ jobs: run: rye build - name: Get GitHub OIDC Token - if: github.repository == 'stainless-sdks/gitpod-python' + if: |- + github.repository == 'stainless-sdks/gitpod-python' && + !startsWith(github.ref, 'refs/heads/stl/') id: github-oidc uses: actions/github-script@v8 with: script: core.setOutput('github_token', await core.getIDToken()); - name: Upload tarball - if: github.repository == 'stainless-sdks/gitpod-python' + if: |- + github.repository == 'stainless-sdks/gitpod-python' && + !startsWith(github.ref, 'refs/heads/stl/') env: URL: https://pkg.stainless.com/s AUTH: ${{ steps.github-oidc.outputs.github_token }} diff --git a/.release-please-manifest.json b/.release-please-manifest.json index 091cfb12..f7014c35 100644 --- a/.release-please-manifest.json +++ b/.release-please-manifest.json @@ -1,3 +1,3 @@ { - ".": "0.10.0" + ".": "0.11.0" } \ No newline at end of file diff --git a/.stats.yml b/.stats.yml index 9d8e308c..137fe16c 100644 --- a/.stats.yml +++ b/.stats.yml @@ -1,4 +1,4 @@ -configured_endpoints: 175 -openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/gitpod%2Fgitpod-04247bf988645580ef6550363a7279d67d7c844e4310b526b6868be92541199f.yml -openapi_spec_hash: b0f61f1a55a55a187447ff684bf51d3d -config_hash: 469d30a2d44895c8c53a5aac370a56f1 +configured_endpoints: 193 +openapi_spec_url: https://storage.googleapis.com/stainless-sdk-openapi-specs/gitpod%2Fgitpod-81e6dd362ed000dd15cc51a77545a0772d791241380906229b5ba6f2ba265bcb.yml +openapi_spec_hash: 9adc025d621dcefde671682cdd711ec0 +config_hash: 1e3edbeecb529f712bfaac1b561d91d5 diff --git a/CHANGELOG.md b/CHANGELOG.md index 1ffcfe36..0f07da8e 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,5 +1,64 @@ # Changelog +## 0.11.0 (2026-03-14) + +Full Changelog: [v0.10.0...v0.11.0](https://github.com/gitpod-io/gitpod-sdk-python/compare/v0.10.0...v0.11.0) + +### Features + +* [backend/api] add backend search for group members ([0eb24b8](https://github.com/gitpod-io/gitpod-sdk-python/commit/0eb24b80e8a7b32ad08fbdd6e40fc3862b6545dc)) +* **api:** add acknowledge_token param to environments.start method ([19ce45f](https://github.com/gitpod-io/gitpod-sdk-python/commit/19ce45ff07385a58858da61619c35291b4bd93aa)) +* **api:** add agent_message parameter to agents.send_to_execution ([f7b21f6](https://github.com/gitpod-io/gitpod-sdk-python/commit/f7b21f6d4b9c54a12e4820b4a8226b751af0e7da)) +* **api:** add automations resource with workflows/executions/actions ([7cdce62](https://github.com/gitpod-io/gitpod-sdk-python/commit/7cdce62ead18e8383b8e6119e08361a62d9b653e)) +* **api:** add bpf_debug_level field to KernelControlsConfig ([d0cf7a4](https://github.com/gitpod-io/gitpod-sdk-python/commit/d0cf7a47fc5e68b96a40152ba8f26476da9ded02)) +* **api:** add exclude_prompt_content parameter to agents list_prompts method ([1b78cec](https://github.com/gitpod-io/gitpod-sdk-python/commit/1b78cecf7a623ad29c4d5cdfc8fe3a04a8d024c7)) +* **api:** add filter parameter to groups list method ([c21fcff](https://github.com/gitpod-io/gitpod-sdk-python/commit/c21fcff4e84363a6c73d54516afea8ab40c8f218)) +* **api:** add lockdown_at field to environment status ([6317ac9](https://github.com/gitpod-io/gitpod-sdk-python/commit/6317ac97e4de079d158a0839eea63b8b4f11825f)) +* **api:** add organization_tier field to identity get_authenticated_identity response ([fb627da](https://github.com/gitpod-io/gitpod-sdk-python/commit/fb627dad41802c02ae02ba1621968be8423dd726)) +* **api:** add resource_ids to role assignments, restructure executable deny list in policies ([b30fc23](https://github.com/gitpod-io/gitpod-sdk-python/commit/b30fc2332c0d2f4c8267c00d15a2e0a3f43446ec)) +* **api:** add resource_type_filters parameter to events watch method ([141bcd4](https://github.com/gitpod-io/gitpod-sdk-python/commit/141bcd4c6c1255dbb2ea37838ea87239efa62c81)) +* **api:** add role and sender_execution_id fields to agent messages ([8cbc1ca](https://github.com/gitpod-io/gitpod-sdk-python/commit/8cbc1ca652eb9e2806555ca965d056f63c36dbd8)) +* **api:** add RUNNER_CAPABILITY_WARM_POOL to runner_capability ([b058adf](https://github.com/gitpod-io/gitpod-sdk-python/commit/b058adf259789bb14f556f2c67b6f002fb654046)) +* **api:** add SESSION_ADMIN and SESSION_USER roles to ResourceRole ([1fa7909](https://github.com/gitpod-io/gitpod-sdk-python/commit/1fa7909bd79fbd5f0d89724dd1ae14ac4ca79250)) +* **api:** add session_id parameter to agents start_execution, environments create ([50cf2eb](https://github.com/gitpod-io/gitpod-sdk-python/commit/50cf2eb8b5a932328c7ded80332171ed28ca4e43)) +* **api:** add snapshot_size_bytes field to PrebuildStatus ([c0764ca](https://github.com/gitpod-io/gitpod-sdk-python/commit/c0764ca0574ab440cad5fb732ca8076d11346e5e)) +* **api:** add SONNET_4_6 model variants to agent_execution Status ([e87f54b](https://github.com/gitpod-io/gitpod-sdk-python/commit/e87f54b36e2913913125398b6e36223c795b9562)) +* **api:** add sort option to ListAuditLogs ([19af3c6](https://github.com/gitpod-io/gitpod-sdk-python/commit/19af3c6ad9ba8ae3ca8605b26195fc27f8810d5f)) +* **api:** add sort parameter to projects list, SortOrder/SortParam types ([fada768](https://github.com/gitpod-io/gitpod-sdk-python/commit/fada768b6dbe0721d4e6d93dca8ff2d6dc44f648)) +* **api:** add SUPPORTED_MODEL_HAIKU_4_5 to agent_execution Status enum ([85c063b](https://github.com/gitpod-io/gitpod-sdk-python/commit/85c063b47e0cc8875f1b3c2a2d17c386fea76df4)) +* **api:** add team admin and viewer roles to ResourceRole ([85b0437](https://github.com/gitpod-io/gitpod-sdk-python/commit/85b043796677897ef9ea8f5d92c129b515107890)) +* **api:** add time range filters to event list method ([c89b37e](https://github.com/gitpod-io/gitpod-sdk-python/commit/c89b37ec3240396215fba5b77b19c29ae598da2e)) +* **api:** add wake_event parameter to agents send_to_execution method ([893e4b3](https://github.com/gitpod-io/gitpod-sdk-python/commit/893e4b37b75000dee0b99a0e82fe5c62a2732dd5)) +* **api:** add warm pool methods to prebuilds ([68b693f](https://github.com/gitpod-io/gitpod-sdk-python/commit/68b693fe0134ac6df5aa06f7cc9409c15c9308a5)) +* **api:** remove acknowledge_token parameter from environments.start ([340b6f2](https://github.com/gitpod-io/gitpod-sdk-python/commit/340b6f28ae6fa15ea3955d10720dcd44a6e85651)) +* **types:** add CountResponseRelation enum type ([c5c6a3a](https://github.com/gitpod-io/gitpod-sdk-python/commit/c5c6a3a85b17dafe0bb879d42eb671f4601718b7)) + + +### Bug Fixes + +* **api:** rename executable_deny_list to veto_exec_policy in policies update ([8e6e434](https://github.com/gitpod-io/gitpod-sdk-python/commit/8e6e434949910725dcf3e0919e57f2f748acff15)) +* **types:** remove AGENT_EXECUTION values from Principal and ResourceRole enums ([36adf59](https://github.com/gitpod-io/gitpod-sdk-python/commit/36adf596f84d9ea0063185d7ade2ff5b4c723fb6)) + + +### Chores + +* **ci:** skip uploading artifacts on stainless-internal branches ([6955303](https://github.com/gitpod-io/gitpod-sdk-python/commit/69553031de097820152f561c7e300eceb8756df1)) +* **docs:** add missing descriptions ([c10fa2e](https://github.com/gitpod-io/gitpod-sdk-python/commit/c10fa2e60f87bc25f37efa9923ebaac979abe6dd)) +* **internal:** add request options to SSE classes ([17c6632](https://github.com/gitpod-io/gitpod-sdk-python/commit/17c6632b21cdf3fb082f74a6a3823cb210aa1757)) +* **internal:** make `test_proxy_environment_variables` more resilient ([b5ee95d](https://github.com/gitpod-io/gitpod-sdk-python/commit/b5ee95d7dcc5a9da2ed73af7a7f896dd56c5b4a4)) +* **internal:** make `test_proxy_environment_variables` more resilient to env ([2520d14](https://github.com/gitpod-io/gitpod-sdk-python/commit/2520d14755b2be28dbb6b4335438482aca97a794)) +* **internal:** move CountResponseRelation type to shared module ([641a91c](https://github.com/gitpod-io/gitpod-sdk-python/commit/641a91ccea854113f3d9ccea80ba22c2f82cad76)) +* **internal:** remove mock server code ([3c5deb3](https://github.com/gitpod-io/gitpod-sdk-python/commit/3c5deb354f3c5059bac0bb2b50c288a7b40e2b7f)) +* **internal:** update jsonl tests ([6d2b499](https://github.com/gitpod-io/gitpod-sdk-python/commit/6d2b4990c73692b942ae02d99577c119bd6a8b18)) +* **test:** update skip reason message ([49175f9](https://github.com/gitpod-io/gitpod-sdk-python/commit/49175f922aa977681c528dc55920562433fcaaee)) +* update mock server docs ([cef4896](https://github.com/gitpod-io/gitpod-sdk-python/commit/cef48965ac676afcc1adde238fc0a59c85ed0dac)) + + +### Documentation + +* **api:** add validation examples to timeout fields in policies/environments ([8ae9d6c](https://github.com/gitpod-io/gitpod-sdk-python/commit/8ae9d6cc242c17a4e608c289c34bfe0a1814ffb2)) +* **api:** update filter descriptions in groups role_assignment_list_params ([daf1ad5](https://github.com/gitpod-io/gitpod-sdk-python/commit/daf1ad5c2b42f7851566d8c32f5dda6f9313dd53)) + ## 0.10.0 (2026-02-18) Full Changelog: [v0.9.0...v0.10.0](https://github.com/gitpod-io/gitpod-sdk-python/compare/v0.9.0...v0.10.0) diff --git a/CONTRIBUTING.md b/CONTRIBUTING.md index 8e1d17a7..1637a470 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/api.md b/api.md index 819e682c..8c8075ae 100644 --- a/api.md +++ b/api.md @@ -3,6 +3,7 @@ ```python from gitpod.types import ( AutomationTrigger, + CountResponseRelation, EnvironmentClass, EnvironmentVariableItem, EnvironmentVariableSource, @@ -17,6 +18,8 @@ from gitpod.types import ( ResourceType, RunsOn, SecretRef, + Sort, + SortOrder, State, Subject, Task, @@ -64,11 +67,15 @@ Types: from gitpod.types import ( AgentCodeContext, AgentExecution, + AgentMessage, AgentMode, Prompt, PromptMetadata, PromptSpec, + Role, + Type, UserInputBlock, + WakeEvent, AgentCreateExecutionConversationTokenResponse, AgentCreatePromptResponse, AgentRetrieveExecutionResponse, @@ -93,6 +100,45 @@ Methods: - client.agents.stop_execution(\*\*params) -> object - client.agents.update_prompt(\*\*params) -> AgentUpdatePromptResponse +# Automations + +Types: + +```python +from gitpod.types import ( + Workflow, + WorkflowAction, + WorkflowExecution, + WorkflowExecutionAction, + WorkflowStep, + WorkflowTrigger, + WorkflowTriggerContext, + AutomationCreateResponse, + AutomationRetrieveResponse, + AutomationUpdateResponse, + AutomationListExecutionOutputsResponse, + AutomationRetrieveExecutionResponse, + AutomationRetrieveExecutionActionResponse, + AutomationStartExecutionResponse, +) +``` + +Methods: + +- client.automations.create(\*\*params) -> AutomationCreateResponse +- client.automations.retrieve(\*\*params) -> AutomationRetrieveResponse +- client.automations.update(\*\*params) -> AutomationUpdateResponse +- client.automations.list(\*\*params) -> SyncWorkflowsPage[Workflow] +- client.automations.delete(\*\*params) -> object +- client.automations.cancel_execution(\*\*params) -> object +- client.automations.cancel_execution_action(\*\*params) -> object +- client.automations.list_execution_actions(\*\*params) -> SyncWorkflowExecutionActionsPage[WorkflowExecutionAction] +- client.automations.list_execution_outputs(\*\*params) -> SyncOutputsPage[AutomationListExecutionOutputsResponse] +- client.automations.list_executions(\*\*params) -> SyncWorkflowExecutionsPage[WorkflowExecution] +- client.automations.retrieve_execution(\*\*params) -> AutomationRetrieveExecutionResponse +- client.automations.retrieve_execution_action(\*\*params) -> AutomationRetrieveExecutionActionResponse +- client.automations.start_execution(\*\*params) -> AutomationStartExecutionResponse + # Editors Types: @@ -114,6 +160,7 @@ Types: ```python from gitpod.types import ( AdmissionLevel, + BpfDebugLevel, Environment, EnvironmentActivitySignal, EnvironmentMetadata, @@ -525,10 +572,18 @@ from gitpod.types import ( PrebuildSpec, PrebuildStatus, PrebuildTrigger, + WarmPool, + WarmPoolMetadata, + WarmPoolPhase, + WarmPoolSpec, + WarmPoolStatus, PrebuildCreateResponse, PrebuildRetrieveResponse, PrebuildCancelResponse, PrebuildCreateLogsTokenResponse, + PrebuildCreateWarmPoolResponse, + PrebuildRetrieveWarmPoolResponse, + PrebuildUpdateWarmPoolResponse, ) ``` @@ -540,6 +595,11 @@ Methods: - client.prebuilds.delete(\*\*params) -> object - client.prebuilds.cancel(\*\*params) -> PrebuildCancelResponse - client.prebuilds.create_logs_token(\*\*params) -> PrebuildCreateLogsTokenResponse +- client.prebuilds.create_warm_pool(\*\*params) -> PrebuildCreateWarmPoolResponse +- client.prebuilds.delete_warm_pool(\*\*params) -> object +- client.prebuilds.list_warm_pools(\*\*params) -> SyncWarmPoolsPage[WarmPool] +- client.prebuilds.retrieve_warm_pool(\*\*params) -> PrebuildRetrieveWarmPoolResponse +- client.prebuilds.update_warm_pool(\*\*params) -> PrebuildUpdateWarmPoolResponse # Projects diff --git a/pyproject.toml b/pyproject.toml index 9e844446..2e27c800 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -1,6 +1,6 @@ [project] name = "gitpod-sdk" -version = "0.10.0" +version = "0.11.0" description = "The official Python library for the gitpod API" dynamic = ["readme"] license = "Apache-2.0" diff --git a/scripts/mock b/scripts/mock deleted file mode 100755 index 0b28f6ea..00000000 --- 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 dbeda2d2..39729d09 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/gitpod/_client.py b/src/gitpod/_client.py index e1319a29..dddc11d8 100644 --- a/src/gitpod/_client.py +++ b/src/gitpod/_client.py @@ -46,6 +46,7 @@ identity, projects, prebuilds, + automations, environments, organizations, ) @@ -59,6 +60,7 @@ from .resources.gateways import GatewaysResource, AsyncGatewaysResource from .resources.identity import IdentityResource, AsyncIdentityResource from .resources.prebuilds import PrebuildsResource, AsyncPrebuildsResource + from .resources.automations import AutomationsResource, AsyncAutomationsResource from .resources.users.users import UsersResource, AsyncUsersResource from .resources.groups.groups import GroupsResource, AsyncGroupsResource from .resources.runners.runners import RunnersResource, AsyncRunnersResource @@ -136,6 +138,12 @@ def agents(self) -> AgentsResource: return AgentsResource(self) + @cached_property + def automations(self) -> AutomationsResource: + from .resources.automations import AutomationsResource + + return AutomationsResource(self) + @cached_property def editors(self) -> EditorsResource: from .resources.editors import EditorsResource @@ -150,6 +158,10 @@ def environments(self) -> EnvironmentsResource: @cached_property def errors(self) -> ErrorsResource: + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ from .resources.errors import ErrorsResource return ErrorsResource(self) @@ -186,6 +198,10 @@ def organizations(self) -> OrganizationsResource: @cached_property def prebuilds(self) -> PrebuildsResource: + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ from .resources.prebuilds import PrebuildsResource return PrebuildsResource(self) @@ -210,6 +226,9 @@ def secrets(self) -> SecretsResource: @cached_property def usage(self) -> UsageResource: + """ + UsageService provides usage information about environments, users, and projects. + """ from .resources.usage import UsageResource return UsageResource(self) @@ -400,6 +419,12 @@ def agents(self) -> AsyncAgentsResource: return AsyncAgentsResource(self) + @cached_property + def automations(self) -> AsyncAutomationsResource: + from .resources.automations import AsyncAutomationsResource + + return AsyncAutomationsResource(self) + @cached_property def editors(self) -> AsyncEditorsResource: from .resources.editors import AsyncEditorsResource @@ -414,6 +439,10 @@ def environments(self) -> AsyncEnvironmentsResource: @cached_property def errors(self) -> AsyncErrorsResource: + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ from .resources.errors import AsyncErrorsResource return AsyncErrorsResource(self) @@ -450,6 +479,10 @@ def organizations(self) -> AsyncOrganizationsResource: @cached_property def prebuilds(self) -> AsyncPrebuildsResource: + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ from .resources.prebuilds import AsyncPrebuildsResource return AsyncPrebuildsResource(self) @@ -474,6 +507,9 @@ def secrets(self) -> AsyncSecretsResource: @cached_property def usage(self) -> AsyncUsageResource: + """ + UsageService provides usage information about environments, users, and projects. + """ from .resources.usage import AsyncUsageResource return AsyncUsageResource(self) @@ -615,6 +651,12 @@ def agents(self) -> agents.AgentsResourceWithRawResponse: return AgentsResourceWithRawResponse(self._client.agents) + @cached_property + def automations(self) -> automations.AutomationsResourceWithRawResponse: + from .resources.automations import AutomationsResourceWithRawResponse + + return AutomationsResourceWithRawResponse(self._client.automations) + @cached_property def editors(self) -> editors.EditorsResourceWithRawResponse: from .resources.editors import EditorsResourceWithRawResponse @@ -629,6 +671,10 @@ def environments(self) -> environments.EnvironmentsResourceWithRawResponse: @cached_property def errors(self) -> errors.ErrorsResourceWithRawResponse: + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ from .resources.errors import ErrorsResourceWithRawResponse return ErrorsResourceWithRawResponse(self._client.errors) @@ -665,6 +711,10 @@ def organizations(self) -> organizations.OrganizationsResourceWithRawResponse: @cached_property def prebuilds(self) -> prebuilds.PrebuildsResourceWithRawResponse: + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ from .resources.prebuilds import PrebuildsResourceWithRawResponse return PrebuildsResourceWithRawResponse(self._client.prebuilds) @@ -689,6 +739,9 @@ def secrets(self) -> secrets.SecretsResourceWithRawResponse: @cached_property def usage(self) -> usage.UsageResourceWithRawResponse: + """ + UsageService provides usage information about environments, users, and projects. + """ from .resources.usage import UsageResourceWithRawResponse return UsageResourceWithRawResponse(self._client.usage) @@ -718,6 +771,12 @@ def agents(self) -> agents.AsyncAgentsResourceWithRawResponse: return AsyncAgentsResourceWithRawResponse(self._client.agents) + @cached_property + def automations(self) -> automations.AsyncAutomationsResourceWithRawResponse: + from .resources.automations import AsyncAutomationsResourceWithRawResponse + + return AsyncAutomationsResourceWithRawResponse(self._client.automations) + @cached_property def editors(self) -> editors.AsyncEditorsResourceWithRawResponse: from .resources.editors import AsyncEditorsResourceWithRawResponse @@ -732,6 +791,10 @@ def environments(self) -> environments.AsyncEnvironmentsResourceWithRawResponse: @cached_property def errors(self) -> errors.AsyncErrorsResourceWithRawResponse: + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ from .resources.errors import AsyncErrorsResourceWithRawResponse return AsyncErrorsResourceWithRawResponse(self._client.errors) @@ -768,6 +831,10 @@ def organizations(self) -> organizations.AsyncOrganizationsResourceWithRawRespon @cached_property def prebuilds(self) -> prebuilds.AsyncPrebuildsResourceWithRawResponse: + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ from .resources.prebuilds import AsyncPrebuildsResourceWithRawResponse return AsyncPrebuildsResourceWithRawResponse(self._client.prebuilds) @@ -792,6 +859,9 @@ def secrets(self) -> secrets.AsyncSecretsResourceWithRawResponse: @cached_property def usage(self) -> usage.AsyncUsageResourceWithRawResponse: + """ + UsageService provides usage information about environments, users, and projects. + """ from .resources.usage import AsyncUsageResourceWithRawResponse return AsyncUsageResourceWithRawResponse(self._client.usage) @@ -821,6 +891,12 @@ def agents(self) -> agents.AgentsResourceWithStreamingResponse: return AgentsResourceWithStreamingResponse(self._client.agents) + @cached_property + def automations(self) -> automations.AutomationsResourceWithStreamingResponse: + from .resources.automations import AutomationsResourceWithStreamingResponse + + return AutomationsResourceWithStreamingResponse(self._client.automations) + @cached_property def editors(self) -> editors.EditorsResourceWithStreamingResponse: from .resources.editors import EditorsResourceWithStreamingResponse @@ -835,6 +911,10 @@ def environments(self) -> environments.EnvironmentsResourceWithStreamingResponse @cached_property def errors(self) -> errors.ErrorsResourceWithStreamingResponse: + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ from .resources.errors import ErrorsResourceWithStreamingResponse return ErrorsResourceWithStreamingResponse(self._client.errors) @@ -871,6 +951,10 @@ def organizations(self) -> organizations.OrganizationsResourceWithStreamingRespo @cached_property def prebuilds(self) -> prebuilds.PrebuildsResourceWithStreamingResponse: + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ from .resources.prebuilds import PrebuildsResourceWithStreamingResponse return PrebuildsResourceWithStreamingResponse(self._client.prebuilds) @@ -895,6 +979,9 @@ def secrets(self) -> secrets.SecretsResourceWithStreamingResponse: @cached_property def usage(self) -> usage.UsageResourceWithStreamingResponse: + """ + UsageService provides usage information about environments, users, and projects. + """ from .resources.usage import UsageResourceWithStreamingResponse return UsageResourceWithStreamingResponse(self._client.usage) @@ -924,6 +1011,12 @@ def agents(self) -> agents.AsyncAgentsResourceWithStreamingResponse: return AsyncAgentsResourceWithStreamingResponse(self._client.agents) + @cached_property + def automations(self) -> automations.AsyncAutomationsResourceWithStreamingResponse: + from .resources.automations import AsyncAutomationsResourceWithStreamingResponse + + return AsyncAutomationsResourceWithStreamingResponse(self._client.automations) + @cached_property def editors(self) -> editors.AsyncEditorsResourceWithStreamingResponse: from .resources.editors import AsyncEditorsResourceWithStreamingResponse @@ -938,6 +1031,10 @@ def environments(self) -> environments.AsyncEnvironmentsResourceWithStreamingRes @cached_property def errors(self) -> errors.AsyncErrorsResourceWithStreamingResponse: + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ from .resources.errors import AsyncErrorsResourceWithStreamingResponse return AsyncErrorsResourceWithStreamingResponse(self._client.errors) @@ -974,6 +1071,10 @@ def organizations(self) -> organizations.AsyncOrganizationsResourceWithStreaming @cached_property def prebuilds(self) -> prebuilds.AsyncPrebuildsResourceWithStreamingResponse: + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ from .resources.prebuilds import AsyncPrebuildsResourceWithStreamingResponse return AsyncPrebuildsResourceWithStreamingResponse(self._client.prebuilds) @@ -998,6 +1099,9 @@ def secrets(self) -> secrets.AsyncSecretsResourceWithStreamingResponse: @cached_property def usage(self) -> usage.AsyncUsageResourceWithStreamingResponse: + """ + UsageService provides usage information about environments, users, and projects. + """ from .resources.usage import AsyncUsageResourceWithStreamingResponse return AsyncUsageResourceWithStreamingResponse(self._client.usage) diff --git a/src/gitpod/_response.py b/src/gitpod/_response.py index 6211d722..5122aac0 100644 --- a/src/gitpod/_response.py +++ b/src/gitpod/_response.py @@ -174,6 +174,7 @@ def _parse(self, *, to: type[_T] | None = None) -> R | _T: ), response=self.http_response, client=cast(Any, self._client), + options=self._options, ), ) @@ -184,6 +185,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, ), ) @@ -197,6 +199,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/gitpod/_streaming.py b/src/gitpod/_streaming.py index 9a4ccf40..e7850426 100644 --- a/src/gitpod/_streaming.py +++ b/src/gitpod/_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 Gitpod, AsyncGitpod + 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: Gitpod, + 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: AsyncGitpod, + 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/gitpod/_version.py b/src/gitpod/_version.py index dec0e423..7504df3f 100644 --- a/src/gitpod/_version.py +++ b/src/gitpod/_version.py @@ -1,4 +1,4 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. __title__ = "gitpod" -__version__ = "0.10.0" # x-release-please-version +__version__ = "0.11.0" # x-release-please-version diff --git a/src/gitpod/pagination.py b/src/gitpod/pagination.py index 0ffd69d7..b55ecc60 100644 --- a/src/gitpod/pagination.py +++ b/src/gitpod/pagination.py @@ -51,6 +51,9 @@ "MembersPagePagination", "SyncMembersPage", "AsyncMembersPage", + "OutputsPagePagination", + "SyncOutputsPage", + "AsyncOutputsPage", "PersonalAccessTokensPagePagination", "SyncPersonalAccessTokensPage", "AsyncPersonalAccessTokensPage", @@ -99,6 +102,18 @@ "TokensPagePagination", "SyncTokensPage", "AsyncTokensPage", + "WarmPoolsPagePagination", + "SyncWarmPoolsPage", + "AsyncWarmPoolsPage", + "WorkflowExecutionActionsPagePagination", + "SyncWorkflowExecutionActionsPage", + "AsyncWorkflowExecutionActionsPage", + "WorkflowExecutionsPagePagination", + "SyncWorkflowExecutionsPage", + "AsyncWorkflowExecutionsPage", + "WorkflowsPagePagination", + "SyncWorkflowsPage", + "AsyncWorkflowsPage", ] _T = TypeVar("_T") @@ -804,6 +819,56 @@ def next_page_info(self) -> Optional[PageInfo]: return PageInfo(params={"token": next_token}) +class OutputsPagePagination(BaseModel): + next_token: Optional[str] = FieldInfo(alias="nextToken", default=None) + + +class SyncOutputsPage(BaseSyncPage[_T], BasePage[_T], Generic[_T]): + outputs: List[_T] + pagination: Optional[OutputsPagePagination] = None + + @override + def _get_page_items(self) -> List[_T]: + outputs = self.outputs + if not outputs: + return [] + return outputs + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class AsyncOutputsPage(BaseAsyncPage[_T], BasePage[_T], Generic[_T]): + outputs: List[_T] + pagination: Optional[OutputsPagePagination] = None + + @override + def _get_page_items(self) -> List[_T]: + outputs = self.outputs + if not outputs: + return [] + return outputs + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + class PersonalAccessTokensPagePagination(BaseModel): next_token: Optional[str] = FieldInfo(alias="nextToken", default=None) @@ -1602,3 +1667,203 @@ def next_page_info(self) -> Optional[PageInfo]: return None return PageInfo(params={"token": next_token}) + + +class WarmPoolsPagePagination(BaseModel): + next_token: Optional[str] = FieldInfo(alias="nextToken", default=None) + + +class SyncWarmPoolsPage(BaseSyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WarmPoolsPagePagination] = None + warm_pools: List[_T] = FieldInfo(alias="warmPools") + + @override + def _get_page_items(self) -> List[_T]: + warm_pools = self.warm_pools + if not warm_pools: + return [] + return warm_pools + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class AsyncWarmPoolsPage(BaseAsyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WarmPoolsPagePagination] = None + warm_pools: List[_T] = FieldInfo(alias="warmPools") + + @override + def _get_page_items(self) -> List[_T]: + warm_pools = self.warm_pools + if not warm_pools: + return [] + return warm_pools + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class WorkflowExecutionActionsPagePagination(BaseModel): + next_token: Optional[str] = FieldInfo(alias="nextToken", default=None) + + +class SyncWorkflowExecutionActionsPage(BaseSyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WorkflowExecutionActionsPagePagination] = None + workflow_execution_actions: List[_T] = FieldInfo(alias="workflowExecutionActions") + + @override + def _get_page_items(self) -> List[_T]: + workflow_execution_actions = self.workflow_execution_actions + if not workflow_execution_actions: + return [] + return workflow_execution_actions + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class AsyncWorkflowExecutionActionsPage(BaseAsyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WorkflowExecutionActionsPagePagination] = None + workflow_execution_actions: List[_T] = FieldInfo(alias="workflowExecutionActions") + + @override + def _get_page_items(self) -> List[_T]: + workflow_execution_actions = self.workflow_execution_actions + if not workflow_execution_actions: + return [] + return workflow_execution_actions + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class WorkflowExecutionsPagePagination(BaseModel): + next_token: Optional[str] = FieldInfo(alias="nextToken", default=None) + + +class SyncWorkflowExecutionsPage(BaseSyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WorkflowExecutionsPagePagination] = None + workflow_executions: List[_T] = FieldInfo(alias="workflowExecutions") + + @override + def _get_page_items(self) -> List[_T]: + workflow_executions = self.workflow_executions + if not workflow_executions: + return [] + return workflow_executions + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class AsyncWorkflowExecutionsPage(BaseAsyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WorkflowExecutionsPagePagination] = None + workflow_executions: List[_T] = FieldInfo(alias="workflowExecutions") + + @override + def _get_page_items(self) -> List[_T]: + workflow_executions = self.workflow_executions + if not workflow_executions: + return [] + return workflow_executions + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class WorkflowsPagePagination(BaseModel): + next_token: Optional[str] = FieldInfo(alias="nextToken", default=None) + + +class SyncWorkflowsPage(BaseSyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WorkflowsPagePagination] = None + workflows: List[_T] + + @override + def _get_page_items(self) -> List[_T]: + workflows = self.workflows + if not workflows: + return [] + return workflows + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) + + +class AsyncWorkflowsPage(BaseAsyncPage[_T], BasePage[_T], Generic[_T]): + pagination: Optional[WorkflowsPagePagination] = None + workflows: List[_T] + + @override + def _get_page_items(self) -> List[_T]: + workflows = self.workflows + if not workflows: + return [] + return workflows + + @override + def next_page_info(self) -> Optional[PageInfo]: + next_token = None + if self.pagination is not None: + if self.pagination.next_token is not None: + next_token = self.pagination.next_token + if not next_token: + return None + + return PageInfo(params={"token": next_token}) diff --git a/src/gitpod/resources/__init__.py b/src/gitpod/resources/__init__.py index d5baa12a..97c0390c 100644 --- a/src/gitpod/resources/__init__.py +++ b/src/gitpod/resources/__init__.py @@ -112,6 +112,14 @@ PrebuildsResourceWithStreamingResponse, AsyncPrebuildsResourceWithStreamingResponse, ) +from .automations import ( + AutomationsResource, + AsyncAutomationsResource, + AutomationsResourceWithRawResponse, + AsyncAutomationsResourceWithRawResponse, + AutomationsResourceWithStreamingResponse, + AsyncAutomationsResourceWithStreamingResponse, +) from .environments import ( EnvironmentsResource, AsyncEnvironmentsResource, @@ -142,6 +150,12 @@ "AsyncAgentsResourceWithRawResponse", "AgentsResourceWithStreamingResponse", "AsyncAgentsResourceWithStreamingResponse", + "AutomationsResource", + "AsyncAutomationsResource", + "AutomationsResourceWithRawResponse", + "AsyncAutomationsResourceWithRawResponse", + "AutomationsResourceWithStreamingResponse", + "AsyncAutomationsResourceWithStreamingResponse", "EditorsResource", "AsyncEditorsResource", "EditorsResourceWithRawResponse", diff --git a/src/gitpod/resources/agents.py b/src/gitpod/resources/agents.py index 3206d8ce..4cabe2e8 100644 --- a/src/gitpod/resources/agents.py +++ b/src/gitpod/resources/agents.py @@ -36,6 +36,8 @@ from ..types.prompt import Prompt from ..types.agent_mode import AgentMode from ..types.agent_execution import AgentExecution +from ..types.wake_event_param import WakeEventParam +from ..types.agent_message_param import AgentMessageParam from ..types.user_input_block_param import UserInputBlockParam from ..types.agent_code_context_param import AgentCodeContextParam from ..types.agent_create_prompt_response import AgentCreatePromptResponse @@ -483,7 +485,9 @@ def send_to_execution( self, *, agent_execution_id: str | Omit = omit, + agent_message: AgentMessageParam | Omit = omit, user_input: UserInputBlockParam | Omit = omit, + wake_event: WakeEventParam | 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, @@ -510,6 +514,12 @@ def send_to_execution( ``` Args: + agent_message: AgentMessage is a message sent between agents (e.g. from a parent agent to a + child agent execution, or vice versa). + + wake_event: WakeEvent is sent by the backend to wake an agent when a registered interest + fires. Delivered via SendToAgentExecution as a new oneof variant. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -523,7 +533,9 @@ def send_to_execution( body=maybe_transform( { "agent_execution_id": agent_execution_id, + "agent_message": agent_message, "user_input": user_input, + "wake_event": wake_event, }, agent_send_to_execution_params.AgentSendToExecutionParams, ), @@ -542,6 +554,7 @@ def start_execution( mode: AgentMode | Omit = omit, name: str | Omit = omit, runner_id: str | Omit = omit, + session_id: str | Omit = omit, workflow_action_id: Optional[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. @@ -579,6 +592,9 @@ def start_execution( execution is routed to this runner instead of the runner associated with the environment. + session_id: session_id is the ID of the session this agent execution belongs to. If empty, a + new session is created implicitly. + workflow_action_id: workflow_action_id is an optional reference to the workflow execution action that created this agent execution. Used for tracking and event correlation. @@ -600,6 +616,7 @@ def start_execution( "mode": mode, "name": name, "runner_id": runner_id, + "session_id": session_id, "workflow_action_id": workflow_action_id, }, agent_start_execution_params.AgentStartExecutionParams, @@ -1149,7 +1166,9 @@ async def send_to_execution( self, *, agent_execution_id: str | Omit = omit, + agent_message: AgentMessageParam | Omit = omit, user_input: UserInputBlockParam | Omit = omit, + wake_event: WakeEventParam | 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, @@ -1176,6 +1195,12 @@ async def send_to_execution( ``` Args: + agent_message: AgentMessage is a message sent between agents (e.g. from a parent agent to a + child agent execution, or vice versa). + + wake_event: WakeEvent is sent by the backend to wake an agent when a registered interest + fires. Delivered via SendToAgentExecution as a new oneof variant. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -1189,7 +1214,9 @@ async def send_to_execution( body=await async_maybe_transform( { "agent_execution_id": agent_execution_id, + "agent_message": agent_message, "user_input": user_input, + "wake_event": wake_event, }, agent_send_to_execution_params.AgentSendToExecutionParams, ), @@ -1208,6 +1235,7 @@ async def start_execution( mode: AgentMode | Omit = omit, name: str | Omit = omit, runner_id: str | Omit = omit, + session_id: str | Omit = omit, workflow_action_id: Optional[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. @@ -1245,6 +1273,9 @@ async def start_execution( execution is routed to this runner instead of the runner associated with the environment. + session_id: session_id is the ID of the session this agent execution belongs to. If empty, a + new session is created implicitly. + workflow_action_id: workflow_action_id is an optional reference to the workflow execution action that created this agent execution. Used for tracking and event correlation. @@ -1266,6 +1297,7 @@ async def start_execution( "mode": mode, "name": name, "runner_id": runner_id, + "session_id": session_id, "workflow_action_id": workflow_action_id, }, agent_start_execution_params.AgentStartExecutionParams, diff --git a/src/gitpod/resources/automations.py b/src/gitpod/resources/automations.py new file mode 100644 index 00000000..616bc89d --- /dev/null +++ b/src/gitpod/resources/automations.py @@ -0,0 +1,2027 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Dict, Iterable, Optional + +import httpx + +from ..types import ( + automation_list_params, + automation_create_params, + automation_delete_params, + automation_update_params, + automation_retrieve_params, + automation_list_executions_params, + automation_start_execution_params, + automation_cancel_execution_params, + automation_retrieve_execution_params, + automation_list_execution_actions_params, + automation_list_execution_outputs_params, + automation_cancel_execution_action_params, + automation_retrieve_execution_action_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 +from .._resource import SyncAPIResource, AsyncAPIResource +from .._response import ( + to_raw_response_wrapper, + to_streamed_response_wrapper, + async_to_raw_response_wrapper, + async_to_streamed_response_wrapper, +) +from ..pagination import ( + SyncOutputsPage, + AsyncOutputsPage, + SyncWorkflowsPage, + AsyncWorkflowsPage, + SyncWorkflowExecutionsPage, + AsyncWorkflowExecutionsPage, + SyncWorkflowExecutionActionsPage, + AsyncWorkflowExecutionActionsPage, +) +from .._base_client import AsyncPaginator, make_request_options +from ..types.workflow import Workflow +from ..types.shared_params.sort import Sort +from ..types.workflow_execution import WorkflowExecution +from ..types.shared_params.subject import Subject +from ..types.workflow_action_param import WorkflowActionParam +from ..types.workflow_trigger_param import WorkflowTriggerParam +from ..types.workflow_execution_action import WorkflowExecutionAction +from ..types.automation_create_response import AutomationCreateResponse +from ..types.automation_update_response import AutomationUpdateResponse +from ..types.automation_retrieve_response import AutomationRetrieveResponse +from ..types.workflow_trigger_context_param import WorkflowTriggerContextParam +from ..types.automation_start_execution_response import AutomationStartExecutionResponse +from ..types.automation_retrieve_execution_response import AutomationRetrieveExecutionResponse +from ..types.automation_list_execution_outputs_response import AutomationListExecutionOutputsResponse +from ..types.automation_retrieve_execution_action_response import AutomationRetrieveExecutionActionResponse + +__all__ = ["AutomationsResource", "AsyncAutomationsResource"] + + +class AutomationsResource(SyncAPIResource): + @cached_property + def with_raw_response(self) -> AutomationsResourceWithRawResponse: + """ + This property can be used as a prefix for any HTTP method call to return + the raw response object instead of the parsed content. + + For more information, see https://www.github.com/gitpod-io/gitpod-sdk-python#accessing-raw-response-data-eg-headers + """ + return AutomationsResourceWithRawResponse(self) + + @cached_property + def with_streaming_response(self) -> AutomationsResourceWithStreamingResponse: + """ + An alternative to `.with_raw_response` that doesn't eagerly read the response body. + + For more information, see https://www.github.com/gitpod-io/gitpod-sdk-python#with_streaming_response + """ + return AutomationsResourceWithStreamingResponse(self) + + def create( + self, + *, + action: WorkflowActionParam, + description: str | Omit = omit, + executor: Optional[Subject] | Omit = omit, + name: str | Omit = omit, + report: WorkflowActionParam | Omit = omit, + triggers: Iterable[WorkflowTriggerParam] | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationCreateResponse: + """ + Creates a new workflow with specified configuration. + + Use this method to: + + - Set up automated workflows + - Configure workflow triggers + - Define workflow actions and steps + - Set execution limits and constraints + + Args: + action: WorkflowAction defines the actions to be executed in a workflow. + + description: + Description must be at most 500 characters: + + ``` + size(this) <= 500 + ``` + + executor: Optional executor for the workflow. If not provided, defaults to the creator. + Must be either the caller themselves or a service account. + + name: + Name must be between 1 and 80 characters: + + ``` + size(this) >= 1 && size(this) <= 80 + ``` + + report: WorkflowAction defines the actions to be executed in a workflow. + + triggers: + Automation must have between 1 and 10 triggers: + + ``` + size(this) >= 1 && size(this) <= 10 + ``` + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/CreateWorkflow", + body=maybe_transform( + { + "action": action, + "description": description, + "executor": executor, + "name": name, + "report": report, + "triggers": triggers, + }, + automation_create_params.AutomationCreateParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationCreateResponse, + ) + + def retrieve( + self, + *, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationRetrieveResponse: + """ + Gets details about a specific workflow. + + Use this method to: + + - View workflow configuration + - Check workflow status + - Get workflow metadata + + ### Examples + + - Get workflow details: + + Retrieves information about a specific workflow. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/GetWorkflow", + body=maybe_transform({"workflow_id": workflow_id}, automation_retrieve_params.AutomationRetrieveParams), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationRetrieveResponse, + ) + + def update( + self, + *, + action: Optional[WorkflowActionParam] | Omit = omit, + description: Optional[str] | Omit = omit, + executor: Optional[Subject] | Omit = omit, + name: Optional[str] | Omit = omit, + report: Optional[WorkflowActionParam] | Omit = omit, + triggers: Iterable[WorkflowTriggerParam] | Omit = omit, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationUpdateResponse: + """ + Updates a workflow's configuration using full replacement semantics. + + Update Behavior: + + - All provided fields completely replace existing values + - Optional fields that are not provided remain unchanged + - Complex fields (triggers, action) are replaced entirely, not merged + - To remove optional fields, explicitly set them to empty/default values + + Use this method to: + + - Modify workflow settings + - Update triggers and actions + - Change execution limits + - Update workflow steps + + ### Examples + + - Update workflow name: + + Changes the workflow's display name. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + name: "Updated Workflow Name" + ``` + + - Replace all triggers: + + Completely replaces the workflow's trigger configuration. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + triggers: + - manual: {} + context: + projects: + projectIds: ["new-project-id"] + ``` + + - Update execution limits: + + Completely replaces the workflow's action configuration. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + action: + limits: + maxParallel: 10 + maxTotal: 100 + steps: + - task: + command: "npm test" + ``` + + Args: + action: WorkflowAction defines the actions to be executed in a workflow. + + description: + Description must be at most 500 characters: + + ``` + size(this) <= 500 + ``` + + name: + Name must be between 1 and 80 characters: + + ``` + size(this) >= 1 && size(this) <= 80 + ``` + + report: WorkflowAction defines the actions to be executed in a workflow. + + triggers: + Automation can have at most 10 triggers: + + ``` + size(this) <= 10 + ``` + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/UpdateWorkflow", + body=maybe_transform( + { + "action": action, + "description": description, + "executor": executor, + "name": name, + "report": report, + "triggers": triggers, + "workflow_id": workflow_id, + }, + automation_update_params.AutomationUpdateParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationUpdateResponse, + ) + + def list( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_params.Filter | Omit = omit, + pagination: automation_list_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> SyncWorkflowsPage[Workflow]: + """ + ListWorkflows + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflows", + page=SyncWorkflowsPage[Workflow], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + automation_list_params.AutomationListParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_params.AutomationListParams, + ), + ), + model=Workflow, + method="post", + ) + + def delete( + self, + *, + force: bool | Omit = omit, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """ + Deletes a workflow permanently. + + Use this method to: + + - Remove unused workflows + - Clean up test workflows + - Delete obsolete configurations + + ### Examples + + - Delete workflow: + + Permanently removes a workflow. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + ``` + + Args: + force: force indicates whether to immediately delete the workflow and all related + resources. When true, performs cascading deletion of: + + - All workflow executions + - All workflow execution actions + - All environments created by workflow actions + - All agent executions created by workflow actions + - The workflow itself When false (default), marks workflow executions for + deletion and relies on background reconciliation to clean up resources. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/DeleteWorkflow", + body=maybe_transform( + { + "force": force, + "workflow_id": workflow_id, + }, + automation_delete_params.AutomationDeleteParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + def cancel_execution( + self, + *, + workflow_execution_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """ + Cancels a running workflow execution. + + Use this method to: + + - Stop long-running executions + - Cancel failed executions + - Manage resource usage + + ### Examples + + - Cancel execution: + + Stops a running workflow execution. + + ```yaml + workflowExecutionId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/CancelWorkflowExecution", + body=maybe_transform( + {"workflow_execution_id": workflow_execution_id}, + automation_cancel_execution_params.AutomationCancelExecutionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + def cancel_execution_action( + self, + *, + workflow_execution_action_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """ + Cancels a running workflow execution action. + + Use this method to: + + - Stop long-running actions + - Cancel failed actions + - Manage resource usage + + ### Examples + + - Cancel execution action: + + Stops a running workflow execution action. + + ```yaml + workflowExecutionActionId: "a1b2c3d4-5e6f-7890-abcd-ef1234567890" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/CancelWorkflowExecutionAction", + body=maybe_transform( + {"workflow_execution_action_id": workflow_execution_action_id}, + automation_cancel_execution_action_params.AutomationCancelExecutionActionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + def list_execution_actions( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_execution_actions_params.Filter | Omit = omit, + pagination: automation_list_execution_actions_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> SyncWorkflowExecutionActionsPage[WorkflowExecutionAction]: + """ + Lists workflow execution actions with optional filtering. + + Use this method to: + + - Monitor individual action execution status + - Debug action failures + - Track resource usage per action + + ### Examples + + - List execution actions for workflow execution: + + Shows all execution actions for a specific workflow execution. + + ```yaml + filter: + workflowExecutionIds: ["d2c94c27-3b76-4a42-b88c-95a85e392c68"] + pagination: + pageSize: 20 + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflowExecutionActions", + page=SyncWorkflowExecutionActionsPage[WorkflowExecutionAction], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + automation_list_execution_actions_params.AutomationListExecutionActionsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_execution_actions_params.AutomationListExecutionActionsParams, + ), + ), + model=WorkflowExecutionAction, + method="post", + ) + + def list_execution_outputs( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_execution_outputs_params.Filter | Omit = omit, + pagination: automation_list_execution_outputs_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> SyncOutputsPage[AutomationListExecutionOutputsResponse]: + """ + Lists outputs produced by workflow execution actions. + + Use this method to: + + - Retrieve test results, coverage metrics, or other structured data from + executions + - Aggregate outputs across multiple workflow executions + - Build dashboards or reports from execution data + + ### Examples + + - List outputs for a workflow execution: + + Retrieves all outputs produced by actions in the specified execution. + + ```yaml + filter: + workflowExecutionIds: ["d2c94c27-3b76-4a42-b88c-95a85e392c68"] + pagination: + pageSize: 50 + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflowExecutionOutputs", + page=SyncOutputsPage[AutomationListExecutionOutputsResponse], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + automation_list_execution_outputs_params.AutomationListExecutionOutputsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_execution_outputs_params.AutomationListExecutionOutputsParams, + ), + ), + model=AutomationListExecutionOutputsResponse, + method="post", + ) + + def list_executions( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_executions_params.Filter | Omit = omit, + pagination: automation_list_executions_params.Pagination | Omit = omit, + sort: Sort | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> SyncWorkflowExecutionsPage[WorkflowExecution]: + """ + Lists workflow executions with optional filtering. + + Use this method to: + + - Monitor workflow execution history + - Track execution status + - Debug workflow issues + + ### Examples + + - List executions for workflow: + + Shows all executions for a specific workflow. + + ```yaml + filter: + workflowIds: ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"] + pagination: + pageSize: 20 + ``` + + Args: + sort: sort specifies the order of results. When unspecified, results are sorted by + operational priority (running first, then failed, then completed, then others). + Supported sort fields: startedAt, finishedAt, createdAt. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflowExecutions", + page=SyncWorkflowExecutionsPage[WorkflowExecution], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + "sort": sort, + }, + automation_list_executions_params.AutomationListExecutionsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_executions_params.AutomationListExecutionsParams, + ), + ), + model=WorkflowExecution, + method="post", + ) + + def retrieve_execution( + self, + *, + workflow_execution_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationRetrieveExecutionResponse: + """ + Gets details about a specific workflow execution. + + Use this method to: + + - Check execution status + - View execution results + - Monitor execution progress + + ### Examples + + - Get execution details: + + Retrieves information about a specific execution. + + ```yaml + workflowExecutionId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/GetWorkflowExecution", + body=maybe_transform( + {"workflow_execution_id": workflow_execution_id}, + automation_retrieve_execution_params.AutomationRetrieveExecutionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationRetrieveExecutionResponse, + ) + + def retrieve_execution_action( + self, + *, + workflow_execution_action_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationRetrieveExecutionActionResponse: + """ + Gets details about a specific workflow execution action. + + Use this method to: + + - Check execution action status + - View execution action results + - Monitor execution action progress + + ### Examples + + - Get execution action details: + + Retrieves information about a specific execution action. + + ```yaml + workflowExecutionActionId: "a1b2c3d4-5e6f-7890-abcd-ef1234567890" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/GetWorkflowExecutionAction", + body=maybe_transform( + {"workflow_execution_action_id": workflow_execution_action_id}, + automation_retrieve_execution_action_params.AutomationRetrieveExecutionActionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationRetrieveExecutionActionResponse, + ) + + def start_execution( + self, + *, + context_override: Optional[WorkflowTriggerContextParam] | Omit = omit, + parameters: Dict[str, str] | Omit = omit, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationStartExecutionResponse: + """ + Starts a workflow execution. + + Use this method to: + + - Start workflow execution on demand + - Test workflow configurations + - Run workflows outside of automatic triggers + + ### Examples + + - Start workflow: + + Starts a workflow execution manually. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + ``` + + Args: + context_override: Optional context override for the execution. When provided, replaces the + workflow's default trigger context. User must have appropriate permissions on + the overridden resources. Supports Projects, Repositories, and Agent context + types. FromTrigger context type is not supported for manual overrides. + + parameters: Parameters to substitute into workflow steps using Go template syntax. Use + {{ .Parameters.key_name }} in templatable fields (task.command, agent.prompt, + pull*request.title/description/branch, trigger context agent.prompt). Keys must + match pattern ^[a-zA-Z*][a-zA-Z0-9_]\\**$ Maximum 10 parameters allowed. Empty map + is treated as no parameters provided. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.WorkflowService/StartWorkflow", + body=maybe_transform( + { + "context_override": context_override, + "parameters": parameters, + "workflow_id": workflow_id, + }, + automation_start_execution_params.AutomationStartExecutionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationStartExecutionResponse, + ) + + +class AsyncAutomationsResource(AsyncAPIResource): + @cached_property + def with_raw_response(self) -> AsyncAutomationsResourceWithRawResponse: + """ + This property can be used as a prefix for any HTTP method call to return + the raw response object instead of the parsed content. + + For more information, see https://www.github.com/gitpod-io/gitpod-sdk-python#accessing-raw-response-data-eg-headers + """ + return AsyncAutomationsResourceWithRawResponse(self) + + @cached_property + def with_streaming_response(self) -> AsyncAutomationsResourceWithStreamingResponse: + """ + An alternative to `.with_raw_response` that doesn't eagerly read the response body. + + For more information, see https://www.github.com/gitpod-io/gitpod-sdk-python#with_streaming_response + """ + return AsyncAutomationsResourceWithStreamingResponse(self) + + async def create( + self, + *, + action: WorkflowActionParam, + description: str | Omit = omit, + executor: Optional[Subject] | Omit = omit, + name: str | Omit = omit, + report: WorkflowActionParam | Omit = omit, + triggers: Iterable[WorkflowTriggerParam] | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationCreateResponse: + """ + Creates a new workflow with specified configuration. + + Use this method to: + + - Set up automated workflows + - Configure workflow triggers + - Define workflow actions and steps + - Set execution limits and constraints + + Args: + action: WorkflowAction defines the actions to be executed in a workflow. + + description: + Description must be at most 500 characters: + + ``` + size(this) <= 500 + ``` + + executor: Optional executor for the workflow. If not provided, defaults to the creator. + Must be either the caller themselves or a service account. + + name: + Name must be between 1 and 80 characters: + + ``` + size(this) >= 1 && size(this) <= 80 + ``` + + report: WorkflowAction defines the actions to be executed in a workflow. + + triggers: + Automation must have between 1 and 10 triggers: + + ``` + size(this) >= 1 && size(this) <= 10 + ``` + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/CreateWorkflow", + body=await async_maybe_transform( + { + "action": action, + "description": description, + "executor": executor, + "name": name, + "report": report, + "triggers": triggers, + }, + automation_create_params.AutomationCreateParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationCreateResponse, + ) + + async def retrieve( + self, + *, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationRetrieveResponse: + """ + Gets details about a specific workflow. + + Use this method to: + + - View workflow configuration + - Check workflow status + - Get workflow metadata + + ### Examples + + - Get workflow details: + + Retrieves information about a specific workflow. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/GetWorkflow", + body=await async_maybe_transform( + {"workflow_id": workflow_id}, automation_retrieve_params.AutomationRetrieveParams + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationRetrieveResponse, + ) + + async def update( + self, + *, + action: Optional[WorkflowActionParam] | Omit = omit, + description: Optional[str] | Omit = omit, + executor: Optional[Subject] | Omit = omit, + name: Optional[str] | Omit = omit, + report: Optional[WorkflowActionParam] | Omit = omit, + triggers: Iterable[WorkflowTriggerParam] | Omit = omit, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationUpdateResponse: + """ + Updates a workflow's configuration using full replacement semantics. + + Update Behavior: + + - All provided fields completely replace existing values + - Optional fields that are not provided remain unchanged + - Complex fields (triggers, action) are replaced entirely, not merged + - To remove optional fields, explicitly set them to empty/default values + + Use this method to: + + - Modify workflow settings + - Update triggers and actions + - Change execution limits + - Update workflow steps + + ### Examples + + - Update workflow name: + + Changes the workflow's display name. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + name: "Updated Workflow Name" + ``` + + - Replace all triggers: + + Completely replaces the workflow's trigger configuration. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + triggers: + - manual: {} + context: + projects: + projectIds: ["new-project-id"] + ``` + + - Update execution limits: + + Completely replaces the workflow's action configuration. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + action: + limits: + maxParallel: 10 + maxTotal: 100 + steps: + - task: + command: "npm test" + ``` + + Args: + action: WorkflowAction defines the actions to be executed in a workflow. + + description: + Description must be at most 500 characters: + + ``` + size(this) <= 500 + ``` + + name: + Name must be between 1 and 80 characters: + + ``` + size(this) >= 1 && size(this) <= 80 + ``` + + report: WorkflowAction defines the actions to be executed in a workflow. + + triggers: + Automation can have at most 10 triggers: + + ``` + size(this) <= 10 + ``` + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/UpdateWorkflow", + body=await async_maybe_transform( + { + "action": action, + "description": description, + "executor": executor, + "name": name, + "report": report, + "triggers": triggers, + "workflow_id": workflow_id, + }, + automation_update_params.AutomationUpdateParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationUpdateResponse, + ) + + def list( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_params.Filter | Omit = omit, + pagination: automation_list_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AsyncPaginator[Workflow, AsyncWorkflowsPage[Workflow]]: + """ + ListWorkflows + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflows", + page=AsyncWorkflowsPage[Workflow], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + automation_list_params.AutomationListParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_params.AutomationListParams, + ), + ), + model=Workflow, + method="post", + ) + + async def delete( + self, + *, + force: bool | Omit = omit, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """ + Deletes a workflow permanently. + + Use this method to: + + - Remove unused workflows + - Clean up test workflows + - Delete obsolete configurations + + ### Examples + + - Delete workflow: + + Permanently removes a workflow. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + ``` + + Args: + force: force indicates whether to immediately delete the workflow and all related + resources. When true, performs cascading deletion of: + + - All workflow executions + - All workflow execution actions + - All environments created by workflow actions + - All agent executions created by workflow actions + - The workflow itself When false (default), marks workflow executions for + deletion and relies on background reconciliation to clean up resources. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/DeleteWorkflow", + body=await async_maybe_transform( + { + "force": force, + "workflow_id": workflow_id, + }, + automation_delete_params.AutomationDeleteParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + async def cancel_execution( + self, + *, + workflow_execution_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """ + Cancels a running workflow execution. + + Use this method to: + + - Stop long-running executions + - Cancel failed executions + - Manage resource usage + + ### Examples + + - Cancel execution: + + Stops a running workflow execution. + + ```yaml + workflowExecutionId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/CancelWorkflowExecution", + body=await async_maybe_transform( + {"workflow_execution_id": workflow_execution_id}, + automation_cancel_execution_params.AutomationCancelExecutionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + async def cancel_execution_action( + self, + *, + workflow_execution_action_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """ + Cancels a running workflow execution action. + + Use this method to: + + - Stop long-running actions + - Cancel failed actions + - Manage resource usage + + ### Examples + + - Cancel execution action: + + Stops a running workflow execution action. + + ```yaml + workflowExecutionActionId: "a1b2c3d4-5e6f-7890-abcd-ef1234567890" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/CancelWorkflowExecutionAction", + body=await async_maybe_transform( + {"workflow_execution_action_id": workflow_execution_action_id}, + automation_cancel_execution_action_params.AutomationCancelExecutionActionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + def list_execution_actions( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_execution_actions_params.Filter | Omit = omit, + pagination: automation_list_execution_actions_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AsyncPaginator[WorkflowExecutionAction, AsyncWorkflowExecutionActionsPage[WorkflowExecutionAction]]: + """ + Lists workflow execution actions with optional filtering. + + Use this method to: + + - Monitor individual action execution status + - Debug action failures + - Track resource usage per action + + ### Examples + + - List execution actions for workflow execution: + + Shows all execution actions for a specific workflow execution. + + ```yaml + filter: + workflowExecutionIds: ["d2c94c27-3b76-4a42-b88c-95a85e392c68"] + pagination: + pageSize: 20 + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflowExecutionActions", + page=AsyncWorkflowExecutionActionsPage[WorkflowExecutionAction], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + automation_list_execution_actions_params.AutomationListExecutionActionsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_execution_actions_params.AutomationListExecutionActionsParams, + ), + ), + model=WorkflowExecutionAction, + method="post", + ) + + def list_execution_outputs( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_execution_outputs_params.Filter | Omit = omit, + pagination: automation_list_execution_outputs_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AsyncPaginator[ + AutomationListExecutionOutputsResponse, AsyncOutputsPage[AutomationListExecutionOutputsResponse] + ]: + """ + Lists outputs produced by workflow execution actions. + + Use this method to: + + - Retrieve test results, coverage metrics, or other structured data from + executions + - Aggregate outputs across multiple workflow executions + - Build dashboards or reports from execution data + + ### Examples + + - List outputs for a workflow execution: + + Retrieves all outputs produced by actions in the specified execution. + + ```yaml + filter: + workflowExecutionIds: ["d2c94c27-3b76-4a42-b88c-95a85e392c68"] + pagination: + pageSize: 50 + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflowExecutionOutputs", + page=AsyncOutputsPage[AutomationListExecutionOutputsResponse], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + automation_list_execution_outputs_params.AutomationListExecutionOutputsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_execution_outputs_params.AutomationListExecutionOutputsParams, + ), + ), + model=AutomationListExecutionOutputsResponse, + method="post", + ) + + def list_executions( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: automation_list_executions_params.Filter | Omit = omit, + pagination: automation_list_executions_params.Pagination | Omit = omit, + sort: Sort | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AsyncPaginator[WorkflowExecution, AsyncWorkflowExecutionsPage[WorkflowExecution]]: + """ + Lists workflow executions with optional filtering. + + Use this method to: + + - Monitor workflow execution history + - Track execution status + - Debug workflow issues + + ### Examples + + - List executions for workflow: + + Shows all executions for a specific workflow. + + ```yaml + filter: + workflowIds: ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"] + pagination: + pageSize: 20 + ``` + + Args: + sort: sort specifies the order of results. When unspecified, results are sorted by + operational priority (running first, then failed, then completed, then others). + Supported sort fields: startedAt, finishedAt, createdAt. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.WorkflowService/ListWorkflowExecutions", + page=AsyncWorkflowExecutionsPage[WorkflowExecution], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + "sort": sort, + }, + automation_list_executions_params.AutomationListExecutionsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + automation_list_executions_params.AutomationListExecutionsParams, + ), + ), + model=WorkflowExecution, + method="post", + ) + + async def retrieve_execution( + self, + *, + workflow_execution_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationRetrieveExecutionResponse: + """ + Gets details about a specific workflow execution. + + Use this method to: + + - Check execution status + - View execution results + - Monitor execution progress + + ### Examples + + - Get execution details: + + Retrieves information about a specific execution. + + ```yaml + workflowExecutionId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/GetWorkflowExecution", + body=await async_maybe_transform( + {"workflow_execution_id": workflow_execution_id}, + automation_retrieve_execution_params.AutomationRetrieveExecutionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationRetrieveExecutionResponse, + ) + + async def retrieve_execution_action( + self, + *, + workflow_execution_action_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationRetrieveExecutionActionResponse: + """ + Gets details about a specific workflow execution action. + + Use this method to: + + - Check execution action status + - View execution action results + - Monitor execution action progress + + ### Examples + + - Get execution action details: + + Retrieves information about a specific execution action. + + ```yaml + workflowExecutionActionId: "a1b2c3d4-5e6f-7890-abcd-ef1234567890" + ``` + + Args: + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/GetWorkflowExecutionAction", + body=await async_maybe_transform( + {"workflow_execution_action_id": workflow_execution_action_id}, + automation_retrieve_execution_action_params.AutomationRetrieveExecutionActionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationRetrieveExecutionActionResponse, + ) + + async def start_execution( + self, + *, + context_override: Optional[WorkflowTriggerContextParam] | Omit = omit, + parameters: Dict[str, str] | Omit = omit, + workflow_id: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AutomationStartExecutionResponse: + """ + Starts a workflow execution. + + Use this method to: + + - Start workflow execution on demand + - Test workflow configurations + - Run workflows outside of automatic triggers + + ### Examples + + - Start workflow: + + Starts a workflow execution manually. + + ```yaml + workflowId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + ``` + + Args: + context_override: Optional context override for the execution. When provided, replaces the + workflow's default trigger context. User must have appropriate permissions on + the overridden resources. Supports Projects, Repositories, and Agent context + types. FromTrigger context type is not supported for manual overrides. + + parameters: Parameters to substitute into workflow steps using Go template syntax. Use + {{ .Parameters.key_name }} in templatable fields (task.command, agent.prompt, + pull*request.title/description/branch, trigger context agent.prompt). Keys must + match pattern ^[a-zA-Z*][a-zA-Z0-9_]\\**$ Maximum 10 parameters allowed. Empty map + is treated as no parameters provided. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.WorkflowService/StartWorkflow", + body=await async_maybe_transform( + { + "context_override": context_override, + "parameters": parameters, + "workflow_id": workflow_id, + }, + automation_start_execution_params.AutomationStartExecutionParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=AutomationStartExecutionResponse, + ) + + +class AutomationsResourceWithRawResponse: + def __init__(self, automations: AutomationsResource) -> None: + self._automations = automations + + self.create = to_raw_response_wrapper( + automations.create, + ) + self.retrieve = to_raw_response_wrapper( + automations.retrieve, + ) + self.update = to_raw_response_wrapper( + automations.update, + ) + self.list = to_raw_response_wrapper( + automations.list, + ) + self.delete = to_raw_response_wrapper( + automations.delete, + ) + self.cancel_execution = to_raw_response_wrapper( + automations.cancel_execution, + ) + self.cancel_execution_action = to_raw_response_wrapper( + automations.cancel_execution_action, + ) + self.list_execution_actions = to_raw_response_wrapper( + automations.list_execution_actions, + ) + self.list_execution_outputs = to_raw_response_wrapper( + automations.list_execution_outputs, + ) + self.list_executions = to_raw_response_wrapper( + automations.list_executions, + ) + self.retrieve_execution = to_raw_response_wrapper( + automations.retrieve_execution, + ) + self.retrieve_execution_action = to_raw_response_wrapper( + automations.retrieve_execution_action, + ) + self.start_execution = to_raw_response_wrapper( + automations.start_execution, + ) + + +class AsyncAutomationsResourceWithRawResponse: + def __init__(self, automations: AsyncAutomationsResource) -> None: + self._automations = automations + + self.create = async_to_raw_response_wrapper( + automations.create, + ) + self.retrieve = async_to_raw_response_wrapper( + automations.retrieve, + ) + self.update = async_to_raw_response_wrapper( + automations.update, + ) + self.list = async_to_raw_response_wrapper( + automations.list, + ) + self.delete = async_to_raw_response_wrapper( + automations.delete, + ) + self.cancel_execution = async_to_raw_response_wrapper( + automations.cancel_execution, + ) + self.cancel_execution_action = async_to_raw_response_wrapper( + automations.cancel_execution_action, + ) + self.list_execution_actions = async_to_raw_response_wrapper( + automations.list_execution_actions, + ) + self.list_execution_outputs = async_to_raw_response_wrapper( + automations.list_execution_outputs, + ) + self.list_executions = async_to_raw_response_wrapper( + automations.list_executions, + ) + self.retrieve_execution = async_to_raw_response_wrapper( + automations.retrieve_execution, + ) + self.retrieve_execution_action = async_to_raw_response_wrapper( + automations.retrieve_execution_action, + ) + self.start_execution = async_to_raw_response_wrapper( + automations.start_execution, + ) + + +class AutomationsResourceWithStreamingResponse: + def __init__(self, automations: AutomationsResource) -> None: + self._automations = automations + + self.create = to_streamed_response_wrapper( + automations.create, + ) + self.retrieve = to_streamed_response_wrapper( + automations.retrieve, + ) + self.update = to_streamed_response_wrapper( + automations.update, + ) + self.list = to_streamed_response_wrapper( + automations.list, + ) + self.delete = to_streamed_response_wrapper( + automations.delete, + ) + self.cancel_execution = to_streamed_response_wrapper( + automations.cancel_execution, + ) + self.cancel_execution_action = to_streamed_response_wrapper( + automations.cancel_execution_action, + ) + self.list_execution_actions = to_streamed_response_wrapper( + automations.list_execution_actions, + ) + self.list_execution_outputs = to_streamed_response_wrapper( + automations.list_execution_outputs, + ) + self.list_executions = to_streamed_response_wrapper( + automations.list_executions, + ) + self.retrieve_execution = to_streamed_response_wrapper( + automations.retrieve_execution, + ) + self.retrieve_execution_action = to_streamed_response_wrapper( + automations.retrieve_execution_action, + ) + self.start_execution = to_streamed_response_wrapper( + automations.start_execution, + ) + + +class AsyncAutomationsResourceWithStreamingResponse: + def __init__(self, automations: AsyncAutomationsResource) -> None: + self._automations = automations + + self.create = async_to_streamed_response_wrapper( + automations.create, + ) + self.retrieve = async_to_streamed_response_wrapper( + automations.retrieve, + ) + self.update = async_to_streamed_response_wrapper( + automations.update, + ) + self.list = async_to_streamed_response_wrapper( + automations.list, + ) + self.delete = async_to_streamed_response_wrapper( + automations.delete, + ) + self.cancel_execution = async_to_streamed_response_wrapper( + automations.cancel_execution, + ) + self.cancel_execution_action = async_to_streamed_response_wrapper( + automations.cancel_execution_action, + ) + self.list_execution_actions = async_to_streamed_response_wrapper( + automations.list_execution_actions, + ) + self.list_execution_outputs = async_to_streamed_response_wrapper( + automations.list_execution_outputs, + ) + self.list_executions = async_to_streamed_response_wrapper( + automations.list_executions, + ) + self.retrieve_execution = async_to_streamed_response_wrapper( + automations.retrieve_execution, + ) + self.retrieve_execution_action = async_to_streamed_response_wrapper( + automations.retrieve_execution_action, + ) + self.start_execution = async_to_streamed_response_wrapper( + automations.start_execution, + ) diff --git a/src/gitpod/resources/environments/environments.py b/src/gitpod/resources/environments/environments.py index 3f5defc8..24d3584e 100644 --- a/src/gitpod/resources/environments/environments.py +++ b/src/gitpod/resources/environments/environments.py @@ -92,6 +92,7 @@ def create( self, *, name: Optional[str] | Omit = omit, + session_id: str | Omit = omit, spec: EnvironmentSpecParam | 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. @@ -168,6 +169,9 @@ def create( name: name is a user-defined identifier for the environment. If not specified, the system will generate a name. + session_id: session_id is the ID of the session this environment belongs to. If empty, a new + session is created implicitly. + spec: spec is the configuration of the environment that's required for the to start the environment @@ -184,6 +188,7 @@ def create( body=maybe_transform( { "name": name, + "session_id": session_id, "spec": spec, }, environment_create_params.EnvironmentCreateParams, @@ -921,6 +926,7 @@ async def create( self, *, name: Optional[str] | Omit = omit, + session_id: str | Omit = omit, spec: EnvironmentSpecParam | 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. @@ -997,6 +1003,9 @@ async def create( name: name is a user-defined identifier for the environment. If not specified, the system will generate a name. + session_id: session_id is the ID of the session this environment belongs to. If empty, a new + session is created implicitly. + spec: spec is the configuration of the environment that's required for the to start the environment @@ -1013,6 +1022,7 @@ async def create( body=await async_maybe_transform( { "name": name, + "session_id": session_id, "spec": spec, }, environment_create_params.EnvironmentCreateParams, diff --git a/src/gitpod/resources/errors.py b/src/gitpod/resources/errors.py index 220301f2..68f6e2b4 100644 --- a/src/gitpod/resources/errors.py +++ b/src/gitpod/resources/errors.py @@ -24,6 +24,11 @@ class ErrorsResource(SyncAPIResource): + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ + @cached_property def with_raw_response(self) -> ErrorsResourceWithRawResponse: """ @@ -94,6 +99,11 @@ def report_errors( class AsyncErrorsResource(AsyncAPIResource): + """ + ErrorsService provides endpoints for clients to report errors + that will be sent to error reporting systems. + """ + @cached_property def with_raw_response(self) -> AsyncErrorsResourceWithRawResponse: """ diff --git a/src/gitpod/resources/events.py b/src/gitpod/resources/events.py index a37c2a27..179eb6cb 100644 --- a/src/gitpod/resources/events.py +++ b/src/gitpod/resources/events.py @@ -2,6 +2,8 @@ from __future__ import annotations +from typing import Iterable + import httpx from ..types import event_list_params, event_watch_params @@ -18,6 +20,7 @@ from ..pagination import SyncEntriesPage, AsyncEntriesPage from .._base_client import AsyncPaginator, make_request_options from .._decoders.jsonl import JSONLDecoder, AsyncJSONLDecoder +from ..types.shared_params.sort import Sort from ..types.event_list_response import EventListResponse from ..types.event_watch_response import EventWatchResponse @@ -51,6 +54,7 @@ def list( page_size: int | Omit = omit, filter: event_list_params.Filter | Omit = omit, pagination: event_list_params.Pagination | Omit = omit, + sort: Sort | 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, @@ -86,8 +90,21 @@ def list( pageSize: 20 ``` + - Filter by time range: + + ```yaml + filter: + from: "2024-01-01T00:00:00Z" + to: "2024-02-01T00:00:00Z" + pagination: + pageSize: 20 + ``` + Args: - pagination: pagination contains the pagination options for listing environments + pagination: pagination contains the pagination options for listing audit logs + + sort: sort specifies the order of results. When unspecified, results are sorted by + creation time descending (newest first). Supported sort fields: createdAt. extra_headers: Send extra headers @@ -104,6 +121,7 @@ def list( { "filter": filter, "pagination": pagination, + "sort": sort, }, event_list_params.EventListParams, ), @@ -129,6 +147,7 @@ def watch( *, environment_id: str | Omit = omit, organization: bool | Omit = omit, + resource_type_filters: Iterable[event_watch_params.ResourceTypeFilter] | 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, @@ -163,6 +182,11 @@ def watch( the caller can see within their organization. No task, task execution or service events are produed. + resource_type_filters: Filters to limit which events are delivered on organization-scoped streams. When + empty, all events for the scope are delivered. When populated, only events + matching at least one filter entry are forwarded. Not supported for + environment-scoped streams; setting this field returns an error. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -178,6 +202,7 @@ def watch( { "environment_id": environment_id, "organization": organization, + "resource_type_filters": resource_type_filters, }, event_watch_params.EventWatchParams, ), @@ -216,6 +241,7 @@ def list( page_size: int | Omit = omit, filter: event_list_params.Filter | Omit = omit, pagination: event_list_params.Pagination | Omit = omit, + sort: Sort | 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, @@ -251,8 +277,21 @@ def list( pageSize: 20 ``` + - Filter by time range: + + ```yaml + filter: + from: "2024-01-01T00:00:00Z" + to: "2024-02-01T00:00:00Z" + pagination: + pageSize: 20 + ``` + Args: - pagination: pagination contains the pagination options for listing environments + pagination: pagination contains the pagination options for listing audit logs + + sort: sort specifies the order of results. When unspecified, results are sorted by + creation time descending (newest first). Supported sort fields: createdAt. extra_headers: Send extra headers @@ -269,6 +308,7 @@ def list( { "filter": filter, "pagination": pagination, + "sort": sort, }, event_list_params.EventListParams, ), @@ -294,6 +334,7 @@ async def watch( *, environment_id: str | Omit = omit, organization: bool | Omit = omit, + resource_type_filters: Iterable[event_watch_params.ResourceTypeFilter] | 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, @@ -328,6 +369,11 @@ async def watch( the caller can see within their organization. No task, task execution or service events are produed. + resource_type_filters: Filters to limit which events are delivered on organization-scoped streams. When + empty, all events for the scope are delivered. When populated, only events + matching at least one filter entry are forwarded. Not supported for + environment-scoped streams; setting this field returns an error. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -343,6 +389,7 @@ async def watch( { "environment_id": environment_id, "organization": organization, + "resource_type_filters": resource_type_filters, }, event_watch_params.EventWatchParams, ), diff --git a/src/gitpod/resources/groups/groups.py b/src/gitpod/resources/groups/groups.py index bebd369b..f32fe099 100644 --- a/src/gitpod/resources/groups/groups.py +++ b/src/gitpod/resources/groups/groups.py @@ -270,6 +270,7 @@ def list( *, token: str | Omit = omit, page_size: int | Omit = omit, + filter: group_list_params.Filter | Omit = omit, pagination: group_list_params.Pagination | 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. @@ -314,6 +315,8 @@ def list( All organization members can list groups (transparency model). Args: + filter: filter contains options for filtering the list of groups. + pagination: pagination contains the pagination options for listing groups extra_headers: Send extra headers @@ -327,7 +330,13 @@ def list( return self._get_api_list( "/gitpod.v1.GroupService/ListGroups", page=SyncGroupsPage[Group], - body=maybe_transform({"pagination": pagination}, group_list_params.GroupListParams), + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + group_list_params.GroupListParams, + ), options=make_request_options( extra_headers=extra_headers, extra_query=extra_query, @@ -614,6 +623,7 @@ def list( *, token: str | Omit = omit, page_size: int | Omit = omit, + filter: group_list_params.Filter | Omit = omit, pagination: group_list_params.Pagination | 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. @@ -658,6 +668,8 @@ def list( All organization members can list groups (transparency model). Args: + filter: filter contains options for filtering the list of groups. + pagination: pagination contains the pagination options for listing groups extra_headers: Send extra headers @@ -671,7 +683,13 @@ def list( return self._get_api_list( "/gitpod.v1.GroupService/ListGroups", page=AsyncGroupsPage[Group], - body=maybe_transform({"pagination": pagination}, group_list_params.GroupListParams), + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + group_list_params.GroupListParams, + ), options=make_request_options( extra_headers=extra_headers, extra_query=extra_query, diff --git a/src/gitpod/resources/groups/memberships.py b/src/gitpod/resources/groups/memberships.py index 9ccee3ce..6183457e 100644 --- a/src/gitpod/resources/groups/memberships.py +++ b/src/gitpod/resources/groups/memberships.py @@ -182,6 +182,7 @@ def list( *, token: str | Omit = omit, page_size: int | Omit = omit, + filter: membership_list_params.Filter | Omit = omit, group_id: str | Omit = omit, pagination: membership_list_params.Pagination | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. @@ -216,6 +217,8 @@ def list( All organization members can view group membership (transparency model). Args: + filter: filter contains options for filtering the list of memberships. + pagination: pagination contains the pagination options for listing memberships extra_headers: Send extra headers @@ -231,6 +234,7 @@ def list( page=SyncMembersPage[GroupMembership], body=maybe_transform( { + "filter": filter, "group_id": group_id, "pagination": pagination, }, @@ -460,6 +464,7 @@ def list( *, token: str | Omit = omit, page_size: int | Omit = omit, + filter: membership_list_params.Filter | Omit = omit, group_id: str | Omit = omit, pagination: membership_list_params.Pagination | Omit = omit, # Use the following arguments if you need to pass additional parameters to the API that aren't available via kwargs. @@ -494,6 +499,8 @@ def list( All organization members can view group membership (transparency model). Args: + filter: filter contains options for filtering the list of memberships. + pagination: pagination contains the pagination options for listing memberships extra_headers: Send extra headers @@ -509,6 +516,7 @@ def list( page=AsyncMembersPage[GroupMembership], body=maybe_transform( { + "filter": filter, "group_id": group_id, "pagination": pagination, }, diff --git a/src/gitpod/resources/organizations/policies.py b/src/gitpod/resources/organizations/policies.py index da3cb4d2..a9d30bfb 100644 --- a/src/gitpod/resources/organizations/policies.py +++ b/src/gitpod/resources/organizations/policies.py @@ -105,7 +105,6 @@ def update( default_environment_image: Optional[str] | Omit = omit, delete_archived_environments_after: Optional[str] | Omit = omit, editor_version_restrictions: Dict[str, policy_update_params.EditorVersionRestrictions] | Omit = omit, - executable_deny_list: Optional[VetoExecPolicyParam] | Omit = omit, maximum_environment_lifetime: Optional[str] | Omit = omit, maximum_environments_per_user: Optional[str] | Omit = omit, maximum_environment_timeout: Optional[str] | Omit = omit, @@ -116,6 +115,7 @@ def update( require_custom_domain_access: Optional[bool] | Omit = omit, restrict_account_creation_to_scim: Optional[bool] | Omit = omit, security_agent_policy: Optional[policy_update_params.SecurityAgentPolicy] | Omit = omit, + veto_exec_policy: Optional[VetoExecPolicyParam] | 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, @@ -182,8 +182,6 @@ def update( editor_version_restrictions: editor_version_restrictions restricts which editor versions can be used. Maps editor ID to version policy with allowed major versions. - executable_deny_list: executable_deny_list contains the veto exec policy for environments. - maximum_environment_lifetime: maximum_environment_lifetime controls for how long environments are allowed to be reused. 0 means no maximum lifetime. Maximum duration is 180 days (15552000 seconds). @@ -193,7 +191,12 @@ def update( maximum_environment_timeout: maximum_environment_timeout controls the maximum timeout allowed for environments in seconds. 0 means no limit (never). Minimum duration is 30 - minutes (1800 seconds). + minutes (1800 seconds). value must be 0s (no limit) or at least 1800s (30 + minutes): + + ``` + this == duration('0s') || this >= duration('1800s') + ``` maximum_running_environments_per_user: maximum_running_environments_per_user limits simultaneously running environments per user @@ -216,6 +219,8 @@ def update( security_agent_policy: security_agent_policy contains security agent configuration updates + veto_exec_policy: veto_exec_policy contains the veto exec policy for environments. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -236,7 +241,6 @@ def update( "default_environment_image": default_environment_image, "delete_archived_environments_after": delete_archived_environments_after, "editor_version_restrictions": editor_version_restrictions, - "executable_deny_list": executable_deny_list, "maximum_environment_lifetime": maximum_environment_lifetime, "maximum_environments_per_user": maximum_environments_per_user, "maximum_environment_timeout": maximum_environment_timeout, @@ -247,6 +251,7 @@ def update( "require_custom_domain_access": require_custom_domain_access, "restrict_account_creation_to_scim": restrict_account_creation_to_scim, "security_agent_policy": security_agent_policy, + "veto_exec_policy": veto_exec_policy, }, policy_update_params.PolicyUpdateParams, ), @@ -340,7 +345,6 @@ async def update( default_environment_image: Optional[str] | Omit = omit, delete_archived_environments_after: Optional[str] | Omit = omit, editor_version_restrictions: Dict[str, policy_update_params.EditorVersionRestrictions] | Omit = omit, - executable_deny_list: Optional[VetoExecPolicyParam] | Omit = omit, maximum_environment_lifetime: Optional[str] | Omit = omit, maximum_environments_per_user: Optional[str] | Omit = omit, maximum_environment_timeout: Optional[str] | Omit = omit, @@ -351,6 +355,7 @@ async def update( require_custom_domain_access: Optional[bool] | Omit = omit, restrict_account_creation_to_scim: Optional[bool] | Omit = omit, security_agent_policy: Optional[policy_update_params.SecurityAgentPolicy] | Omit = omit, + veto_exec_policy: Optional[VetoExecPolicyParam] | 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, @@ -417,8 +422,6 @@ async def update( editor_version_restrictions: editor_version_restrictions restricts which editor versions can be used. Maps editor ID to version policy with allowed major versions. - executable_deny_list: executable_deny_list contains the veto exec policy for environments. - maximum_environment_lifetime: maximum_environment_lifetime controls for how long environments are allowed to be reused. 0 means no maximum lifetime. Maximum duration is 180 days (15552000 seconds). @@ -428,7 +431,12 @@ async def update( maximum_environment_timeout: maximum_environment_timeout controls the maximum timeout allowed for environments in seconds. 0 means no limit (never). Minimum duration is 30 - minutes (1800 seconds). + minutes (1800 seconds). value must be 0s (no limit) or at least 1800s (30 + minutes): + + ``` + this == duration('0s') || this >= duration('1800s') + ``` maximum_running_environments_per_user: maximum_running_environments_per_user limits simultaneously running environments per user @@ -451,6 +459,8 @@ async def update( security_agent_policy: security_agent_policy contains security agent configuration updates + veto_exec_policy: veto_exec_policy contains the veto exec policy for environments. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -471,7 +481,6 @@ async def update( "default_environment_image": default_environment_image, "delete_archived_environments_after": delete_archived_environments_after, "editor_version_restrictions": editor_version_restrictions, - "executable_deny_list": executable_deny_list, "maximum_environment_lifetime": maximum_environment_lifetime, "maximum_environments_per_user": maximum_environments_per_user, "maximum_environment_timeout": maximum_environment_timeout, @@ -482,6 +491,7 @@ async def update( "require_custom_domain_access": require_custom_domain_access, "restrict_account_creation_to_scim": restrict_account_creation_to_scim, "security_agent_policy": security_agent_policy, + "veto_exec_policy": veto_exec_policy, }, policy_update_params.PolicyUpdateParams, ), diff --git a/src/gitpod/resources/prebuilds.py b/src/gitpod/resources/prebuilds.py index c688d1a3..6213db22 100644 --- a/src/gitpod/resources/prebuilds.py +++ b/src/gitpod/resources/prebuilds.py @@ -12,7 +12,12 @@ prebuild_create_params, prebuild_delete_params, prebuild_retrieve_params, + prebuild_list_warm_pools_params, + prebuild_create_warm_pool_params, + prebuild_delete_warm_pool_params, + prebuild_update_warm_pool_params, prebuild_create_logs_token_params, + prebuild_retrieve_warm_pool_params, ) from .._types import Body, Omit, Query, Headers, NotGiven, omit, not_given from .._utils import maybe_transform, async_maybe_transform @@ -24,19 +29,28 @@ async_to_raw_response_wrapper, async_to_streamed_response_wrapper, ) -from ..pagination import SyncPrebuildsPage, AsyncPrebuildsPage +from ..pagination import SyncPrebuildsPage, SyncWarmPoolsPage, AsyncPrebuildsPage, AsyncWarmPoolsPage from .._base_client import AsyncPaginator, make_request_options from ..types.prebuild import Prebuild +from ..types.warm_pool import WarmPool from ..types.prebuild_spec_param import PrebuildSpecParam from ..types.prebuild_cancel_response import PrebuildCancelResponse from ..types.prebuild_create_response import PrebuildCreateResponse from ..types.prebuild_retrieve_response import PrebuildRetrieveResponse +from ..types.prebuild_create_warm_pool_response import PrebuildCreateWarmPoolResponse +from ..types.prebuild_update_warm_pool_response import PrebuildUpdateWarmPoolResponse from ..types.prebuild_create_logs_token_response import PrebuildCreateLogsTokenResponse +from ..types.prebuild_retrieve_warm_pool_response import PrebuildRetrieveWarmPoolResponse __all__ = ["PrebuildsResource", "AsyncPrebuildsResource"] class PrebuildsResource(SyncAPIResource): + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ + @cached_property def with_raw_response(self) -> PrebuildsResourceWithRawResponse: """ @@ -398,8 +412,310 @@ def create_logs_token( cast_to=PrebuildCreateLogsTokenResponse, ) + def create_warm_pool( + self, + *, + environment_class_id: str, + project_id: str, + desired_size: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> PrebuildCreateWarmPoolResponse: + """ + Creates a warm pool for a project and environment class. + + A warm pool maintains pre-created environment instances from a prebuild snapshot + so that new environments can start near-instantly. + + Only one warm pool is allowed per pair. The + environment class must have prebuilds enabled on the project. + + The pool's snapshot is managed automatically: when a new prebuild completes for + the same project and environment class, the pool's snapshot is updated and the + runner rotates instances. + + ### Examples + + - Create warm pool: + + Creates a warm pool with 2 instances for a project and environment class. + + ```yaml + projectId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + environmentClassId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" + desiredSize: 2 + ``` + + Args: + environment_class_id: environment_class_id specifies which environment class to warm. Must be listed + in the project's prebuild configuration environment_class_ids. + + project_id: project_id specifies the project this warm pool belongs to. The project must + have prebuilds enabled. + + desired_size: desired_size is the number of warm instances to maintain. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.PrebuildService/CreateWarmPool", + body=maybe_transform( + { + "environment_class_id": environment_class_id, + "project_id": project_id, + "desired_size": desired_size, + }, + prebuild_create_warm_pool_params.PrebuildCreateWarmPoolParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=PrebuildCreateWarmPoolResponse, + ) + + def delete_warm_pool( + self, + *, + warm_pool_id: str, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """Deletes a warm pool. + + Deletion is processed asynchronously. + + The pool is marked for deletion and the + runner drains instances in the background. + + Warm pools are also automatically deleted when prebuilds are disabled on the + project or the environment class is removed from the prebuild configuration. + + ### Examples + + - Delete warm pool: + + ```yaml + warmPoolId: "a1b2c3d4-5678-9abc-def0-1234567890ab" + ``` + + Args: + warm_pool_id: warm_pool_id specifies the warm pool to delete + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.PrebuildService/DeleteWarmPool", + body=maybe_transform( + {"warm_pool_id": warm_pool_id}, prebuild_delete_warm_pool_params.PrebuildDeleteWarmPoolParams + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + def list_warm_pools( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: prebuild_list_warm_pools_params.Filter | Omit = omit, + pagination: prebuild_list_warm_pools_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> SyncWarmPoolsPage[WarmPool]: + """ + Lists warm pools with optional filtering. + + Use this method to: + + - View all warm pools for a project + - Monitor warm pool status across environment classes + + ### Examples + + - List warm pools for a project: + + ```yaml + filter: + projectIds: ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"] + ``` + + Args: + filter: filter contains the filter options for listing warm pools + + pagination: pagination contains the pagination options for listing warm pools + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.PrebuildService/ListWarmPools", + page=SyncWarmPoolsPage[WarmPool], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + prebuild_list_warm_pools_params.PrebuildListWarmPoolsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + prebuild_list_warm_pools_params.PrebuildListWarmPoolsParams, + ), + ), + model=WarmPool, + method="post", + ) + + def retrieve_warm_pool( + self, + *, + warm_pool_id: str, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> PrebuildRetrieveWarmPoolResponse: + """ + Gets details about a specific warm pool. + + Use this method to: + + - Check warm pool status and phase + - View the current snapshot being warmed + - Monitor pool health + + ### Examples + + - Get warm pool: + + ```yaml + warmPoolId: "a1b2c3d4-5678-9abc-def0-1234567890ab" + ``` + + Args: + warm_pool_id: warm_pool_id specifies the warm pool to retrieve + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.PrebuildService/GetWarmPool", + body=maybe_transform( + {"warm_pool_id": warm_pool_id}, prebuild_retrieve_warm_pool_params.PrebuildRetrieveWarmPoolParams + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=PrebuildRetrieveWarmPoolResponse, + ) + + def update_warm_pool( + self, + *, + warm_pool_id: str, + desired_size: Optional[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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> PrebuildUpdateWarmPoolResponse: + """ + Updates a warm pool's configuration. + + Use this method to change the desired pool size. + + ### Examples + + - Update pool size: + + ```yaml + warmPoolId: "a1b2c3d4-5678-9abc-def0-1234567890ab" + desiredSize: 5 + ``` + + Args: + warm_pool_id: warm_pool_id specifies the warm pool to update + + desired_size: desired_size updates the number of warm instances to maintain. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._post( + "/gitpod.v1.PrebuildService/UpdateWarmPool", + body=maybe_transform( + { + "warm_pool_id": warm_pool_id, + "desired_size": desired_size, + }, + prebuild_update_warm_pool_params.PrebuildUpdateWarmPoolParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=PrebuildUpdateWarmPoolResponse, + ) + class AsyncPrebuildsResource(AsyncAPIResource): + """ + PrebuildService manages prebuilds for projects to enable faster environment startup times. + Prebuilds create snapshots of environments that can be used to provision new environments quickly. + """ + @cached_property def with_raw_response(self) -> AsyncPrebuildsResourceWithRawResponse: """ @@ -763,6 +1079,303 @@ async def create_logs_token( cast_to=PrebuildCreateLogsTokenResponse, ) + async def create_warm_pool( + self, + *, + environment_class_id: str, + project_id: str, + desired_size: 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> PrebuildCreateWarmPoolResponse: + """ + Creates a warm pool for a project and environment class. + + A warm pool maintains pre-created environment instances from a prebuild snapshot + so that new environments can start near-instantly. + + Only one warm pool is allowed per pair. The + environment class must have prebuilds enabled on the project. + + The pool's snapshot is managed automatically: when a new prebuild completes for + the same project and environment class, the pool's snapshot is updated and the + runner rotates instances. + + ### Examples + + - Create warm pool: + + Creates a warm pool with 2 instances for a project and environment class. + + ```yaml + projectId: "b0e12f6c-4c67-429d-a4a6-d9838b5da047" + environmentClassId: "d2c94c27-3b76-4a42-b88c-95a85e392c68" + desiredSize: 2 + ``` + + Args: + environment_class_id: environment_class_id specifies which environment class to warm. Must be listed + in the project's prebuild configuration environment_class_ids. + + project_id: project_id specifies the project this warm pool belongs to. The project must + have prebuilds enabled. + + desired_size: desired_size is the number of warm instances to maintain. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.PrebuildService/CreateWarmPool", + body=await async_maybe_transform( + { + "environment_class_id": environment_class_id, + "project_id": project_id, + "desired_size": desired_size, + }, + prebuild_create_warm_pool_params.PrebuildCreateWarmPoolParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=PrebuildCreateWarmPoolResponse, + ) + + async def delete_warm_pool( + self, + *, + warm_pool_id: str, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> object: + """Deletes a warm pool. + + Deletion is processed asynchronously. + + The pool is marked for deletion and the + runner drains instances in the background. + + Warm pools are also automatically deleted when prebuilds are disabled on the + project or the environment class is removed from the prebuild configuration. + + ### Examples + + - Delete warm pool: + + ```yaml + warmPoolId: "a1b2c3d4-5678-9abc-def0-1234567890ab" + ``` + + Args: + warm_pool_id: warm_pool_id specifies the warm pool to delete + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.PrebuildService/DeleteWarmPool", + body=await async_maybe_transform( + {"warm_pool_id": warm_pool_id}, prebuild_delete_warm_pool_params.PrebuildDeleteWarmPoolParams + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=object, + ) + + def list_warm_pools( + self, + *, + token: str | Omit = omit, + page_size: int | Omit = omit, + filter: prebuild_list_warm_pools_params.Filter | Omit = omit, + pagination: prebuild_list_warm_pools_params.Pagination | 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> AsyncPaginator[WarmPool, AsyncWarmPoolsPage[WarmPool]]: + """ + Lists warm pools with optional filtering. + + Use this method to: + + - View all warm pools for a project + - Monitor warm pool status across environment classes + + ### Examples + + - List warm pools for a project: + + ```yaml + filter: + projectIds: ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"] + ``` + + Args: + filter: filter contains the filter options for listing warm pools + + pagination: pagination contains the pagination options for listing warm pools + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return self._get_api_list( + "/gitpod.v1.PrebuildService/ListWarmPools", + page=AsyncWarmPoolsPage[WarmPool], + body=maybe_transform( + { + "filter": filter, + "pagination": pagination, + }, + prebuild_list_warm_pools_params.PrebuildListWarmPoolsParams, + ), + options=make_request_options( + extra_headers=extra_headers, + extra_query=extra_query, + extra_body=extra_body, + timeout=timeout, + query=maybe_transform( + { + "token": token, + "page_size": page_size, + }, + prebuild_list_warm_pools_params.PrebuildListWarmPoolsParams, + ), + ), + model=WarmPool, + method="post", + ) + + async def retrieve_warm_pool( + self, + *, + warm_pool_id: str, + # 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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> PrebuildRetrieveWarmPoolResponse: + """ + Gets details about a specific warm pool. + + Use this method to: + + - Check warm pool status and phase + - View the current snapshot being warmed + - Monitor pool health + + ### Examples + + - Get warm pool: + + ```yaml + warmPoolId: "a1b2c3d4-5678-9abc-def0-1234567890ab" + ``` + + Args: + warm_pool_id: warm_pool_id specifies the warm pool to retrieve + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.PrebuildService/GetWarmPool", + body=await async_maybe_transform( + {"warm_pool_id": warm_pool_id}, prebuild_retrieve_warm_pool_params.PrebuildRetrieveWarmPoolParams + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=PrebuildRetrieveWarmPoolResponse, + ) + + async def update_warm_pool( + self, + *, + warm_pool_id: str, + desired_size: Optional[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, + extra_query: Query | None = None, + extra_body: Body | None = None, + timeout: float | httpx.Timeout | None | NotGiven = not_given, + ) -> PrebuildUpdateWarmPoolResponse: + """ + Updates a warm pool's configuration. + + Use this method to change the desired pool size. + + ### Examples + + - Update pool size: + + ```yaml + warmPoolId: "a1b2c3d4-5678-9abc-def0-1234567890ab" + desiredSize: 5 + ``` + + Args: + warm_pool_id: warm_pool_id specifies the warm pool to update + + desired_size: desired_size updates the number of warm instances to maintain. + + extra_headers: Send extra headers + + extra_query: Add additional query parameters to the request + + extra_body: Add additional JSON properties to the request + + timeout: Override the client-level default timeout for this request, in seconds + """ + return await self._post( + "/gitpod.v1.PrebuildService/UpdateWarmPool", + body=await async_maybe_transform( + { + "warm_pool_id": warm_pool_id, + "desired_size": desired_size, + }, + prebuild_update_warm_pool_params.PrebuildUpdateWarmPoolParams, + ), + options=make_request_options( + extra_headers=extra_headers, extra_query=extra_query, extra_body=extra_body, timeout=timeout + ), + cast_to=PrebuildUpdateWarmPoolResponse, + ) + class PrebuildsResourceWithRawResponse: def __init__(self, prebuilds: PrebuildsResource) -> None: @@ -786,6 +1399,21 @@ def __init__(self, prebuilds: PrebuildsResource) -> None: self.create_logs_token = to_raw_response_wrapper( prebuilds.create_logs_token, ) + self.create_warm_pool = to_raw_response_wrapper( + prebuilds.create_warm_pool, + ) + self.delete_warm_pool = to_raw_response_wrapper( + prebuilds.delete_warm_pool, + ) + self.list_warm_pools = to_raw_response_wrapper( + prebuilds.list_warm_pools, + ) + self.retrieve_warm_pool = to_raw_response_wrapper( + prebuilds.retrieve_warm_pool, + ) + self.update_warm_pool = to_raw_response_wrapper( + prebuilds.update_warm_pool, + ) class AsyncPrebuildsResourceWithRawResponse: @@ -810,6 +1438,21 @@ def __init__(self, prebuilds: AsyncPrebuildsResource) -> None: self.create_logs_token = async_to_raw_response_wrapper( prebuilds.create_logs_token, ) + self.create_warm_pool = async_to_raw_response_wrapper( + prebuilds.create_warm_pool, + ) + self.delete_warm_pool = async_to_raw_response_wrapper( + prebuilds.delete_warm_pool, + ) + self.list_warm_pools = async_to_raw_response_wrapper( + prebuilds.list_warm_pools, + ) + self.retrieve_warm_pool = async_to_raw_response_wrapper( + prebuilds.retrieve_warm_pool, + ) + self.update_warm_pool = async_to_raw_response_wrapper( + prebuilds.update_warm_pool, + ) class PrebuildsResourceWithStreamingResponse: @@ -834,6 +1477,21 @@ def __init__(self, prebuilds: PrebuildsResource) -> None: self.create_logs_token = to_streamed_response_wrapper( prebuilds.create_logs_token, ) + self.create_warm_pool = to_streamed_response_wrapper( + prebuilds.create_warm_pool, + ) + self.delete_warm_pool = to_streamed_response_wrapper( + prebuilds.delete_warm_pool, + ) + self.list_warm_pools = to_streamed_response_wrapper( + prebuilds.list_warm_pools, + ) + self.retrieve_warm_pool = to_streamed_response_wrapper( + prebuilds.retrieve_warm_pool, + ) + self.update_warm_pool = to_streamed_response_wrapper( + prebuilds.update_warm_pool, + ) class AsyncPrebuildsResourceWithStreamingResponse: @@ -858,3 +1516,18 @@ def __init__(self, prebuilds: AsyncPrebuildsResource) -> None: self.create_logs_token = async_to_streamed_response_wrapper( prebuilds.create_logs_token, ) + self.create_warm_pool = async_to_streamed_response_wrapper( + prebuilds.create_warm_pool, + ) + self.delete_warm_pool = async_to_streamed_response_wrapper( + prebuilds.delete_warm_pool, + ) + self.list_warm_pools = async_to_streamed_response_wrapper( + prebuilds.list_warm_pools, + ) + self.retrieve_warm_pool = async_to_streamed_response_wrapper( + prebuilds.retrieve_warm_pool, + ) + self.update_warm_pool = async_to_streamed_response_wrapper( + prebuilds.update_warm_pool, + ) diff --git a/src/gitpod/resources/projects/projects.py b/src/gitpod/resources/projects/projects.py index ac2caee1..7661206e 100644 --- a/src/gitpod/resources/projects/projects.py +++ b/src/gitpod/resources/projects/projects.py @@ -46,6 +46,7 @@ EnvironmentClasesResourceWithStreamingResponse, AsyncEnvironmentClasesResourceWithStreamingResponse, ) +from ...types.shared_params.sort import Sort from ...types.project_create_response import ProjectCreateResponse from ...types.project_update_response import ProjectUpdateResponse from ...types.project_retrieve_response import ProjectRetrieveResponse @@ -364,6 +365,7 @@ def list( page_size: int | Omit = omit, filter: project_list_params.Filter | Omit = omit, pagination: project_list_params.Pagination | Omit = omit, + sort: Sort | 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, @@ -394,6 +396,15 @@ def list( Args: pagination: pagination contains the pagination options for listing organizations + sort: sort specifies the order of results. Defaults to popularity descending. + + Supported fields: + + - "id": Sort by project ID (UUID v7, effectively creation order). Produces a + stable, deterministic result set suitable for consistent pagination. + - "popularity": Sort by popularity — a precomputed score based on recent + environment creation activity. Updated periodically by a background job. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -409,6 +420,7 @@ def list( { "filter": filter, "pagination": pagination, + "sort": sort, }, project_list_params.ProjectListParams, ), @@ -1008,6 +1020,7 @@ def list( page_size: int | Omit = omit, filter: project_list_params.Filter | Omit = omit, pagination: project_list_params.Pagination | Omit = omit, + sort: Sort | 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, @@ -1038,6 +1051,15 @@ def list( Args: pagination: pagination contains the pagination options for listing organizations + sort: sort specifies the order of results. Defaults to popularity descending. + + Supported fields: + + - "id": Sort by project ID (UUID v7, effectively creation order). Produces a + stable, deterministic result set suitable for consistent pagination. + - "popularity": Sort by popularity — a precomputed score based on recent + environment creation activity. Updated periodically by a background job. + extra_headers: Send extra headers extra_query: Add additional query parameters to the request @@ -1053,6 +1075,7 @@ def list( { "filter": filter, "pagination": pagination, + "sort": sort, }, project_list_params.ProjectListParams, ), diff --git a/src/gitpod/resources/usage.py b/src/gitpod/resources/usage.py index 2b98af15..6285e304 100644 --- a/src/gitpod/resources/usage.py +++ b/src/gitpod/resources/usage.py @@ -23,6 +23,10 @@ class UsageResource(SyncAPIResource): + """ + UsageService provides usage information about environments, users, and projects. + """ + @cached_property def with_raw_response(self) -> UsageResourceWithRawResponse: """ @@ -123,6 +127,10 @@ def list_environment_runtime_records( class AsyncUsageResource(AsyncAPIResource): + """ + UsageService provides usage information about environments, users, and projects. + """ + @cached_property def with_raw_response(self) -> AsyncUsageResourceWithRawResponse: """ diff --git a/src/gitpod/types/__init__.py b/src/gitpod/types/__init__.py index 05178ab1..aedad4c6 100644 --- a/src/gitpod/types/__init__.py +++ b/src/gitpod/types/__init__.py @@ -2,6 +2,8 @@ from __future__ import annotations +from .role import Role as Role +from .type import Type as Type from .user import User as User from .veto import Veto as Veto from .group import Group as Group @@ -10,6 +12,7 @@ from .runner import Runner as Runner from .secret import Secret as Secret from .shared import ( + Sort as Sort, Task as Task, State as State, RunsOn as RunsOn, @@ -19,6 +22,7 @@ ErrorCode as ErrorCode, Principal as Principal, SecretRef as SecretRef, + SortOrder as SortOrder, FieldValue as FieldValue, UserStatus as UserStatus, ResourceRole as ResourceRole, @@ -32,6 +36,7 @@ TaskExecutionSpec as TaskExecutionSpec, TaskExecutionPhase as TaskExecutionPhase, TaskExecutionStatus as TaskExecutionStatus, + CountResponseRelation as CountResponseRelation, TaskExecutionMetadata as TaskExecutionMetadata, EnvironmentVariableItem as EnvironmentVariableItem, ProjectEnvironmentClass as ProjectEnvironmentClass, @@ -40,7 +45,9 @@ from .account import Account as Account from .project import Project as Project from .prebuild import Prebuild as Prebuild +from .workflow import Workflow as Workflow from .log_level import LogLevel as LogLevel +from .warm_pool import WarmPool as WarmPool from .agent_mode import AgentMode as AgentMode from .veto_param import VetoParam as VetoParam from .environment import Environment as Environment @@ -56,22 +63,30 @@ from .prebuild_spec import PrebuildSpec as PrebuildSpec from .project_phase import ProjectPhase as ProjectPhase from .runner_status import RunnerStatus as RunnerStatus +from .workflow_step import WorkflowStep as WorkflowStep from .editor_version import EditorVersion as EditorVersion from .invite_domains import InviteDomains as InviteDomains from .login_provider import LoginProvider as LoginProvider from .prebuild_phase import PrebuildPhase as PrebuildPhase from .runner_variant import RunnerVariant as RunnerVariant +from .warm_pool_spec import WarmPoolSpec as WarmPoolSpec from .admission_level import AdmissionLevel as AdmissionLevel from .agent_execution import AgentExecution as AgentExecution +from .bpf_debug_level import BpfDebugLevel as BpfDebugLevel from .prebuild_status import PrebuildStatus as PrebuildStatus from .prompt_metadata import PromptMetadata as PromptMetadata from .runner_provider import RunnerProvider as RunnerProvider +from .warm_pool_phase import WarmPoolPhase as WarmPoolPhase +from .workflow_action import WorkflowAction as WorkflowAction from .breadcrumb_param import BreadcrumbParam as BreadcrumbParam from .environment_role import EnvironmentRole as EnvironmentRole from .environment_spec import EnvironmentSpec as EnvironmentSpec from .id_token_version import IDTokenVersion as IDTokenVersion from .prebuild_trigger import PrebuildTrigger as PrebuildTrigger from .project_metadata import ProjectMetadata as ProjectMetadata +from .wake_event_param import WakeEventParam as WakeEventParam +from .warm_pool_status import WarmPoolStatus as WarmPoolStatus +from .workflow_trigger import WorkflowTrigger as WorkflowTrigger from .environment_phase import EnvironmentPhase as EnvironmentPhase from .error_event_param import ErrorEventParam as ErrorEventParam from .event_list_params import EventListParams as EventListParams @@ -90,6 +105,9 @@ from .runner_list_params import RunnerListParams as RunnerListParams from .secret_list_params import SecretListParams as SecretListParams from .secret_scope_param import SecretScopeParam as SecretScopeParam +from .warm_pool_metadata import WarmPoolMetadata as WarmPoolMetadata +from .workflow_execution import WorkflowExecution as WorkflowExecution +from .agent_message_param import AgentMessageParam as AgentMessageParam from .event_list_response import EventListResponse as EventListResponse from .gateway_list_params import GatewayListParams as GatewayListParams from .group_create_params import GroupCreateParams as GroupCreateParams @@ -99,6 +117,7 @@ from .prebuild_spec_param import PrebuildSpecParam as PrebuildSpecParam from .project_list_params import ProjectListParams as ProjectListParams from .recommended_editors import RecommendedEditors as RecommendedEditors +from .workflow_step_param import WorkflowStepParam as WorkflowStepParam from .environment_metadata import EnvironmentMetadata as EnvironmentMetadata from .event_watch_response import EventWatchResponse as EventWatchResponse from .exception_info_param import ExceptionInfoParam as ExceptionInfoParam @@ -120,6 +139,8 @@ from .project_create_params import ProjectCreateParams as ProjectCreateParams from .project_delete_params import ProjectDeleteParams as ProjectDeleteParams from .project_update_params import ProjectUpdateParams as ProjectUpdateParams +from .workflow_action_param import WorkflowActionParam as WorkflowActionParam +from .automation_list_params import AutomationListParams as AutomationListParams from .editor_retrieve_params import EditorRetrieveParams as EditorRetrieveParams from .environment_spec_param import EnvironmentSpecParam as EnvironmentSpecParam from .kernel_controls_config import KernelControlsConfig as KernelControlsConfig @@ -132,6 +153,7 @@ from .secret_create_response import SecretCreateResponse as SecretCreateResponse from .user_get_user_response import UserGetUserResponse as UserGetUserResponse from .user_input_block_param import UserInputBlockParam as UserInputBlockParam +from .workflow_trigger_param import WorkflowTriggerParam as WorkflowTriggerParam from .account_retrieve_params import AccountRetrieveParams as AccountRetrieveParams from .environment_initializer import EnvironmentInitializer as EnvironmentInitializer from .environment_list_params import EnvironmentListParams as EnvironmentListParams @@ -143,6 +165,9 @@ from .secret_get_value_params import SecretGetValueParams as SecretGetValueParams from .user_delete_user_params import UserDeleteUserParams as UserDeleteUserParams from .agent_code_context_param import AgentCodeContextParam as AgentCodeContextParam +from .automation_create_params import AutomationCreateParams as AutomationCreateParams +from .automation_delete_params import AutomationDeleteParams as AutomationDeleteParams +from .automation_update_params import AutomationUpdateParams as AutomationUpdateParams from .editor_retrieve_response import EditorRetrieveResponse as EditorRetrieveResponse from .environment_start_params import EnvironmentStartParams as EnvironmentStartParams from .environment_usage_record import EnvironmentUsageRecord as EnvironmentUsageRecord @@ -151,6 +176,7 @@ from .prebuild_create_response import PrebuildCreateResponse as PrebuildCreateResponse from .prebuild_retrieve_params import PrebuildRetrieveParams as PrebuildRetrieveParams from .runner_retrieve_response import RunnerRetrieveResponse as RunnerRetrieveResponse +from .workflow_trigger_context import WorkflowTriggerContext as WorkflowTriggerContext from .account_retrieve_response import AccountRetrieveResponse as AccountRetrieveResponse from .agent_list_prompts_params import AgentListPromptsParams as AgentListPromptsParams from .editor_resolve_url_params import EditorResolveURLParams as EditorResolveURLParams @@ -163,9 +189,13 @@ from .recommended_editors_param import RecommendedEditorsParam as RecommendedEditorsParam from .secret_get_value_response import SecretGetValueResponse as SecretGetValueResponse from .user_set_suspended_params import UserSetSuspendedParams as UserSetSuspendedParams +from .workflow_execution_action import WorkflowExecutionAction as WorkflowExecutionAction from .agent_create_prompt_params import AgentCreatePromptParams as AgentCreatePromptParams from .agent_delete_prompt_params import AgentDeletePromptParams as AgentDeletePromptParams from .agent_update_prompt_params import AgentUpdatePromptParams as AgentUpdatePromptParams +from .automation_create_response import AutomationCreateResponse as AutomationCreateResponse +from .automation_retrieve_params import AutomationRetrieveParams as AutomationRetrieveParams +from .automation_update_response import AutomationUpdateResponse as AutomationUpdateResponse from .error_report_errors_params import ErrorReportErrorsParams as ErrorReportErrorsParams from .organization_create_params import OrganizationCreateParams as OrganizationCreateParams from .organization_delete_params import OrganizationDeleteParams as OrganizationDeleteParams @@ -188,6 +218,7 @@ from .agent_retrieve_prompt_params import AgentRetrievePromptParams as AgentRetrievePromptParams from .agent_start_execution_params import AgentStartExecutionParams as AgentStartExecutionParams from .agent_update_prompt_response import AgentUpdatePromptResponse as AgentUpdatePromptResponse +from .automation_retrieve_response import AutomationRetrieveResponse as AutomationRetrieveResponse from .environment_unarchive_params import EnvironmentUnarchiveParams as EnvironmentUnarchiveParams from .identity_get_id_token_params import IdentityGetIDTokenParams as IdentityGetIDTokenParams from .kernel_controls_config_param import KernelControlsConfigParam as KernelControlsConfigParam @@ -210,14 +241,21 @@ from .identity_get_id_token_response import IdentityGetIDTokenResponse as IdentityGetIDTokenResponse from .organization_retrieve_response import OrganizationRetrieveResponse as OrganizationRetrieveResponse from .project_prebuild_configuration import ProjectPrebuildConfiguration as ProjectPrebuildConfiguration +from .workflow_trigger_context_param import WorkflowTriggerContextParam as WorkflowTriggerContextParam from .agent_retrieve_execution_params import AgentRetrieveExecutionParams as AgentRetrieveExecutionParams +from .prebuild_list_warm_pools_params import PrebuildListWarmPoolsParams as PrebuildListWarmPoolsParams from .runner_create_logs_token_params import RunnerCreateLogsTokenParams as RunnerCreateLogsTokenParams from .runner_parse_context_url_params import RunnerParseContextURLParams as RunnerParseContextURLParams from .account_get_sso_login_url_params import AccountGetSSOLoginURLParams as AccountGetSSOLoginURLParams from .account_list_sso_logins_response import AccountListSSOLoginsResponse as AccountListSSOLoginsResponse from .identity_exchange_token_response import IdentityExchangeTokenResponse as IdentityExchangeTokenResponse from .organization_list_members_params import OrganizationListMembersParams as OrganizationListMembersParams +from .prebuild_create_warm_pool_params import PrebuildCreateWarmPoolParams as PrebuildCreateWarmPoolParams +from .prebuild_delete_warm_pool_params import PrebuildDeleteWarmPoolParams as PrebuildDeleteWarmPoolParams +from .prebuild_update_warm_pool_params import PrebuildUpdateWarmPoolParams as PrebuildUpdateWarmPoolParams from .agent_retrieve_execution_response import AgentRetrieveExecutionResponse as AgentRetrieveExecutionResponse +from .automation_list_executions_params import AutomationListExecutionsParams as AutomationListExecutionsParams +from .automation_start_execution_params import AutomationStartExecutionParams as AutomationStartExecutionParams from .environment_activity_signal_param import EnvironmentActivitySignalParam as EnvironmentActivitySignalParam from .prebuild_create_logs_token_params import PrebuildCreateLogsTokenParams as PrebuildCreateLogsTokenParams from .runner_create_logs_token_response import RunnerCreateLogsTokenResponse as RunnerCreateLogsTokenResponse @@ -225,18 +263,28 @@ from .runner_parse_context_url_response import RunnerParseContextURLResponse as RunnerParseContextURLResponse from .runner_search_repositories_params import RunnerSearchRepositoriesParams as RunnerSearchRepositoriesParams from .account_get_sso_login_url_response import AccountGetSSOLoginURLResponse as AccountGetSSOLoginURLResponse +from .automation_cancel_execution_params import AutomationCancelExecutionParams as AutomationCancelExecutionParams +from .prebuild_create_warm_pool_response import PrebuildCreateWarmPoolResponse as PrebuildCreateWarmPoolResponse +from .prebuild_retrieve_warm_pool_params import PrebuildRetrieveWarmPoolParams as PrebuildRetrieveWarmPoolParams +from .prebuild_update_warm_pool_response import PrebuildUpdateWarmPoolResponse as PrebuildUpdateWarmPoolResponse from .user_get_authenticated_user_params import UserGetAuthenticatedUserParams as UserGetAuthenticatedUserParams from .account_list_login_providers_params import AccountListLoginProvidersParams as AccountListLoginProvidersParams +from .automation_start_execution_response import AutomationStartExecutionResponse as AutomationStartExecutionResponse from .prebuild_create_logs_token_response import PrebuildCreateLogsTokenResponse as PrebuildCreateLogsTokenResponse from .runner_create_runner_token_response import RunnerCreateRunnerTokenResponse as RunnerCreateRunnerTokenResponse from .runner_search_repositories_response import RunnerSearchRepositoriesResponse as RunnerSearchRepositoriesResponse +from .automation_retrieve_execution_params import AutomationRetrieveExecutionParams as AutomationRetrieveExecutionParams from .environment_create_logs_token_params import EnvironmentCreateLogsTokenParams as EnvironmentCreateLogsTokenParams +from .prebuild_retrieve_warm_pool_response import PrebuildRetrieveWarmPoolResponse as PrebuildRetrieveWarmPoolResponse from .project_prebuild_configuration_param import ProjectPrebuildConfigurationParam as ProjectPrebuildConfigurationParam from .runner_list_scm_organizations_params import RunnerListScmOrganizationsParams as RunnerListScmOrganizationsParams from .user_get_authenticated_user_response import UserGetAuthenticatedUserResponse as UserGetAuthenticatedUserResponse from .runner_check_repository_access_params import ( RunnerCheckRepositoryAccessParams as RunnerCheckRepositoryAccessParams, ) +from .automation_retrieve_execution_response import ( + AutomationRetrieveExecutionResponse as AutomationRetrieveExecutionResponse, +) from .environment_create_from_project_params import ( EnvironmentCreateFromProjectParams as EnvironmentCreateFromProjectParams, ) @@ -252,18 +300,33 @@ from .runner_check_repository_access_response import ( RunnerCheckRepositoryAccessResponse as RunnerCheckRepositoryAccessResponse, ) +from .automation_list_execution_actions_params import ( + AutomationListExecutionActionsParams as AutomationListExecutionActionsParams, +) +from .automation_list_execution_outputs_params import ( + AutomationListExecutionOutputsParams as AutomationListExecutionOutputsParams, +) from .environment_create_from_project_response import ( EnvironmentCreateFromProjectResponse as EnvironmentCreateFromProjectResponse, ) from .project_create_from_environment_response import ( ProjectCreateFromEnvironmentResponse as ProjectCreateFromEnvironmentResponse, ) +from .automation_cancel_execution_action_params import ( + AutomationCancelExecutionActionParams as AutomationCancelExecutionActionParams, +) from .account_list_joinable_organizations_params import ( AccountListJoinableOrganizationsParams as AccountListJoinableOrganizationsParams, ) +from .automation_list_execution_outputs_response import ( + AutomationListExecutionOutputsResponse as AutomationListExecutionOutputsResponse, +) from .identity_get_authenticated_identity_params import ( IdentityGetAuthenticatedIdentityParams as IdentityGetAuthenticatedIdentityParams, ) +from .automation_retrieve_execution_action_params import ( + AutomationRetrieveExecutionActionParams as AutomationRetrieveExecutionActionParams, +) from .environment_create_environment_token_params import ( EnvironmentCreateEnvironmentTokenParams as EnvironmentCreateEnvironmentTokenParams, ) @@ -273,6 +336,9 @@ from .identity_get_authenticated_identity_response import ( IdentityGetAuthenticatedIdentityResponse as IdentityGetAuthenticatedIdentityResponse, ) +from .automation_retrieve_execution_action_response import ( + AutomationRetrieveExecutionActionResponse as AutomationRetrieveExecutionActionResponse, +) from .environment_create_environment_token_response import ( EnvironmentCreateEnvironmentTokenResponse as EnvironmentCreateEnvironmentTokenResponse, ) diff --git a/src/gitpod/types/agent_execution.py b/src/gitpod/types/agent_execution.py index ee64847f..f3e92d83 100644 --- a/src/gitpod/types/agent_execution.py +++ b/src/gitpod/types/agent_execution.py @@ -436,12 +436,15 @@ class Status(BaseModel): "SUPPORTED_MODEL_SONNET_4_EXTENDED", "SUPPORTED_MODEL_SONNET_4_5", "SUPPORTED_MODEL_SONNET_4_5_EXTENDED", + "SUPPORTED_MODEL_SONNET_4_6", + "SUPPORTED_MODEL_SONNET_4_6_EXTENDED", "SUPPORTED_MODEL_OPUS_4", "SUPPORTED_MODEL_OPUS_4_EXTENDED", "SUPPORTED_MODEL_OPUS_4_5", "SUPPORTED_MODEL_OPUS_4_5_EXTENDED", "SUPPORTED_MODEL_OPUS_4_6", "SUPPORTED_MODEL_OPUS_4_6_EXTENDED", + "SUPPORTED_MODEL_HAIKU_4_5", "SUPPORTED_MODEL_OPENAI_4O", "SUPPORTED_MODEL_OPENAI_4O_MINI", "SUPPORTED_MODEL_OPENAI_O1", diff --git a/src/gitpod/types/agent_list_prompts_params.py b/src/gitpod/types/agent_list_prompts_params.py index 6c3ac239..eb1f295c 100644 --- a/src/gitpod/types/agent_list_prompts_params.py +++ b/src/gitpod/types/agent_list_prompts_params.py @@ -24,6 +24,13 @@ class Filter(TypedDict, total=False): command_prefix: Annotated[str, PropertyInfo(alias="commandPrefix")] + exclude_prompt_content: Annotated[bool, PropertyInfo(alias="excludePromptContent")] + """ + exclude_prompt_content omits the large spec.prompt text from the response. Other + spec fields (is_template, is_command, command, is_skill) are still returned. Use + GetPrompt to retrieve the full prompt content when needed. + """ + is_command: Annotated[bool, PropertyInfo(alias="isCommand")] is_skill: Annotated[bool, PropertyInfo(alias="isSkill")] diff --git a/src/gitpod/types/agent_message_param.py b/src/gitpod/types/agent_message_param.py new file mode 100644 index 00000000..634fd16d --- /dev/null +++ b/src/gitpod/types/agent_message_param.py @@ -0,0 +1,22 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import TypedDict + +from .type import Type + +__all__ = ["AgentMessageParam"] + + +class AgentMessageParam(TypedDict, total=False): + """AgentMessage is a message sent between agents (e.g. + + from a parent agent to a + child agent execution, or vice versa). + """ + + payload: str + """Free-form payload of the message.""" + + type: Type diff --git a/src/gitpod/types/agent_send_to_execution_params.py b/src/gitpod/types/agent_send_to_execution_params.py index 27c14294..2ad05f82 100644 --- a/src/gitpod/types/agent_send_to_execution_params.py +++ b/src/gitpod/types/agent_send_to_execution_params.py @@ -5,6 +5,8 @@ from typing_extensions import Annotated, TypedDict from .._utils import PropertyInfo +from .wake_event_param import WakeEventParam +from .agent_message_param import AgentMessageParam from .user_input_block_param import UserInputBlockParam __all__ = ["AgentSendToExecutionParams"] @@ -13,4 +15,16 @@ class AgentSendToExecutionParams(TypedDict, total=False): agent_execution_id: Annotated[str, PropertyInfo(alias="agentExecutionId")] + agent_message: Annotated[AgentMessageParam, PropertyInfo(alias="agentMessage")] + """AgentMessage is a message sent between agents (e.g. + + from a parent agent to a child agent execution, or vice versa). + """ + user_input: Annotated[UserInputBlockParam, PropertyInfo(alias="userInput")] + + wake_event: Annotated[WakeEventParam, PropertyInfo(alias="wakeEvent")] + """ + WakeEvent is sent by the backend to wake an agent when a registered interest + fires. Delivered via SendToAgentExecution as a new oneof variant. + """ diff --git a/src/gitpod/types/agent_start_execution_params.py b/src/gitpod/types/agent_start_execution_params.py index 4d9f640a..699ab8f6 100644 --- a/src/gitpod/types/agent_start_execution_params.py +++ b/src/gitpod/types/agent_start_execution_params.py @@ -39,6 +39,12 @@ class AgentStartExecutionParams(TypedDict, total=False): environment. """ + session_id: Annotated[str, PropertyInfo(alias="sessionId")] + """ + session_id is the ID of the session this agent execution belongs to. If empty, a + new session is created implicitly. + """ + workflow_action_id: Annotated[Optional[str], PropertyInfo(alias="workflowActionId")] """ workflow_action_id is an optional reference to the workflow execution action diff --git a/src/gitpod/types/automation_cancel_execution_action_params.py b/src/gitpod/types/automation_cancel_execution_action_params.py new file mode 100644 index 00000000..0a072c29 --- /dev/null +++ b/src/gitpod/types/automation_cancel_execution_action_params.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["AutomationCancelExecutionActionParams"] + + +class AutomationCancelExecutionActionParams(TypedDict, total=False): + workflow_execution_action_id: Annotated[str, PropertyInfo(alias="workflowExecutionActionId")] diff --git a/src/gitpod/types/automation_cancel_execution_params.py b/src/gitpod/types/automation_cancel_execution_params.py new file mode 100644 index 00000000..7f2517cf --- /dev/null +++ b/src/gitpod/types/automation_cancel_execution_params.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["AutomationCancelExecutionParams"] + + +class AutomationCancelExecutionParams(TypedDict, total=False): + workflow_execution_id: Annotated[str, PropertyInfo(alias="workflowExecutionId")] diff --git a/src/gitpod/types/automation_create_params.py b/src/gitpod/types/automation_create_params.py new file mode 100644 index 00000000..cb8ade23 --- /dev/null +++ b/src/gitpod/types/automation_create_params.py @@ -0,0 +1,51 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Iterable, Optional +from typing_extensions import Required, TypedDict + +from .shared_params.subject import Subject +from .workflow_action_param import WorkflowActionParam +from .workflow_trigger_param import WorkflowTriggerParam + +__all__ = ["AutomationCreateParams"] + + +class AutomationCreateParams(TypedDict, total=False): + action: Required[WorkflowActionParam] + """WorkflowAction defines the actions to be executed in a workflow.""" + + description: str + """Description must be at most 500 characters: + + ``` + size(this) <= 500 + ``` + """ + + executor: Optional[Subject] + """Optional executor for the workflow. + + If not provided, defaults to the creator. Must be either the caller themselves + or a service account. + """ + + name: str + """Name must be between 1 and 80 characters: + + ``` + size(this) >= 1 && size(this) <= 80 + ``` + """ + + report: WorkflowActionParam + """WorkflowAction defines the actions to be executed in a workflow.""" + + triggers: Iterable[WorkflowTriggerParam] + """Automation must have between 1 and 10 triggers: + + ``` + size(this) >= 1 && size(this) <= 10 + ``` + """ diff --git a/src/gitpod/types/automation_create_response.py b/src/gitpod/types/automation_create_response.py new file mode 100644 index 00000000..a9c9c67f --- /dev/null +++ b/src/gitpod/types/automation_create_response.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from .._models import BaseModel +from .workflow import Workflow + +__all__ = ["AutomationCreateResponse"] + + +class AutomationCreateResponse(BaseModel): + workflow: Optional[Workflow] = None + """Workflow represents a workflow configuration.""" diff --git a/src/gitpod/types/automation_delete_params.py b/src/gitpod/types/automation_delete_params.py new file mode 100644 index 00000000..77bcd804 --- /dev/null +++ b/src/gitpod/types/automation_delete_params.py @@ -0,0 +1,26 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["AutomationDeleteParams"] + + +class AutomationDeleteParams(TypedDict, total=False): + force: bool + """ + force indicates whether to immediately delete the workflow and all related + resources. When true, performs cascading deletion of: + + - All workflow executions + - All workflow execution actions + - All environments created by workflow actions + - All agent executions created by workflow actions + - The workflow itself When false (default), marks workflow executions for + deletion and relies on background reconciliation to clean up resources. + """ + + workflow_id: Annotated[str, PropertyInfo(alias="workflowId")] diff --git a/src/gitpod/types/automation_list_execution_actions_params.py b/src/gitpod/types/automation_list_execution_actions_params.py new file mode 100644 index 00000000..d0d34298 --- /dev/null +++ b/src/gitpod/types/automation_list_execution_actions_params.py @@ -0,0 +1,56 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import List +from typing_extensions import Literal, Annotated, TypedDict + +from .._types import SequenceNotStr +from .._utils import PropertyInfo + +__all__ = ["AutomationListExecutionActionsParams", "Filter", "Pagination"] + + +class AutomationListExecutionActionsParams(TypedDict, total=False): + token: str + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + + filter: Filter + + pagination: Pagination + + +class Filter(TypedDict, total=False): + phases: List[ + Literal[ + "WORKFLOW_EXECUTION_ACTION_PHASE_UNSPECIFIED", + "WORKFLOW_EXECUTION_ACTION_PHASE_PENDING", + "WORKFLOW_EXECUTION_ACTION_PHASE_RUNNING", + "WORKFLOW_EXECUTION_ACTION_PHASE_STOPPING", + "WORKFLOW_EXECUTION_ACTION_PHASE_STOPPED", + "WORKFLOW_EXECUTION_ACTION_PHASE_DELETING", + "WORKFLOW_EXECUTION_ACTION_PHASE_DELETED", + "WORKFLOW_EXECUTION_ACTION_PHASE_DONE", + ] + ] + + workflow_execution_action_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="workflowExecutionActionIds")] + + workflow_execution_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="workflowExecutionIds")] + + workflow_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="workflowIds")] + + +class Pagination(TypedDict, total=False): + token: str + """ + Token for the next set of results that was returned as next_token of a + PaginationResponse + """ + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + """Page size is the maximum number of results to retrieve per page. Defaults to 25. + + Maximum 100. + """ diff --git a/src/gitpod/types/automation_list_execution_outputs_params.py b/src/gitpod/types/automation_list_execution_outputs_params.py new file mode 100644 index 00000000..da53d870 --- /dev/null +++ b/src/gitpod/types/automation_list_execution_outputs_params.py @@ -0,0 +1,38 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._types import SequenceNotStr +from .._utils import PropertyInfo + +__all__ = ["AutomationListExecutionOutputsParams", "Filter", "Pagination"] + + +class AutomationListExecutionOutputsParams(TypedDict, total=False): + token: str + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + + filter: Filter + + pagination: Pagination + + +class Filter(TypedDict, total=False): + workflow_execution_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="workflowExecutionIds")] + + +class Pagination(TypedDict, total=False): + token: str + """ + Token for the next set of results that was returned as next_token of a + PaginationResponse + """ + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + """Page size is the maximum number of results to retrieve per page. Defaults to 25. + + Maximum 100. + """ diff --git a/src/gitpod/types/automation_list_execution_outputs_response.py b/src/gitpod/types/automation_list_execution_outputs_response.py new file mode 100644 index 00000000..3a3bc69e --- /dev/null +++ b/src/gitpod/types/automation_list_execution_outputs_response.py @@ -0,0 +1,25 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Dict, Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel + +__all__ = ["AutomationListExecutionOutputsResponse", "Values"] + + +class Values(BaseModel): + bool_value: Optional[bool] = FieldInfo(alias="boolValue", default=None) + + float_value: Optional[float] = FieldInfo(alias="floatValue", default=None) + + int_value: Optional[str] = FieldInfo(alias="intValue", default=None) + + string_value: Optional[str] = FieldInfo(alias="stringValue", default=None) + + +class AutomationListExecutionOutputsResponse(BaseModel): + action_id: Optional[str] = FieldInfo(alias="actionId", default=None) + + values: Optional[Dict[str, Values]] = None diff --git a/src/gitpod/types/automation_list_executions_params.py b/src/gitpod/types/automation_list_executions_params.py new file mode 100644 index 00000000..dab6e801 --- /dev/null +++ b/src/gitpod/types/automation_list_executions_params.py @@ -0,0 +1,74 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import List, Optional +from typing_extensions import Literal, Annotated, TypedDict + +from .._types import SequenceNotStr +from .._utils import PropertyInfo +from .shared_params.sort import Sort + +__all__ = ["AutomationListExecutionsParams", "Filter", "Pagination"] + + +class AutomationListExecutionsParams(TypedDict, total=False): + token: str + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + + filter: Filter + + pagination: Pagination + + sort: Sort + """sort specifies the order of results. + + When unspecified, results are sorted by operational priority (running first, + then failed, then completed, then others). Supported sort fields: startedAt, + finishedAt, createdAt. + """ + + +class Filter(TypedDict, total=False): + has_failed_actions: Annotated[Optional[bool], PropertyInfo(alias="hasFailedActions")] + + search: str + """ + search performs case-insensitive search across workflow execution ID and trigger + type + """ + + status_phases: Annotated[ + List[ + Literal[ + "WORKFLOW_EXECUTION_PHASE_UNSPECIFIED", + "WORKFLOW_EXECUTION_PHASE_PENDING", + "WORKFLOW_EXECUTION_PHASE_RUNNING", + "WORKFLOW_EXECUTION_PHASE_STOPPING", + "WORKFLOW_EXECUTION_PHASE_STOPPED", + "WORKFLOW_EXECUTION_PHASE_DELETING", + "WORKFLOW_EXECUTION_PHASE_DELETED", + "WORKFLOW_EXECUTION_PHASE_COMPLETED", + ] + ], + PropertyInfo(alias="statusPhases"), + ] + + workflow_execution_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="workflowExecutionIds")] + + workflow_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="workflowIds")] + + +class Pagination(TypedDict, total=False): + token: str + """ + Token for the next set of results that was returned as next_token of a + PaginationResponse + """ + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + """Page size is the maximum number of results to retrieve per page. Defaults to 25. + + Maximum 100. + """ diff --git a/src/gitpod/types/automation_list_params.py b/src/gitpod/types/automation_list_params.py new file mode 100644 index 00000000..40b3a3d4 --- /dev/null +++ b/src/gitpod/types/automation_list_params.py @@ -0,0 +1,69 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import List +from typing_extensions import Literal, Annotated, TypedDict + +from .._types import SequenceNotStr +from .._utils import PropertyInfo + +__all__ = ["AutomationListParams", "Filter", "Pagination"] + + +class AutomationListParams(TypedDict, total=False): + token: str + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + + filter: Filter + + pagination: Pagination + + +class Filter(TypedDict, total=False): + creator_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="creatorIds")] + """creator_ids filters workflows by creator user IDs""" + + search: str + """ + search performs case-insensitive search across workflow name, description, and + ID + """ + + status_phases: Annotated[ + List[ + Literal[ + "WORKFLOW_EXECUTION_PHASE_UNSPECIFIED", + "WORKFLOW_EXECUTION_PHASE_PENDING", + "WORKFLOW_EXECUTION_PHASE_RUNNING", + "WORKFLOW_EXECUTION_PHASE_STOPPING", + "WORKFLOW_EXECUTION_PHASE_STOPPED", + "WORKFLOW_EXECUTION_PHASE_DELETING", + "WORKFLOW_EXECUTION_PHASE_DELETED", + "WORKFLOW_EXECUTION_PHASE_COMPLETED", + ] + ], + PropertyInfo(alias="statusPhases"), + ] + """ + status_phases filters workflows by the phase of their latest execution. Only + workflows whose most recent execution matches one of the specified phases are + returned. + """ + + workflow_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="workflowIds")] + + +class Pagination(TypedDict, total=False): + token: str + """ + Token for the next set of results that was returned as next_token of a + PaginationResponse + """ + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + """Page size is the maximum number of results to retrieve per page. Defaults to 25. + + Maximum 100. + """ diff --git a/src/gitpod/types/automation_retrieve_execution_action_params.py b/src/gitpod/types/automation_retrieve_execution_action_params.py new file mode 100644 index 00000000..bbf73594 --- /dev/null +++ b/src/gitpod/types/automation_retrieve_execution_action_params.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["AutomationRetrieveExecutionActionParams"] + + +class AutomationRetrieveExecutionActionParams(TypedDict, total=False): + workflow_execution_action_id: Annotated[str, PropertyInfo(alias="workflowExecutionActionId")] diff --git a/src/gitpod/types/automation_retrieve_execution_action_response.py b/src/gitpod/types/automation_retrieve_execution_action_response.py new file mode 100644 index 00000000..77e79a09 --- /dev/null +++ b/src/gitpod/types/automation_retrieve_execution_action_response.py @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .workflow_execution_action import WorkflowExecutionAction + +__all__ = ["AutomationRetrieveExecutionActionResponse"] + + +class AutomationRetrieveExecutionActionResponse(BaseModel): + workflow_execution_action: Optional[WorkflowExecutionAction] = FieldInfo( + alias="workflowExecutionAction", default=None + ) + """WorkflowExecutionAction represents a workflow execution action instance.""" diff --git a/src/gitpod/types/automation_retrieve_execution_params.py b/src/gitpod/types/automation_retrieve_execution_params.py new file mode 100644 index 00000000..b32314e0 --- /dev/null +++ b/src/gitpod/types/automation_retrieve_execution_params.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["AutomationRetrieveExecutionParams"] + + +class AutomationRetrieveExecutionParams(TypedDict, total=False): + workflow_execution_id: Annotated[str, PropertyInfo(alias="workflowExecutionId")] diff --git a/src/gitpod/types/automation_retrieve_execution_response.py b/src/gitpod/types/automation_retrieve_execution_response.py new file mode 100644 index 00000000..7b936a47 --- /dev/null +++ b/src/gitpod/types/automation_retrieve_execution_response.py @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .workflow_execution import WorkflowExecution + +__all__ = ["AutomationRetrieveExecutionResponse"] + + +class AutomationRetrieveExecutionResponse(BaseModel): + workflow_execution: Optional[WorkflowExecution] = FieldInfo(alias="workflowExecution", default=None) + """WorkflowExecution represents a workflow execution instance.""" diff --git a/src/gitpod/types/automation_retrieve_params.py b/src/gitpod/types/automation_retrieve_params.py new file mode 100644 index 00000000..4d17a5cc --- /dev/null +++ b/src/gitpod/types/automation_retrieve_params.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["AutomationRetrieveParams"] + + +class AutomationRetrieveParams(TypedDict, total=False): + workflow_id: Annotated[str, PropertyInfo(alias="workflowId")] diff --git a/src/gitpod/types/automation_retrieve_response.py b/src/gitpod/types/automation_retrieve_response.py new file mode 100644 index 00000000..bdfd185f --- /dev/null +++ b/src/gitpod/types/automation_retrieve_response.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from .._models import BaseModel +from .workflow import Workflow + +__all__ = ["AutomationRetrieveResponse"] + + +class AutomationRetrieveResponse(BaseModel): + workflow: Optional[Workflow] = None + """Workflow represents a workflow configuration.""" diff --git a/src/gitpod/types/automation_start_execution_params.py b/src/gitpod/types/automation_start_execution_params.py new file mode 100644 index 00000000..376b26ed --- /dev/null +++ b/src/gitpod/types/automation_start_execution_params.py @@ -0,0 +1,32 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Dict, Optional +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo +from .workflow_trigger_context_param import WorkflowTriggerContextParam + +__all__ = ["AutomationStartExecutionParams"] + + +class AutomationStartExecutionParams(TypedDict, total=False): + context_override: Annotated[Optional[WorkflowTriggerContextParam], PropertyInfo(alias="contextOverride")] + """ + Optional context override for the execution. When provided, replaces the + workflow's default trigger context. User must have appropriate permissions on + the overridden resources. Supports Projects, Repositories, and Agent context + types. FromTrigger context type is not supported for manual overrides. + """ + + parameters: Dict[str, str] + """ + Parameters to substitute into workflow steps using Go template syntax. Use + {{ .Parameters.key_name }} in templatable fields (task.command, agent.prompt, + pull*request.title/description/branch, trigger context agent.prompt). Keys must + match pattern ^[a-zA-Z*][a-zA-Z0-9_]\\**$ Maximum 10 parameters allowed. Empty map + is treated as no parameters provided. + """ + + workflow_id: Annotated[str, PropertyInfo(alias="workflowId")] diff --git a/src/gitpod/types/automation_start_execution_response.py b/src/gitpod/types/automation_start_execution_response.py new file mode 100644 index 00000000..6e8938a8 --- /dev/null +++ b/src/gitpod/types/automation_start_execution_response.py @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .workflow_execution import WorkflowExecution + +__all__ = ["AutomationStartExecutionResponse"] + + +class AutomationStartExecutionResponse(BaseModel): + workflow_execution: Optional[WorkflowExecution] = FieldInfo(alias="workflowExecution", default=None) + """WorkflowExecution represents a workflow execution instance.""" diff --git a/src/gitpod/types/automation_update_params.py b/src/gitpod/types/automation_update_params.py new file mode 100644 index 00000000..175e84a6 --- /dev/null +++ b/src/gitpod/types/automation_update_params.py @@ -0,0 +1,49 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Iterable, Optional +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo +from .shared_params.subject import Subject +from .workflow_action_param import WorkflowActionParam +from .workflow_trigger_param import WorkflowTriggerParam + +__all__ = ["AutomationUpdateParams"] + + +class AutomationUpdateParams(TypedDict, total=False): + action: Optional[WorkflowActionParam] + """WorkflowAction defines the actions to be executed in a workflow.""" + + description: Optional[str] + """Description must be at most 500 characters: + + ``` + size(this) <= 500 + ``` + """ + + executor: Optional[Subject] + + name: Optional[str] + """Name must be between 1 and 80 characters: + + ``` + size(this) >= 1 && size(this) <= 80 + ``` + """ + + report: Optional[WorkflowActionParam] + """WorkflowAction defines the actions to be executed in a workflow.""" + + triggers: Iterable[WorkflowTriggerParam] + """Automation can have at most 10 triggers: + + ``` + size(this) <= 10 + ``` + """ + + workflow_id: Annotated[str, PropertyInfo(alias="workflowId")] diff --git a/src/gitpod/types/automation_update_response.py b/src/gitpod/types/automation_update_response.py new file mode 100644 index 00000000..d024fedb --- /dev/null +++ b/src/gitpod/types/automation_update_response.py @@ -0,0 +1,13 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from .._models import BaseModel +from .workflow import Workflow + +__all__ = ["AutomationUpdateResponse"] + + +class AutomationUpdateResponse(BaseModel): + workflow: Optional[Workflow] = None + """Workflow represents a workflow configuration.""" diff --git a/src/gitpod/types/bpf_debug_level.py b/src/gitpod/types/bpf_debug_level.py new file mode 100644 index 00000000..261fb8f5 --- /dev/null +++ b/src/gitpod/types/bpf_debug_level.py @@ -0,0 +1,7 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing_extensions import Literal, TypeAlias + +__all__ = ["BpfDebugLevel"] + +BpfDebugLevel: TypeAlias = Literal["BPF_DEBUG_LEVEL_UNSPECIFIED", "BPF_DEBUG_LEVEL_INFO", "BPF_DEBUG_LEVEL_VERBOSE"] diff --git a/src/gitpod/types/environment_create_params.py b/src/gitpod/types/environment_create_params.py index d5c55e8e..711a075d 100644 --- a/src/gitpod/types/environment_create_params.py +++ b/src/gitpod/types/environment_create_params.py @@ -3,8 +3,9 @@ from __future__ import annotations from typing import Optional -from typing_extensions import TypedDict +from typing_extensions import Annotated, TypedDict +from .._utils import PropertyInfo from .environment_spec_param import EnvironmentSpecParam __all__ = ["EnvironmentCreateParams"] @@ -17,6 +18,12 @@ class EnvironmentCreateParams(TypedDict, total=False): system will generate a name. """ + session_id: Annotated[str, PropertyInfo(alias="sessionId")] + """ + session_id is the ID of the session this environment belongs to. If empty, a new + session is created implicitly. + """ + spec: EnvironmentSpecParam """ spec is the configuration of the environment that's required for the to start diff --git a/src/gitpod/types/environment_metadata.py b/src/gitpod/types/environment_metadata.py index 302dded8..28452a70 100644 --- a/src/gitpod/types/environment_metadata.py +++ b/src/gitpod/types/environment_metadata.py @@ -42,6 +42,13 @@ class EnvironmentMetadata(BaseModel): CreateEnvironment or StartEnvironment were called). """ + lockdown_at: Optional[datetime] = FieldInfo(alias="lockdownAt", default=None) + """ + lockdown_at is the time at which the environment becomes locked down due to the + organization's maximum environment lifetime policy. Nil when no lifetime policy + applies. + """ + name: Optional[str] = None """name is the name of the environment as specified by the user""" diff --git a/src/gitpod/types/environment_spec.py b/src/gitpod/types/environment_spec.py index c4a10ecd..0ea027ad 100644 --- a/src/gitpod/types/environment_spec.py +++ b/src/gitpod/types/environment_spec.py @@ -200,7 +200,12 @@ class Timeout(BaseModel): disconnected: Optional[str] = None """ inacitivity is the maximum time of disconnection before the environment is - stopped or paused. Minimum duration is 30 minutes. Set to 0 to disable. + stopped or paused. Minimum duration is 30 minutes. Set to 0 to disable. value + must be 0s (disabled) or at least 1800s (30 minutes): + + ``` + this == duration('0s') || this >= duration('1800s') + ``` """ diff --git a/src/gitpod/types/environment_spec_param.py b/src/gitpod/types/environment_spec_param.py index a646dac6..e761d4d0 100644 --- a/src/gitpod/types/environment_spec_param.py +++ b/src/gitpod/types/environment_spec_param.py @@ -205,7 +205,12 @@ class Timeout(TypedDict, total=False): disconnected: str """ inacitivity is the maximum time of disconnection before the environment is - stopped or paused. Minimum duration is 30 minutes. Set to 0 to disable. + stopped or paused. Minimum duration is 30 minutes. Set to 0 to disable. value + must be 0s (disabled) or at least 1800s (30 minutes): + + ``` + this == duration('0s') || this >= duration('1800s') + ``` """ diff --git a/src/gitpod/types/environment_update_params.py b/src/gitpod/types/environment_update_params.py index 28879ebc..c5437c0a 100644 --- a/src/gitpod/types/environment_update_params.py +++ b/src/gitpod/types/environment_update_params.py @@ -121,7 +121,12 @@ class SpecTimeout(TypedDict, total=False): disconnected: Optional[str] """ inacitivity is the maximum time of disconnection before the environment is - stopped or paused. Minimum duration is 30 minutes. Set to 0 to disable. + stopped or paused. Minimum duration is 30 minutes. Set to 0 to disable. value + must be 0s (disabled) or at least 1800s (30 minutes): + + ``` + this == duration('0s') || this >= duration('1800s') + ``` """ diff --git a/src/gitpod/types/event_list_params.py b/src/gitpod/types/event_list_params.py index 21246d50..b0a320d2 100644 --- a/src/gitpod/types/event_list_params.py +++ b/src/gitpod/types/event_list_params.py @@ -2,12 +2,14 @@ from __future__ import annotations -from typing import List +from typing import List, Union +from datetime import datetime from typing_extensions import Annotated, TypedDict from .._types import SequenceNotStr from .._utils import PropertyInfo from .shared.principal import Principal +from .shared_params.sort import Sort from .shared.resource_type import ResourceType __all__ = ["EventListParams", "Filter", "Pagination"] @@ -21,10 +23,26 @@ class EventListParams(TypedDict, total=False): filter: Filter pagination: Pagination - """pagination contains the pagination options for listing environments""" + """pagination contains the pagination options for listing audit logs""" + sort: Sort + """sort specifies the order of results. -class Filter(TypedDict, total=False): + When unspecified, results are sorted by creation time descending (newest first). + Supported sort fields: createdAt. + """ + + +_FilterReservedKeywords = TypedDict( + "_FilterReservedKeywords", + { + "from": Union[str, datetime, None], + }, + total=False, +) + + +class Filter(_FilterReservedKeywords, total=False): actor_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="actorIds")] actor_principals: Annotated[List[Principal], PropertyInfo(alias="actorPrincipals")] @@ -33,9 +51,12 @@ class Filter(TypedDict, total=False): subject_types: Annotated[List[ResourceType], PropertyInfo(alias="subjectTypes")] + to: Annotated[Union[str, datetime, None], PropertyInfo(format="iso8601")] + """to filters audit logs created before this timestamp (exclusive).""" + class Pagination(TypedDict, total=False): - """pagination contains the pagination options for listing environments""" + """pagination contains the pagination options for listing audit logs""" token: str """ diff --git a/src/gitpod/types/event_watch_params.py b/src/gitpod/types/event_watch_params.py index 0465a094..10c53a53 100644 --- a/src/gitpod/types/event_watch_params.py +++ b/src/gitpod/types/event_watch_params.py @@ -2,11 +2,14 @@ from __future__ import annotations +from typing import Iterable from typing_extensions import Annotated, TypedDict +from .._types import SequenceNotStr from .._utils import PropertyInfo +from .shared.resource_type import ResourceType -__all__ = ["EventWatchParams"] +__all__ = ["EventWatchParams", "ResourceTypeFilter"] class EventWatchParams(TypedDict, total=False): @@ -22,3 +25,31 @@ class EventWatchParams(TypedDict, total=False): the caller can see within their organization. No task, task execution or service events are produed. """ + + resource_type_filters: Annotated[Iterable[ResourceTypeFilter], PropertyInfo(alias="resourceTypeFilters")] + """ + Filters to limit which events are delivered on organization-scoped streams. When + empty, all events for the scope are delivered. When populated, only events + matching at least one filter entry are forwarded. Not supported for + environment-scoped streams; setting this field returns an error. + """ + + +class ResourceTypeFilter(TypedDict, total=False): + """ + ResourceTypeFilter restricts which events are delivered for a specific resource type. + """ + + creator_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="creatorIds")] + """ + If non-empty, only events where the resource was created by one of these user + IDs are delivered. Skipped for DELETE operations (creator info is unavailable + after deletion). Events with no creator information are skipped when this filter + is set (fail-closed). + """ + + resource_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="resourceIds")] + """If non-empty, only events for these specific resource IDs are delivered.""" + + resource_type: Annotated[ResourceType, PropertyInfo(alias="resourceType")] + """The resource type to filter for.""" diff --git a/src/gitpod/types/group_list_params.py b/src/gitpod/types/group_list_params.py index 223e3e8d..55450c32 100644 --- a/src/gitpod/types/group_list_params.py +++ b/src/gitpod/types/group_list_params.py @@ -6,7 +6,7 @@ from .._utils import PropertyInfo -__all__ = ["GroupListParams", "Pagination"] +__all__ = ["GroupListParams", "Filter", "Pagination"] class GroupListParams(TypedDict, total=False): @@ -14,10 +14,20 @@ class GroupListParams(TypedDict, total=False): page_size: Annotated[int, PropertyInfo(alias="pageSize")] + filter: Filter + """filter contains options for filtering the list of groups.""" + pagination: Pagination """pagination contains the pagination options for listing groups""" +class Filter(TypedDict, total=False): + """filter contains options for filtering the list of groups.""" + + search: str + """search performs case-insensitive search across group name, description, and ID""" + + class Pagination(TypedDict, total=False): """pagination contains the pagination options for listing groups""" diff --git a/src/gitpod/types/groups/membership_list_params.py b/src/gitpod/types/groups/membership_list_params.py index e2f90e2d..b4fee1d9 100644 --- a/src/gitpod/types/groups/membership_list_params.py +++ b/src/gitpod/types/groups/membership_list_params.py @@ -6,7 +6,7 @@ from ..._utils import PropertyInfo -__all__ = ["MembershipListParams", "Pagination"] +__all__ = ["MembershipListParams", "Filter", "Pagination"] class MembershipListParams(TypedDict, total=False): @@ -14,12 +14,25 @@ class MembershipListParams(TypedDict, total=False): page_size: Annotated[int, PropertyInfo(alias="pageSize")] + filter: Filter + """filter contains options for filtering the list of memberships.""" + group_id: Annotated[str, PropertyInfo(alias="groupId")] pagination: Pagination """pagination contains the pagination options for listing memberships""" +class Filter(TypedDict, total=False): + """filter contains options for filtering the list of memberships.""" + + search: str + """ + search performs case-insensitive search across member name, email, ID, and + service account name and description + """ + + class Pagination(TypedDict, total=False): """pagination contains the pagination options for listing memberships""" diff --git a/src/gitpod/types/groups/role_assignment_list_params.py b/src/gitpod/types/groups/role_assignment_list_params.py index 52ceaacb..7d3faf02 100644 --- a/src/gitpod/types/groups/role_assignment_list_params.py +++ b/src/gitpod/types/groups/role_assignment_list_params.py @@ -5,6 +5,7 @@ from typing import List from typing_extensions import Annotated, TypedDict +from ..._types import SequenceNotStr from ..._utils import PropertyInfo from ..shared.resource_role import ResourceRole from ..shared.resource_type import ResourceType @@ -34,11 +35,20 @@ class Filter(TypedDict, total=False): """ resource_id: Annotated[str, PropertyInfo(alias="resourceId")] + """Filters by a single resource. + + Non-admin callers with :grant permission on the resource can see role + assignments from groups they don't belong to. Mutually exclusive with + resource_ids. """ - resource_id filters the response to only role assignments for this specific - resource When provided, users with :grant permission on the resource can see its - role assignments even if they don't belong to the assigned groups Empty string - is allowed and means no filtering by resource + + resource_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="resourceIds")] + """Filters by multiple resources in a single request. + + Non-admin callers with :grant permission on a resource can see all role + assignments for that resource, even from groups they don't belong to. The :grant + check is applied per-resource within the batch. Mutually exclusive with + resource_id. """ resource_roles: Annotated[List[ResourceRole], PropertyInfo(alias="resourceRoles")] diff --git a/src/gitpod/types/identity_get_authenticated_identity_response.py b/src/gitpod/types/identity_get_authenticated_identity_response.py index f04ad098..79bd96c8 100644 --- a/src/gitpod/types/identity_get_authenticated_identity_response.py +++ b/src/gitpod/types/identity_get_authenticated_identity_response.py @@ -13,5 +13,7 @@ class IdentityGetAuthenticatedIdentityResponse(BaseModel): organization_id: Optional[str] = FieldInfo(alias="organizationId", default=None) + organization_tier: Optional[str] = FieldInfo(alias="organizationTier", default=None) + subject: Optional[Subject] = None """subject is the identity of the current user""" diff --git a/src/gitpod/types/organization_list_members_params.py b/src/gitpod/types/organization_list_members_params.py index 986af24e..2b4f7714 100644 --- a/src/gitpod/types/organization_list_members_params.py +++ b/src/gitpod/types/organization_list_members_params.py @@ -7,6 +7,7 @@ from .._types import SequenceNotStr from .._utils import PropertyInfo +from .shared.sort_order import SortOrder from .shared.user_status import UserStatus from .shared.organization_role import OrganizationRole @@ -83,4 +84,4 @@ class Sort(TypedDict, total=False): field: Literal["SORT_FIELD_UNSPECIFIED", "SORT_FIELD_NAME", "SORT_FIELD_DATE_JOINED"] - order: Literal["SORT_ORDER_UNSPECIFIED", "SORT_ORDER_ASC", "SORT_ORDER_DESC"] + order: SortOrder diff --git a/src/gitpod/types/organizations/organization_policies.py b/src/gitpod/types/organizations/organization_policies.py index 6929812c..0816b40f 100644 --- a/src/gitpod/types/organizations/organization_policies.py +++ b/src/gitpod/types/organizations/organization_policies.py @@ -113,9 +113,6 @@ class OrganizationPolicies(BaseModel): of the editor """ - executable_deny_list: Optional[VetoExecPolicy] = FieldInfo(alias="executableDenyList", default=None) - """executable_deny_list contains the veto exec policy for environments.""" - maximum_environment_lifetime: Optional[str] = FieldInfo(alias="maximumEnvironmentLifetime", default=None) """ maximum_environment_lifetime controls for how long environments are allowed to @@ -127,7 +124,12 @@ class OrganizationPolicies(BaseModel): """ maximum_environment_timeout controls the maximum timeout allowed for environments in seconds. 0 means no limit (never). Minimum duration is 30 - minutes (1800 seconds). + minutes (1800 seconds). value must be 0s (no limit) or at least 1800s (30 + minutes): + + ``` + this == duration('0s') || this >= duration('1800s') + ``` """ security_agent_policy: Optional[SecurityAgentPolicy] = FieldInfo(alias="securityAgentPolicy", default=None) @@ -136,3 +138,6 @@ class OrganizationPolicies(BaseModel): organization. When configured, security agents are automatically deployed to all environments. """ + + veto_exec_policy: Optional[VetoExecPolicy] = FieldInfo(alias="vetoExecPolicy", default=None) + """veto_exec_policy contains the veto exec policy for environments.""" diff --git a/src/gitpod/types/organizations/policy_update_params.py b/src/gitpod/types/organizations/policy_update_params.py index d69d2928..84d21073 100644 --- a/src/gitpod/types/organizations/policy_update_params.py +++ b/src/gitpod/types/organizations/policy_update_params.py @@ -64,9 +64,6 @@ class PolicyUpdateParams(TypedDict, total=False): editor ID to version policy with allowed major versions. """ - executable_deny_list: Annotated[Optional[VetoExecPolicyParam], PropertyInfo(alias="executableDenyList")] - """executable_deny_list contains the veto exec policy for environments.""" - maximum_environment_lifetime: Annotated[Optional[str], PropertyInfo(alias="maximumEnvironmentLifetime")] """ maximum_environment_lifetime controls for how long environments are allowed to @@ -84,7 +81,12 @@ class PolicyUpdateParams(TypedDict, total=False): """ maximum_environment_timeout controls the maximum timeout allowed for environments in seconds. 0 means no limit (never). Minimum duration is 30 - minutes (1800 seconds). + minutes (1800 seconds). value must be 0s (no limit) or at least 1800s (30 + minutes): + + ``` + this == duration('0s') || this >= duration('1800s') + ``` """ maximum_running_environments_per_user: Annotated[ @@ -127,6 +129,9 @@ class PolicyUpdateParams(TypedDict, total=False): security_agent_policy: Annotated[Optional[SecurityAgentPolicy], PropertyInfo(alias="securityAgentPolicy")] """security_agent_policy contains security agent configuration updates""" + veto_exec_policy: Annotated[Optional[VetoExecPolicyParam], PropertyInfo(alias="vetoExecPolicy")] + """veto_exec_policy contains the veto exec policy for environments.""" + class AgentPolicy(TypedDict, total=False): """agent_policy contains agent-specific policy settings""" diff --git a/src/gitpod/types/prebuild_create_warm_pool_params.py b/src/gitpod/types/prebuild_create_warm_pool_params.py new file mode 100644 index 00000000..051a9558 --- /dev/null +++ b/src/gitpod/types/prebuild_create_warm_pool_params.py @@ -0,0 +1,26 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Required, Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["PrebuildCreateWarmPoolParams"] + + +class PrebuildCreateWarmPoolParams(TypedDict, total=False): + environment_class_id: Required[Annotated[str, PropertyInfo(alias="environmentClassId")]] + """ + environment_class_id specifies which environment class to warm. Must be listed + in the project's prebuild configuration environment_class_ids. + """ + + project_id: Required[Annotated[str, PropertyInfo(alias="projectId")]] + """ + project_id specifies the project this warm pool belongs to. The project must + have prebuilds enabled. + """ + + desired_size: Annotated[int, PropertyInfo(alias="desiredSize")] + """desired_size is the number of warm instances to maintain.""" diff --git a/src/gitpod/types/prebuild_create_warm_pool_response.py b/src/gitpod/types/prebuild_create_warm_pool_response.py new file mode 100644 index 00000000..3bf2f447 --- /dev/null +++ b/src/gitpod/types/prebuild_create_warm_pool_response.py @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .warm_pool import WarmPool + +__all__ = ["PrebuildCreateWarmPoolResponse"] + + +class PrebuildCreateWarmPoolResponse(BaseModel): + warm_pool: WarmPool = FieldInfo(alias="warmPool") + """ + WarmPool maintains pre-created environment instances from a prebuild snapshot + for near-instant environment startup. One warm pool exists per pair. + """ diff --git a/src/gitpod/types/prebuild_delete_warm_pool_params.py b/src/gitpod/types/prebuild_delete_warm_pool_params.py new file mode 100644 index 00000000..5fab3a5b --- /dev/null +++ b/src/gitpod/types/prebuild_delete_warm_pool_params.py @@ -0,0 +1,14 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Required, Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["PrebuildDeleteWarmPoolParams"] + + +class PrebuildDeleteWarmPoolParams(TypedDict, total=False): + warm_pool_id: Required[Annotated[str, PropertyInfo(alias="warmPoolId")]] + """warm_pool_id specifies the warm pool to delete""" diff --git a/src/gitpod/types/prebuild_list_warm_pools_params.py b/src/gitpod/types/prebuild_list_warm_pools_params.py new file mode 100644 index 00000000..1c3b4ae6 --- /dev/null +++ b/src/gitpod/types/prebuild_list_warm_pools_params.py @@ -0,0 +1,48 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._types import SequenceNotStr +from .._utils import PropertyInfo + +__all__ = ["PrebuildListWarmPoolsParams", "Filter", "Pagination"] + + +class PrebuildListWarmPoolsParams(TypedDict, total=False): + token: str + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + + filter: Filter + """filter contains the filter options for listing warm pools""" + + pagination: Pagination + """pagination contains the pagination options for listing warm pools""" + + +class Filter(TypedDict, total=False): + """filter contains the filter options for listing warm pools""" + + environment_class_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="environmentClassIds")] + """environment_class_ids filters warm pools to specific environment classes""" + + project_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="projectIds")] + """project_ids filters warm pools to specific projects""" + + +class Pagination(TypedDict, total=False): + """pagination contains the pagination options for listing warm pools""" + + token: str + """ + Token for the next set of results that was returned as next_token of a + PaginationResponse + """ + + page_size: Annotated[int, PropertyInfo(alias="pageSize")] + """Page size is the maximum number of results to retrieve per page. Defaults to 25. + + Maximum 100. + """ diff --git a/src/gitpod/types/prebuild_retrieve_warm_pool_params.py b/src/gitpod/types/prebuild_retrieve_warm_pool_params.py new file mode 100644 index 00000000..f073b66a --- /dev/null +++ b/src/gitpod/types/prebuild_retrieve_warm_pool_params.py @@ -0,0 +1,14 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Required, Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["PrebuildRetrieveWarmPoolParams"] + + +class PrebuildRetrieveWarmPoolParams(TypedDict, total=False): + warm_pool_id: Required[Annotated[str, PropertyInfo(alias="warmPoolId")]] + """warm_pool_id specifies the warm pool to retrieve""" diff --git a/src/gitpod/types/prebuild_retrieve_warm_pool_response.py b/src/gitpod/types/prebuild_retrieve_warm_pool_response.py new file mode 100644 index 00000000..334c309e --- /dev/null +++ b/src/gitpod/types/prebuild_retrieve_warm_pool_response.py @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .warm_pool import WarmPool + +__all__ = ["PrebuildRetrieveWarmPoolResponse"] + + +class PrebuildRetrieveWarmPoolResponse(BaseModel): + warm_pool: WarmPool = FieldInfo(alias="warmPool") + """ + WarmPool maintains pre-created environment instances from a prebuild snapshot + for near-instant environment startup. One warm pool exists per pair. + """ diff --git a/src/gitpod/types/prebuild_status.py b/src/gitpod/types/prebuild_status.py index dcb1fd07..3510ed0d 100644 --- a/src/gitpod/types/prebuild_status.py +++ b/src/gitpod/types/prebuild_status.py @@ -44,6 +44,12 @@ class PrebuildStatus(BaseModel): the provider. """ + snapshot_size_bytes: Optional[str] = FieldInfo(alias="snapshotSizeBytes", default=None) + """ + snapshot_size_bytes is the size of the snapshot in bytes. Only populated when + the snapshot is available (phase is COMPLETED). + """ + status_version: Optional[str] = FieldInfo(alias="statusVersion", default=None) """ status_version is incremented each time the status is updated. Used for diff --git a/src/gitpod/types/prebuild_update_warm_pool_params.py b/src/gitpod/types/prebuild_update_warm_pool_params.py new file mode 100644 index 00000000..a0137ce5 --- /dev/null +++ b/src/gitpod/types/prebuild_update_warm_pool_params.py @@ -0,0 +1,18 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Optional +from typing_extensions import Required, Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["PrebuildUpdateWarmPoolParams"] + + +class PrebuildUpdateWarmPoolParams(TypedDict, total=False): + warm_pool_id: Required[Annotated[str, PropertyInfo(alias="warmPoolId")]] + """warm_pool_id specifies the warm pool to update""" + + desired_size: Annotated[Optional[int], PropertyInfo(alias="desiredSize")] + """desired_size updates the number of warm instances to maintain.""" diff --git a/src/gitpod/types/prebuild_update_warm_pool_response.py b/src/gitpod/types/prebuild_update_warm_pool_response.py new file mode 100644 index 00000000..cfa24d08 --- /dev/null +++ b/src/gitpod/types/prebuild_update_warm_pool_response.py @@ -0,0 +1,17 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .warm_pool import WarmPool + +__all__ = ["PrebuildUpdateWarmPoolResponse"] + + +class PrebuildUpdateWarmPoolResponse(BaseModel): + warm_pool: WarmPool = FieldInfo(alias="warmPool") + """ + WarmPool maintains pre-created environment instances from a prebuild snapshot + for near-instant environment startup. One warm pool exists per pair. + """ diff --git a/src/gitpod/types/project_list_params.py b/src/gitpod/types/project_list_params.py index 0ce45e83..796fa58a 100644 --- a/src/gitpod/types/project_list_params.py +++ b/src/gitpod/types/project_list_params.py @@ -8,6 +8,7 @@ from .._types import SequenceNotStr from .._utils import PropertyInfo from .runner_kind import RunnerKind +from .shared_params.sort import Sort __all__ = ["ProjectListParams", "Filter", "Pagination"] @@ -22,6 +23,17 @@ class ProjectListParams(TypedDict, total=False): pagination: Pagination """pagination contains the pagination options for listing organizations""" + sort: Sort + """sort specifies the order of results. Defaults to popularity descending. + + Supported fields: + + - "id": Sort by project ID (UUID v7, effectively creation order). Produces a + stable, deterministic result set suitable for consistent pagination. + - "popularity": Sort by popularity — a precomputed score based on recent + environment creation activity. Updated periodically by a background job. + """ + class Filter(TypedDict, total=False): project_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="projectIds")] diff --git a/src/gitpod/types/role.py b/src/gitpod/types/role.py new file mode 100644 index 00000000..89dd1b9b --- /dev/null +++ b/src/gitpod/types/role.py @@ -0,0 +1,7 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing_extensions import Literal, TypeAlias + +__all__ = ["Role"] + +Role: TypeAlias = Literal["ROLE_UNSPECIFIED", "ROLE_PARENT", "ROLE_CHILD"] diff --git a/src/gitpod/types/runner_capability.py b/src/gitpod/types/runner_capability.py index 4224cfba..a0528961 100644 --- a/src/gitpod/types/runner_capability.py +++ b/src/gitpod/types/runner_capability.py @@ -16,4 +16,5 @@ "RUNNER_CAPABILITY_LIST_SCM_ORGANIZATIONS", "RUNNER_CAPABILITY_CHECK_REPOSITORY_ACCESS", "RUNNER_CAPABILITY_RUNNER_SIDE_AGENT", + "RUNNER_CAPABILITY_WARM_POOL", ] diff --git a/src/gitpod/types/shared/__init__.py b/src/gitpod/types/shared/__init__.py index 04e206d4..0d4db91c 100644 --- a/src/gitpod/types/shared/__init__.py +++ b/src/gitpod/types/shared/__init__.py @@ -1,5 +1,6 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. +from .sort import Sort as Sort from .task import Task as Task from .state import State as State from .gateway import Gateway as Gateway @@ -9,6 +10,7 @@ from .task_spec import TaskSpec as TaskSpec from .error_code import ErrorCode as ErrorCode from .secret_ref import SecretRef as SecretRef +from .sort_order import SortOrder as SortOrder from .field_value import FieldValue as FieldValue from .user_status import UserStatus as UserStatus from .resource_role import ResourceRole as ResourceRole @@ -22,6 +24,7 @@ from .task_execution_spec import TaskExecutionSpec as TaskExecutionSpec from .task_execution_phase import TaskExecutionPhase as TaskExecutionPhase from .task_execution_status import TaskExecutionStatus as TaskExecutionStatus +from .count_response_relation import CountResponseRelation as CountResponseRelation from .task_execution_metadata import TaskExecutionMetadata as TaskExecutionMetadata from .environment_variable_item import EnvironmentVariableItem as EnvironmentVariableItem from .project_environment_class import ProjectEnvironmentClass as ProjectEnvironmentClass diff --git a/src/gitpod/types/shared/count_response_relation.py b/src/gitpod/types/shared/count_response_relation.py new file mode 100644 index 00000000..6b4f3228 --- /dev/null +++ b/src/gitpod/types/shared/count_response_relation.py @@ -0,0 +1,9 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing_extensions import Literal, TypeAlias + +__all__ = ["CountResponseRelation"] + +CountResponseRelation: TypeAlias = Literal[ + "COUNT_RESPONSE_RELATION_UNSPECIFIED", "COUNT_RESPONSE_RELATION_EQ", "COUNT_RESPONSE_RELATION_GTE" +] diff --git a/src/gitpod/types/shared/principal.py b/src/gitpod/types/shared/principal.py index b71334f8..5300b520 100644 --- a/src/gitpod/types/shared/principal.py +++ b/src/gitpod/types/shared/principal.py @@ -12,5 +12,4 @@ "PRINCIPAL_ENVIRONMENT", "PRINCIPAL_SERVICE_ACCOUNT", "PRINCIPAL_RUNNER_MANAGER", - "PRINCIPAL_AGENT_EXECUTION", ] diff --git a/src/gitpod/types/shared/resource_role.py b/src/gitpod/types/shared/resource_role.py index c26b9211..e9c753f3 100644 --- a/src/gitpod/types/shared/resource_role.py +++ b/src/gitpod/types/shared/resource_role.py @@ -43,7 +43,6 @@ "RESOURCE_ROLE_ENVIRONMENT_TASK_ENV", "RESOURCE_ROLE_SERVICE_ACCOUNT_IDENTITY", "RESOURCE_ROLE_SERVICE_ACCOUNT_ADMIN", - "RESOURCE_ROLE_AGENT_EXECUTION_IDENTITY", "RESOURCE_ROLE_AGENT_EXECUTION_USER", "RESOURCE_ROLE_AGENT_EXECUTION_ADMIN", "RESOURCE_ROLE_AGENT_EXECUTION_RUNNER", @@ -62,4 +61,8 @@ "RESOURCE_ROLE_WARMPOOL_RUNNER", "RESOURCE_ROLE_WARMPOOL_ADMIN", "RESOURCE_ROLE_WARMPOOL_VIEWER", + "RESOURCE_ROLE_SESSION_ADMIN", + "RESOURCE_ROLE_SESSION_USER", + "RESOURCE_ROLE_TEAM_ADMIN", + "RESOURCE_ROLE_TEAM_VIEWER", ] diff --git a/src/gitpod/types/shared/sort.py b/src/gitpod/types/shared/sort.py new file mode 100644 index 00000000..a34fee6f --- /dev/null +++ b/src/gitpod/types/shared/sort.py @@ -0,0 +1,15 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from ..._models import BaseModel +from .sort_order import SortOrder + +__all__ = ["Sort"] + + +class Sort(BaseModel): + field: Optional[str] = None + """Field name to sort by, in camelCase.""" + + order: Optional[SortOrder] = None diff --git a/src/gitpod/types/shared/sort_order.py b/src/gitpod/types/shared/sort_order.py new file mode 100644 index 00000000..c0164b54 --- /dev/null +++ b/src/gitpod/types/shared/sort_order.py @@ -0,0 +1,7 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing_extensions import Literal, TypeAlias + +__all__ = ["SortOrder"] + +SortOrder: TypeAlias = Literal["SORT_ORDER_UNSPECIFIED", "SORT_ORDER_ASC", "SORT_ORDER_DESC"] diff --git a/src/gitpod/types/shared_params/__init__.py b/src/gitpod/types/shared_params/__init__.py index 1d82dedc..48b06ca8 100644 --- a/src/gitpod/types/shared_params/__init__.py +++ b/src/gitpod/types/shared_params/__init__.py @@ -1,11 +1,13 @@ # File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. +from .sort import Sort as Sort from .state import State as State from .runs_on import RunsOn as RunsOn from .subject import Subject as Subject from .principal import Principal as Principal from .task_spec import TaskSpec as TaskSpec from .secret_ref import SecretRef as SecretRef +from .sort_order import SortOrder as SortOrder from .field_value import FieldValue as FieldValue from .user_status import UserStatus as UserStatus from .resource_role import ResourceRole as ResourceRole diff --git a/src/gitpod/types/shared_params/principal.py b/src/gitpod/types/shared_params/principal.py index 465d7b21..3cefcfa1 100644 --- a/src/gitpod/types/shared_params/principal.py +++ b/src/gitpod/types/shared_params/principal.py @@ -14,5 +14,4 @@ "PRINCIPAL_ENVIRONMENT", "PRINCIPAL_SERVICE_ACCOUNT", "PRINCIPAL_RUNNER_MANAGER", - "PRINCIPAL_AGENT_EXECUTION", ] diff --git a/src/gitpod/types/shared_params/resource_role.py b/src/gitpod/types/shared_params/resource_role.py index 71d430d8..c040a312 100644 --- a/src/gitpod/types/shared_params/resource_role.py +++ b/src/gitpod/types/shared_params/resource_role.py @@ -45,7 +45,6 @@ "RESOURCE_ROLE_ENVIRONMENT_TASK_ENV", "RESOURCE_ROLE_SERVICE_ACCOUNT_IDENTITY", "RESOURCE_ROLE_SERVICE_ACCOUNT_ADMIN", - "RESOURCE_ROLE_AGENT_EXECUTION_IDENTITY", "RESOURCE_ROLE_AGENT_EXECUTION_USER", "RESOURCE_ROLE_AGENT_EXECUTION_ADMIN", "RESOURCE_ROLE_AGENT_EXECUTION_RUNNER", @@ -64,4 +63,8 @@ "RESOURCE_ROLE_WARMPOOL_RUNNER", "RESOURCE_ROLE_WARMPOOL_ADMIN", "RESOURCE_ROLE_WARMPOOL_VIEWER", + "RESOURCE_ROLE_SESSION_ADMIN", + "RESOURCE_ROLE_SESSION_USER", + "RESOURCE_ROLE_TEAM_ADMIN", + "RESOURCE_ROLE_TEAM_VIEWER", ] diff --git a/src/gitpod/types/shared_params/sort.py b/src/gitpod/types/shared_params/sort.py new file mode 100644 index 00000000..9ed3a2ed --- /dev/null +++ b/src/gitpod/types/shared_params/sort.py @@ -0,0 +1,16 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import TypedDict + +from ..shared.sort_order import SortOrder + +__all__ = ["Sort"] + + +class Sort(TypedDict, total=False): + field: str + """Field name to sort by, in camelCase.""" + + order: SortOrder diff --git a/src/gitpod/types/shared_params/sort_order.py b/src/gitpod/types/shared_params/sort_order.py new file mode 100644 index 00000000..679df500 --- /dev/null +++ b/src/gitpod/types/shared_params/sort_order.py @@ -0,0 +1,9 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Literal, TypeAlias + +__all__ = ["SortOrder"] + +SortOrder: TypeAlias = Literal["SORT_ORDER_UNSPECIFIED", "SORT_ORDER_ASC", "SORT_ORDER_DESC"] diff --git a/src/gitpod/types/type.py b/src/gitpod/types/type.py new file mode 100644 index 00000000..585a3d8f --- /dev/null +++ b/src/gitpod/types/type.py @@ -0,0 +1,7 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing_extensions import Literal, TypeAlias + +__all__ = ["Type"] + +Type: TypeAlias = Literal["TYPE_UNSPECIFIED", "TYPE_UPDATE", "TYPE_COMPLETE"] diff --git a/src/gitpod/types/wake_event_param.py b/src/gitpod/types/wake_event_param.py new file mode 100644 index 00000000..eae916dc --- /dev/null +++ b/src/gitpod/types/wake_event_param.py @@ -0,0 +1,28 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Union +from datetime import datetime +from typing_extensions import Required, Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["WakeEventParam", "Timer"] + + +class Timer(TypedDict, total=False): + fired_at: Annotated[Union[str, datetime], PropertyInfo(alias="firedAt", format="iso8601")] + """The actual time the timer was evaluated as expired.""" + + +class WakeEventParam(TypedDict, total=False): + """ + WakeEvent is sent by the backend to wake an agent when a registered interest fires. + Delivered via SendToAgentExecution as a new oneof variant. + """ + + timer: Required[Timer] + + interest_id: Annotated[str, PropertyInfo(alias="interestId")] + """The interest ID that fired (from WaitingInfo.Interest.id).""" diff --git a/src/gitpod/types/warm_pool.py b/src/gitpod/types/warm_pool.py new file mode 100644 index 00000000..3739d57e --- /dev/null +++ b/src/gitpod/types/warm_pool.py @@ -0,0 +1,30 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from .._models import BaseModel +from .warm_pool_spec import WarmPoolSpec +from .warm_pool_status import WarmPoolStatus +from .warm_pool_metadata import WarmPoolMetadata + +__all__ = ["WarmPool"] + + +class WarmPool(BaseModel): + """ + WarmPool maintains pre-created environment instances from a prebuild snapshot + for near-instant environment startup. + One warm pool exists per pair. + """ + + metadata: WarmPoolMetadata + """metadata contains organizational and ownership information""" + + spec: WarmPoolSpec + """spec contains the desired configuration for this warm pool""" + + status: WarmPoolStatus + """status contains the current status reported by the runner""" + + id: Optional[str] = None + """id is the unique identifier for the warm pool""" diff --git a/src/gitpod/types/warm_pool_metadata.py b/src/gitpod/types/warm_pool_metadata.py new file mode 100644 index 00000000..63e81be1 --- /dev/null +++ b/src/gitpod/types/warm_pool_metadata.py @@ -0,0 +1,35 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional +from datetime import datetime + +from pydantic import Field as FieldInfo + +from .._models import BaseModel + +__all__ = ["WarmPoolMetadata"] + + +class WarmPoolMetadata(BaseModel): + """WarmPoolMetadata contains metadata about the warm pool""" + + created_at: datetime = FieldInfo(alias="createdAt") + """created_at is when the warm pool was created""" + + updated_at: datetime = FieldInfo(alias="updatedAt") + """updated_at is when the warm pool was last updated""" + + environment_class_id: Optional[str] = FieldInfo(alias="environmentClassId", default=None) + """environment_class_id is the environment class whose instances are warmed""" + + organization_id: Optional[str] = FieldInfo(alias="organizationId", default=None) + """organization_id is the ID of the organization that owns the warm pool""" + + project_id: Optional[str] = FieldInfo(alias="projectId", default=None) + """project_id is the ID of the project this warm pool belongs to""" + + runner_id: Optional[str] = FieldInfo(alias="runnerId", default=None) + """ + runner_id is the runner that manages this warm pool. Derived from the + environment class. + """ diff --git a/src/gitpod/types/warm_pool_phase.py b/src/gitpod/types/warm_pool_phase.py new file mode 100644 index 00000000..08fa3b48 --- /dev/null +++ b/src/gitpod/types/warm_pool_phase.py @@ -0,0 +1,14 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing_extensions import Literal, TypeAlias + +__all__ = ["WarmPoolPhase"] + +WarmPoolPhase: TypeAlias = Literal[ + "WARM_POOL_PHASE_UNSPECIFIED", + "WARM_POOL_PHASE_PENDING", + "WARM_POOL_PHASE_READY", + "WARM_POOL_PHASE_DEGRADED", + "WARM_POOL_PHASE_DELETING", + "WARM_POOL_PHASE_DELETED", +] diff --git a/src/gitpod/types/warm_pool_spec.py b/src/gitpod/types/warm_pool_spec.py new file mode 100644 index 00000000..e82ac84a --- /dev/null +++ b/src/gitpod/types/warm_pool_spec.py @@ -0,0 +1,36 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .warm_pool_phase import WarmPoolPhase + +__all__ = ["WarmPoolSpec"] + + +class WarmPoolSpec(BaseModel): + """WarmPoolSpec contains the desired configuration for a warm pool""" + + desired_phase: Optional[WarmPoolPhase] = FieldInfo(alias="desiredPhase", default=None) + """ + desired_phase is the intended lifecycle phase for this warm pool. Managed by the + API and reconciler. + """ + + desired_size: Optional[int] = FieldInfo(alias="desiredSize", default=None) + """desired_size is the number of warm instances to maintain.""" + + snapshot_id: Optional[str] = FieldInfo(alias="snapshotId", default=None) + """ + snapshot_id is the prebuild snapshot to warm up in the pool. Updated by the + reconciler when a new prebuild completes for this project and environment class. + Empty when no completed prebuild exists yet. + """ + + spec_version: Optional[str] = FieldInfo(alias="specVersion", default=None) + """ + spec_version is incremented each time the spec is updated. Used for optimistic + concurrency control. + """ diff --git a/src/gitpod/types/warm_pool_status.py b/src/gitpod/types/warm_pool_status.py new file mode 100644 index 00000000..b7605272 --- /dev/null +++ b/src/gitpod/types/warm_pool_status.py @@ -0,0 +1,28 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .warm_pool_phase import WarmPoolPhase + +__all__ = ["WarmPoolStatus"] + + +class WarmPoolStatus(BaseModel): + """ + WarmPoolStatus contains the current status of a warm pool as reported by the runner + """ + + phase: WarmPoolPhase + """phase is the current phase of the warm pool lifecycle""" + + failure_message: Optional[str] = FieldInfo(alias="failureMessage", default=None) + """failure_message contains details about why the warm pool is degraded or failed""" + + status_version: Optional[str] = FieldInfo(alias="statusVersion", default=None) + """ + status_version is incremented each time the status is updated. Used for + optimistic concurrency control. + """ diff --git a/src/gitpod/types/workflow.py b/src/gitpod/types/workflow.py new file mode 100644 index 00000000..6d0e5cc9 --- /dev/null +++ b/src/gitpod/types/workflow.py @@ -0,0 +1,236 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import List, Optional +from datetime import datetime + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .shared.subject import Subject +from .workflow_action import WorkflowAction +from .workflow_trigger import WorkflowTrigger + +__all__ = ["Workflow", "Metadata", "Spec"] + + +class Metadata(BaseModel): + """WorkflowMetadata contains workflow metadata.""" + + created_at: Optional[datetime] = FieldInfo(alias="createdAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + creator: Optional[Subject] = None + + description: Optional[str] = None + + executor: Optional[Subject] = None + + name: Optional[str] = None + + updated_at: Optional[datetime] = FieldInfo(alias="updatedAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + +class Spec(BaseModel): + action: Optional[WorkflowAction] = None + """WorkflowAction defines the actions to be executed in a workflow.""" + + report: Optional[WorkflowAction] = None + """WorkflowAction defines the actions to be executed in a workflow.""" + + triggers: Optional[List[WorkflowTrigger]] = None + + +class Workflow(BaseModel): + """Workflow represents a workflow configuration.""" + + id: Optional[str] = None + + metadata: Optional[Metadata] = None + """WorkflowMetadata contains workflow metadata.""" + + spec: Optional[Spec] = None + + webhook_url: Optional[str] = FieldInfo(alias="webhookUrl", default=None) + """ + Webhook URL for triggering this workflow via HTTP POST Format: + {base_url}/workflows/{workflow_id}/webhooks + """ diff --git a/src/gitpod/types/workflow_action.py b/src/gitpod/types/workflow_action.py new file mode 100644 index 00000000..d0b4e903 --- /dev/null +++ b/src/gitpod/types/workflow_action.py @@ -0,0 +1,71 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import List, Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .workflow_step import WorkflowStep + +__all__ = ["WorkflowAction", "Limits", "LimitsPerExecution"] + + +class LimitsPerExecution(BaseModel): + """PerExecution defines limits per execution action.""" + + max_time: Optional[str] = FieldInfo(alias="maxTime", default=None) + """ + Maximum time allowed for a single execution action. Use standard duration format + (e.g., "30m" for 30 minutes, "2h" for 2 hours). + """ + + +class Limits(BaseModel): + """ + Limits defines execution limits for workflow actions. + Concurrent actions limit cannot exceed total actions limit: + ``` + this.max_parallel <= this.max_total + ``` + """ + + max_parallel: Optional[int] = FieldInfo(alias="maxParallel", default=None) + """Maximum parallel actions must be between 1 and 25: + + ``` + this >= 1 && this <= 25 + ``` + """ + + max_total: Optional[int] = FieldInfo(alias="maxTotal", default=None) + """Maximum total actions must be between 1 and 100: + + ``` + this >= 1 && this <= 100 + ``` + """ + + per_execution: Optional[LimitsPerExecution] = FieldInfo(alias="perExecution", default=None) + """PerExecution defines limits per execution action.""" + + +class WorkflowAction(BaseModel): + """WorkflowAction defines the actions to be executed in a workflow.""" + + limits: Limits + """ + Limits defines execution limits for workflow actions. Concurrent actions limit + cannot exceed total actions limit: + + ``` + this.max_parallel <= this.max_total + ``` + """ + + steps: Optional[List[WorkflowStep]] = None + """Automation must have between 1 and 50 steps: + + ``` + size(this) >= 1 && size(this) <= 50 + ``` + """ diff --git a/src/gitpod/types/workflow_action_param.py b/src/gitpod/types/workflow_action_param.py new file mode 100644 index 00000000..f6464ab3 --- /dev/null +++ b/src/gitpod/types/workflow_action_param.py @@ -0,0 +1,72 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Iterable +from typing_extensions import Required, Annotated, TypedDict + +from .._utils import PropertyInfo +from .workflow_step_param import WorkflowStepParam + +__all__ = ["WorkflowActionParam", "Limits", "LimitsPerExecution"] + + +class LimitsPerExecution(TypedDict, total=False): + """PerExecution defines limits per execution action.""" + + max_time: Annotated[str, PropertyInfo(alias="maxTime")] + """ + Maximum time allowed for a single execution action. Use standard duration format + (e.g., "30m" for 30 minutes, "2h" for 2 hours). + """ + + +class Limits(TypedDict, total=False): + """ + Limits defines execution limits for workflow actions. + Concurrent actions limit cannot exceed total actions limit: + ``` + this.max_parallel <= this.max_total + ``` + """ + + max_parallel: Annotated[int, PropertyInfo(alias="maxParallel")] + """Maximum parallel actions must be between 1 and 25: + + ``` + this >= 1 && this <= 25 + ``` + """ + + max_total: Annotated[int, PropertyInfo(alias="maxTotal")] + """Maximum total actions must be between 1 and 100: + + ``` + this >= 1 && this <= 100 + ``` + """ + + per_execution: Annotated[LimitsPerExecution, PropertyInfo(alias="perExecution")] + """PerExecution defines limits per execution action.""" + + +class WorkflowActionParam(TypedDict, total=False): + """WorkflowAction defines the actions to be executed in a workflow.""" + + limits: Required[Limits] + """ + Limits defines execution limits for workflow actions. Concurrent actions limit + cannot exceed total actions limit: + + ``` + this.max_parallel <= this.max_total + ``` + """ + + steps: Iterable[WorkflowStepParam] + """Automation must have between 1 and 50 steps: + + ``` + size(this) >= 1 && size(this) <= 50 + ``` + """ diff --git a/src/gitpod/types/workflow_execution.py b/src/gitpod/types/workflow_execution.py new file mode 100644 index 00000000..5608014a --- /dev/null +++ b/src/gitpod/types/workflow_execution.py @@ -0,0 +1,560 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Dict, List, Optional +from datetime import datetime +from typing_extensions import Literal + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .shared.state import State +from .shared.subject import Subject +from .workflow_action import WorkflowAction +from .workflow_trigger_context import WorkflowTriggerContext + +__all__ = [ + "WorkflowExecution", + "Metadata", + "Spec", + "SpecTrigger", + "SpecTriggerPullRequest", + "SpecTriggerPullRequestRepository", + "SpecTriggerTime", + "Status", + "StatusFailure", + "StatusFailureRetry", + "StatusWarning", + "StatusWarningRetry", +] + + +class Metadata(BaseModel): + """WorkflowExecutionMetadata contains workflow execution metadata.""" + + creator: Optional[Subject] = None + + executor: Optional[Subject] = None + + finished_at: Optional[datetime] = FieldInfo(alias="finishedAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + started_at: Optional[datetime] = FieldInfo(alias="startedAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + workflow_id: Optional[str] = FieldInfo(alias="workflowId", default=None) + + +class SpecTriggerPullRequestRepository(BaseModel): + """Repository information""" + + clone_url: Optional[str] = FieldInfo(alias="cloneUrl", default=None) + + host: Optional[str] = None + + name: Optional[str] = None + + owner: Optional[str] = None + + +class SpecTriggerPullRequest(BaseModel): + """ + PullRequest represents pull request metadata from source control systems. + This message is used across workflow triggers, executions, and agent contexts + to maintain consistent PR information throughout the system. + """ + + id: Optional[str] = None + """Unique identifier from the source system (e.g., "123" for GitHub PR #123)""" + + author: Optional[str] = None + """Author name as provided by the SCM system""" + + draft: Optional[bool] = None + """Whether this is a draft pull request""" + + from_branch: Optional[str] = FieldInfo(alias="fromBranch", default=None) + """Source branch name (the branch being merged from)""" + + repository: Optional[SpecTriggerPullRequestRepository] = None + """Repository information""" + + state: Optional[State] = None + """Current state of the pull request""" + + title: Optional[str] = None + """Pull request title""" + + to_branch: Optional[str] = FieldInfo(alias="toBranch", default=None) + """Target branch name (the branch being merged into)""" + + url: Optional[str] = None + """Pull request URL (e.g., "https://github.com/owner/repo/pull/123")""" + + +class SpecTriggerTime(BaseModel): + """Time trigger - just the timestamp when it was triggered""" + + triggered_at: Optional[datetime] = FieldInfo(alias="triggeredAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + +class SpecTrigger(BaseModel): + """WorkflowExecutionTrigger represents a workflow execution trigger instance.""" + + context: WorkflowTriggerContext + """ + Context from the workflow trigger - copied at execution time for immutability. + This allows the reconciler to create actions without fetching the workflow + definition. + """ + + manual: Optional[object] = None + """Manual trigger - empty message since no additional data needed""" + + pull_request: Optional[SpecTriggerPullRequest] = FieldInfo(alias="pullRequest", default=None) + """ + PullRequest represents pull request metadata from source control systems. This + message is used across workflow triggers, executions, and agent contexts to + maintain consistent PR information throughout the system. + """ + + time: Optional[SpecTriggerTime] = None + """Time trigger - just the timestamp when it was triggered""" + + +class Spec(BaseModel): + """WorkflowExecutionSpec contains the specification used for this execution.""" + + action: Optional[WorkflowAction] = None + """WorkflowAction defines the actions to be executed in a workflow.""" + + report: Optional[WorkflowAction] = None + """WorkflowAction defines the actions to be executed in a workflow.""" + + trigger: Optional[SpecTrigger] = None + """WorkflowExecutionTrigger represents a workflow execution trigger instance.""" + + +class StatusFailureRetry(BaseModel): + """Retry configuration. If not set, the error is considered non-retriable.""" + + retriable: Optional[bool] = None + """Whether the error is retriable.""" + + retry_after: Optional[str] = FieldInfo(alias="retryAfter", default=None) + """ + Suggested duration to wait before retrying. Only meaningful when retriable is + true. + """ + + +class StatusFailure(BaseModel): + """ + WorkflowError provides structured error information for workflow failures. + This enables the reconciler to make informed retry decisions and the frontend + to display actionable error messages. + """ + + code: Optional[ + Literal[ + "WORKFLOW_ERROR_CODE_UNSPECIFIED", + "WORKFLOW_ERROR_CODE_ENVIRONMENT_ERROR", + "WORKFLOW_ERROR_CODE_AGENT_ERROR", + ] + ] = None + """Error code identifying the type of error.""" + + message: Optional[str] = None + """Human-readable error message.""" + + meta: Optional[Dict[str, str]] = None + """Additional metadata about the error. Common keys include: + + - environment_id: ID of the environment + - task_id: ID of the task + - service_id: ID of the service + - workflow_id: ID of the workflow + - workflow_execution_id: ID of the workflow execution + """ + + reason: Optional[str] = None + """ + Reason explaining why the error occurred. Examples: "not_found", "stopped", + "deleted", "creation_failed", "start_failed" + """ + + retry: Optional[StatusFailureRetry] = None + """Retry configuration. If not set, the error is considered non-retriable.""" + + +class StatusWarningRetry(BaseModel): + """Retry configuration. If not set, the error is considered non-retriable.""" + + retriable: Optional[bool] = None + """Whether the error is retriable.""" + + retry_after: Optional[str] = FieldInfo(alias="retryAfter", default=None) + """ + Suggested duration to wait before retrying. Only meaningful when retriable is + true. + """ + + +class StatusWarning(BaseModel): + """ + WorkflowError provides structured error information for workflow failures. + This enables the reconciler to make informed retry decisions and the frontend + to display actionable error messages. + """ + + code: Optional[ + Literal[ + "WORKFLOW_ERROR_CODE_UNSPECIFIED", + "WORKFLOW_ERROR_CODE_ENVIRONMENT_ERROR", + "WORKFLOW_ERROR_CODE_AGENT_ERROR", + ] + ] = None + """Error code identifying the type of error.""" + + message: Optional[str] = None + """Human-readable error message.""" + + meta: Optional[Dict[str, str]] = None + """Additional metadata about the error. Common keys include: + + - environment_id: ID of the environment + - task_id: ID of the task + - service_id: ID of the service + - workflow_id: ID of the workflow + - workflow_execution_id: ID of the workflow execution + """ + + reason: Optional[str] = None + """ + Reason explaining why the error occurred. Examples: "not_found", "stopped", + "deleted", "creation_failed", "start_failed" + """ + + retry: Optional[StatusWarningRetry] = None + """Retry configuration. If not set, the error is considered non-retriable.""" + + +class Status(BaseModel): + """WorkflowExecutionStatus contains the current status of a workflow execution.""" + + done_action_count: Optional[int] = FieldInfo(alias="doneActionCount", default=None) + + failed_action_count: Optional[int] = FieldInfo(alias="failedActionCount", default=None) + + failures: Optional[List[StatusFailure]] = None + """ + Structured failures that caused the workflow execution to fail. Provides + detailed error codes, messages, and retry information. + """ + + pending_action_count: Optional[int] = FieldInfo(alias="pendingActionCount", default=None) + + phase: Optional[ + Literal[ + "WORKFLOW_EXECUTION_PHASE_UNSPECIFIED", + "WORKFLOW_EXECUTION_PHASE_PENDING", + "WORKFLOW_EXECUTION_PHASE_RUNNING", + "WORKFLOW_EXECUTION_PHASE_STOPPING", + "WORKFLOW_EXECUTION_PHASE_STOPPED", + "WORKFLOW_EXECUTION_PHASE_DELETING", + "WORKFLOW_EXECUTION_PHASE_DELETED", + "WORKFLOW_EXECUTION_PHASE_COMPLETED", + ] + ] = None + + running_action_count: Optional[int] = FieldInfo(alias="runningActionCount", default=None) + + stopped_action_count: Optional[int] = FieldInfo(alias="stoppedActionCount", default=None) + + warnings: Optional[List[StatusWarning]] = None + """ + Structured warnings about the workflow execution. Provides detailed warning + codes and messages. + """ + + +class WorkflowExecution(BaseModel): + """WorkflowExecution represents a workflow execution instance.""" + + id: Optional[str] = None + + metadata: Optional[Metadata] = None + """WorkflowExecutionMetadata contains workflow execution metadata.""" + + spec: Optional[Spec] = None + """WorkflowExecutionSpec contains the specification used for this execution.""" + + status: Optional[Status] = None + """WorkflowExecutionStatus contains the current status of a workflow execution.""" diff --git a/src/gitpod/types/workflow_execution_action.py b/src/gitpod/types/workflow_execution_action.py new file mode 100644 index 00000000..e7eb6454 --- /dev/null +++ b/src/gitpod/types/workflow_execution_action.py @@ -0,0 +1,682 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import Dict, List, Optional +from datetime import datetime +from typing_extensions import Literal + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .workflow_step import WorkflowStep +from .agent_code_context import AgentCodeContext + +__all__ = [ + "WorkflowExecutionAction", + "Metadata", + "Spec", + "SpecLimits", + "Status", + "StatusFailure", + "StatusFailureRetry", + "StatusStepStatus", + "StatusStepStatusError", + "StatusStepStatusErrorRetry", + "StatusWarning", + "StatusWarningRetry", +] + + +class Metadata(BaseModel): + """WorkflowExecutionActionMetadata contains workflow execution action metadata.""" + + action_name: Optional[str] = FieldInfo(alias="actionName", default=None) + """ + Human-readable name for this action based on its context. Examples: + "gitpod-io/gitpod-next" for repository context, "My Project" for project + context. Will be empty string for actions created before this field was added. + """ + + finished_at: Optional[datetime] = FieldInfo(alias="finishedAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + started_at: Optional[datetime] = FieldInfo(alias="startedAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + workflow_execution_id: Optional[str] = FieldInfo(alias="workflowExecutionId", default=None) + + workflow_id: Optional[str] = FieldInfo(alias="workflowId", default=None) + + +class SpecLimits(BaseModel): + """PerExecution defines limits per execution action.""" + + max_time: Optional[str] = FieldInfo(alias="maxTime", default=None) + """ + Maximum time allowed for a single execution action. Use standard duration format + (e.g., "30m" for 30 minutes, "2h" for 2 hours). + """ + + +class Spec(BaseModel): + """ + WorkflowExecutionActionSpec contains the specification for this execution action. + """ + + context: Optional[AgentCodeContext] = None + """ + Context for the execution action - specifies where and how the action executes. + This is resolved from the workflow trigger context and contains the specific + project, repository, or agent context for this execution instance. + """ + + limits: Optional[SpecLimits] = None + """PerExecution defines limits per execution action.""" + + +class StatusFailureRetry(BaseModel): + """Retry configuration. If not set, the error is considered non-retriable.""" + + retriable: Optional[bool] = None + """Whether the error is retriable.""" + + retry_after: Optional[str] = FieldInfo(alias="retryAfter", default=None) + """ + Suggested duration to wait before retrying. Only meaningful when retriable is + true. + """ + + +class StatusFailure(BaseModel): + """ + WorkflowError provides structured error information for workflow failures. + This enables the reconciler to make informed retry decisions and the frontend + to display actionable error messages. + """ + + code: Optional[ + Literal[ + "WORKFLOW_ERROR_CODE_UNSPECIFIED", + "WORKFLOW_ERROR_CODE_ENVIRONMENT_ERROR", + "WORKFLOW_ERROR_CODE_AGENT_ERROR", + ] + ] = None + """Error code identifying the type of error.""" + + message: Optional[str] = None + """Human-readable error message.""" + + meta: Optional[Dict[str, str]] = None + """Additional metadata about the error. Common keys include: + + - environment_id: ID of the environment + - task_id: ID of the task + - service_id: ID of the service + - workflow_id: ID of the workflow + - workflow_execution_id: ID of the workflow execution + """ + + reason: Optional[str] = None + """ + Reason explaining why the error occurred. Examples: "not_found", "stopped", + "deleted", "creation_failed", "start_failed" + """ + + retry: Optional[StatusFailureRetry] = None + """Retry configuration. If not set, the error is considered non-retriable.""" + + +class StatusStepStatusErrorRetry(BaseModel): + """Retry configuration. If not set, the error is considered non-retriable.""" + + retriable: Optional[bool] = None + """Whether the error is retriable.""" + + retry_after: Optional[str] = FieldInfo(alias="retryAfter", default=None) + """ + Suggested duration to wait before retrying. Only meaningful when retriable is + true. + """ + + +class StatusStepStatusError(BaseModel): + """ + Structured error that caused the step to fail. + Provides detailed error code, message, and retry information. + """ + + code: Optional[ + Literal[ + "WORKFLOW_ERROR_CODE_UNSPECIFIED", + "WORKFLOW_ERROR_CODE_ENVIRONMENT_ERROR", + "WORKFLOW_ERROR_CODE_AGENT_ERROR", + ] + ] = None + """Error code identifying the type of error.""" + + message: Optional[str] = None + """Human-readable error message.""" + + meta: Optional[Dict[str, str]] = None + """Additional metadata about the error. Common keys include: + + - environment_id: ID of the environment + - task_id: ID of the task + - service_id: ID of the service + - workflow_id: ID of the workflow + - workflow_execution_id: ID of the workflow execution + """ + + reason: Optional[str] = None + """ + Reason explaining why the error occurred. Examples: "not_found", "stopped", + "deleted", "creation_failed", "start_failed" + """ + + retry: Optional[StatusStepStatusErrorRetry] = None + """Retry configuration. If not set, the error is considered non-retriable.""" + + +class StatusStepStatus(BaseModel): + """ + WorkflowExecutionActionStepStatus represents the status of a single step execution. + """ + + error: Optional[StatusStepStatusError] = None + """ + Structured error that caused the step to fail. Provides detailed error code, + message, and retry information. + """ + + finished_at: Optional[datetime] = FieldInfo(alias="finishedAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + phase: Optional[ + Literal[ + "STEP_PHASE_UNSPECIFIED", + "STEP_PHASE_PENDING", + "STEP_PHASE_RUNNING", + "STEP_PHASE_DONE", + "STEP_PHASE_FAILED", + "STEP_PHASE_CANCELLED", + ] + ] = None + + started_at: Optional[datetime] = FieldInfo(alias="startedAt", default=None) + """ + A Timestamp represents a point in time independent of any time zone or local + calendar, encoded as a count of seconds and fractions of seconds at nanosecond + resolution. The count is relative to an epoch at UTC midnight on January 1, + 1970, in the proleptic Gregorian calendar which extends the Gregorian calendar + backwards to year one. + + All minutes are 60 seconds long. Leap seconds are "smeared" so that no leap + second table is needed for interpretation, using a + [24-hour linear smear](https://developers.google.com/time/smear). + + The range is from 0001-01-01T00:00:00Z to 9999-12-31T23:59:59.999999999Z. By + restricting to that range, we ensure that we can convert to and from + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) date strings. + + # Examples + + Example 1: Compute Timestamp from POSIX `time()`. + + Timestamp timestamp; + timestamp.set_seconds(time(NULL)); + timestamp.set_nanos(0); + + Example 2: Compute Timestamp from POSIX `gettimeofday()`. + + struct timeval tv; + gettimeofday(&tv, NULL); + + Timestamp timestamp; + timestamp.set_seconds(tv.tv_sec); + timestamp.set_nanos(tv.tv_usec * 1000); + + Example 3: Compute Timestamp from Win32 `GetSystemTimeAsFileTime()`. + + FILETIME ft; + GetSystemTimeAsFileTime(&ft); + UINT64 ticks = (((UINT64)ft.dwHighDateTime) << 32) | ft.dwLowDateTime; + + // A Windows tick is 100 nanoseconds. Windows epoch 1601-01-01T00:00:00Z + // is 11644473600 seconds before Unix epoch 1970-01-01T00:00:00Z. + Timestamp timestamp; + timestamp.set_seconds((INT64) ((ticks / 10000000) - 11644473600LL)); + timestamp.set_nanos((INT32) ((ticks % 10000000) * 100)); + + Example 4: Compute Timestamp from Java `System.currentTimeMillis()`. + + long millis = System.currentTimeMillis(); + + Timestamp timestamp = Timestamp.newBuilder().setSeconds(millis / 1000) + .setNanos((int) ((millis % 1000) * 1000000)).build(); + + Example 5: Compute Timestamp from Java `Instant.now()`. + + Instant now = Instant.now(); + + Timestamp timestamp = + Timestamp.newBuilder().setSeconds(now.getEpochSecond()) + .setNanos(now.getNano()).build(); + + Example 6: Compute Timestamp from current time in Python. + + timestamp = Timestamp() + timestamp.GetCurrentTime() + + # JSON Mapping + + In JSON format, the Timestamp type is encoded as a string in the + [RFC 3339](https://www.ietf.org/rfc/rfc3339.txt) format. That is, the format is + "{year}-{month}-{day}T{hour}:{min}:{sec}[.{frac_sec}]Z" where {year} is always + expressed using four digits while {month}, {day}, {hour}, {min}, and {sec} are + zero-padded to two digits each. The fractional seconds, which can go up to 9 + digits (i.e. up to 1 nanosecond resolution), are optional. The "Z" suffix + indicates the timezone ("UTC"); the timezone is required. A proto3 JSON + serializer should always use UTC (as indicated by "Z") when printing the + Timestamp type and a proto3 JSON parser should be able to accept both UTC and + other timezones (as indicated by an offset). + + For example, "2017-01-15T01:30:15.01Z" encodes 15.01 seconds past 01:30 UTC on + January 15, 2017. + + In JavaScript, one can convert a Date object to this format using the standard + [toISOString()](https://developer.mozilla.org/en-US/docs/Web/JavaScript/Reference/Global_Objects/Date/toISOString) + method. In Python, a standard `datetime.datetime` object can be converted to + this format using + [`strftime`](https://docs.python.org/2/library/time.html#time.strftime) with the + time format spec '%Y-%m-%dT%H:%M:%S.%fZ'. Likewise, in Java, one can use the + Joda Time's + [`ISODateTimeFormat.dateTime()`]() + to obtain a formatter capable of generating timestamps in this format. + """ + + step: Optional[WorkflowStep] = None + """ + The step definition captured at execution time for immutability. This ensures + the UI shows the correct step even if the workflow definition changes. + """ + + step_index: Optional[int] = FieldInfo(alias="stepIndex", default=None) + """Index of the step in the workflow action steps array""" + + +class StatusWarningRetry(BaseModel): + """Retry configuration. If not set, the error is considered non-retriable.""" + + retriable: Optional[bool] = None + """Whether the error is retriable.""" + + retry_after: Optional[str] = FieldInfo(alias="retryAfter", default=None) + """ + Suggested duration to wait before retrying. Only meaningful when retriable is + true. + """ + + +class StatusWarning(BaseModel): + """ + WorkflowError provides structured error information for workflow failures. + This enables the reconciler to make informed retry decisions and the frontend + to display actionable error messages. + """ + + code: Optional[ + Literal[ + "WORKFLOW_ERROR_CODE_UNSPECIFIED", + "WORKFLOW_ERROR_CODE_ENVIRONMENT_ERROR", + "WORKFLOW_ERROR_CODE_AGENT_ERROR", + ] + ] = None + """Error code identifying the type of error.""" + + message: Optional[str] = None + """Human-readable error message.""" + + meta: Optional[Dict[str, str]] = None + """Additional metadata about the error. Common keys include: + + - environment_id: ID of the environment + - task_id: ID of the task + - service_id: ID of the service + - workflow_id: ID of the workflow + - workflow_execution_id: ID of the workflow execution + """ + + reason: Optional[str] = None + """ + Reason explaining why the error occurred. Examples: "not_found", "stopped", + "deleted", "creation_failed", "start_failed" + """ + + retry: Optional[StatusWarningRetry] = None + """Retry configuration. If not set, the error is considered non-retriable.""" + + +class Status(BaseModel): + """ + WorkflowExecutionActionStatus contains the current status of a workflow execution action. + """ + + agent_execution_id: Optional[str] = FieldInfo(alias="agentExecutionId", default=None) + + environment_id: Optional[str] = FieldInfo(alias="environmentId", default=None) + + failures: Optional[List[StatusFailure]] = None + """ + Structured failures that caused the workflow execution action to fail. Provides + detailed error codes, messages, and retry information. + """ + + phase: Optional[ + Literal[ + "WORKFLOW_EXECUTION_ACTION_PHASE_UNSPECIFIED", + "WORKFLOW_EXECUTION_ACTION_PHASE_PENDING", + "WORKFLOW_EXECUTION_ACTION_PHASE_RUNNING", + "WORKFLOW_EXECUTION_ACTION_PHASE_STOPPING", + "WORKFLOW_EXECUTION_ACTION_PHASE_STOPPED", + "WORKFLOW_EXECUTION_ACTION_PHASE_DELETING", + "WORKFLOW_EXECUTION_ACTION_PHASE_DELETED", + "WORKFLOW_EXECUTION_ACTION_PHASE_DONE", + ] + ] = None + """WorkflowExecutionActionPhase defines the phases of workflow execution action.""" + + step_statuses: Optional[List[StatusStepStatus]] = FieldInfo(alias="stepStatuses", default=None) + """Step-level progress tracking""" + + warnings: Optional[List[StatusWarning]] = None + """ + Structured warnings about the workflow execution action. Provides detailed + warning codes and messages. + """ + + +class WorkflowExecutionAction(BaseModel): + """WorkflowExecutionAction represents a workflow execution action instance.""" + + id: Optional[str] = None + + metadata: Optional[Metadata] = None + """WorkflowExecutionActionMetadata contains workflow execution action metadata.""" + + spec: Optional[Spec] = None + """ + WorkflowExecutionActionSpec contains the specification for this execution + action. + """ + + status: Optional[Status] = None + """ + WorkflowExecutionActionStatus contains the current status of a workflow + execution action. + """ diff --git a/src/gitpod/types/workflow_step.py b/src/gitpod/types/workflow_step.py new file mode 100644 index 00000000..c1871e0e --- /dev/null +++ b/src/gitpod/types/workflow_step.py @@ -0,0 +1,92 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import List, Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel + +__all__ = ["WorkflowStep", "Agent", "PullRequest", "Report", "ReportOutput", "Task"] + + +class Agent(BaseModel): + """WorkflowAgentStep represents an agent step that executes with a prompt.""" + + prompt: Optional[str] = None + """Prompt must be between 1 and 20,000 characters: + + ``` + size(this) >= 1 && size(this) <= 20000 + ``` + """ + + +class PullRequest(BaseModel): + """WorkflowPullRequestStep represents a pull request creation step.""" + + branch: Optional[str] = None + """Branch name must be between 1 and 255 characters: + + ``` + size(this) >= 1 && size(this) <= 255 + ``` + """ + + description: Optional[str] = None + """Description must be at most 20,000 characters: + + ``` + size(this) <= 20000 + ``` + """ + + draft: Optional[bool] = None + + title: Optional[str] = None + """Title must be between 1 and 500 characters: + + ``` + size(this) >= 1 && size(this) <= 500 + ``` + """ + + +class ReportOutput: + pass + + +class Report(BaseModel): + outputs: Optional[List[ReportOutput]] = None + """Report must have at least one output: + + ``` + size(this) >= 1 + ``` + """ + + +class Task(BaseModel): + """WorkflowTaskStep represents a task step that executes a command.""" + + command: Optional[str] = None + """Command must be between 1 and 20,000 characters: + + ``` + size(this) >= 1 && size(this) <= 20000 + ``` + """ + + +class WorkflowStep(BaseModel): + """WorkflowStep defines a single step in a workflow action.""" + + agent: Optional[Agent] = None + """WorkflowAgentStep represents an agent step that executes with a prompt.""" + + pull_request: Optional[PullRequest] = FieldInfo(alias="pullRequest", default=None) + """WorkflowPullRequestStep represents a pull request creation step.""" + + report: Optional[Report] = None + + task: Optional[Task] = None + """WorkflowTaskStep represents a task step that executes a command.""" diff --git a/src/gitpod/types/workflow_step_param.py b/src/gitpod/types/workflow_step_param.py new file mode 100644 index 00000000..35365d5b --- /dev/null +++ b/src/gitpod/types/workflow_step_param.py @@ -0,0 +1,93 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import Iterable +from typing_extensions import Annotated, TypedDict + +from .._utils import PropertyInfo + +__all__ = ["WorkflowStepParam", "Agent", "PullRequest", "Report", "ReportOutput", "Task"] + + +class Agent(TypedDict, total=False): + """WorkflowAgentStep represents an agent step that executes with a prompt.""" + + prompt: str + """Prompt must be between 1 and 20,000 characters: + + ``` + size(this) >= 1 && size(this) <= 20000 + ``` + """ + + +class PullRequest(TypedDict, total=False): + """WorkflowPullRequestStep represents a pull request creation step.""" + + branch: str + """Branch name must be between 1 and 255 characters: + + ``` + size(this) >= 1 && size(this) <= 255 + ``` + """ + + description: str + """Description must be at most 20,000 characters: + + ``` + size(this) <= 20000 + ``` + """ + + draft: bool + + title: str + """Title must be between 1 and 500 characters: + + ``` + size(this) >= 1 && size(this) <= 500 + ``` + """ + + +class ReportOutput(total=False): + pass + + +class Report(TypedDict, total=False): + outputs: Iterable[ReportOutput] + """Report must have at least one output: + + ``` + size(this) >= 1 + ``` + """ + + +class Task(TypedDict, total=False): + """WorkflowTaskStep represents a task step that executes a command.""" + + command: str + """Command must be between 1 and 20,000 characters: + + ``` + size(this) >= 1 && size(this) <= 20000 + ``` + """ + + +class WorkflowStepParam(TypedDict, total=False): + """WorkflowStep defines a single step in a workflow action.""" + + agent: Agent + """WorkflowAgentStep represents an agent step that executes with a prompt.""" + + pull_request: Annotated[PullRequest, PropertyInfo(alias="pullRequest")] + """WorkflowPullRequestStep represents a pull request creation step.""" + + report: Report + + task: Task + """WorkflowTaskStep represents a task step that executes a command.""" diff --git a/src/gitpod/types/workflow_trigger.py b/src/gitpod/types/workflow_trigger.py new file mode 100644 index 00000000..4b044761 --- /dev/null +++ b/src/gitpod/types/workflow_trigger.py @@ -0,0 +1,105 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import List, Optional +from typing_extensions import Literal + +from pydantic import Field as FieldInfo + +from .._models import BaseModel +from .workflow_trigger_context import WorkflowTriggerContext + +__all__ = ["WorkflowTrigger", "PullRequest", "Time"] + + +class PullRequest(BaseModel): + """ + Pull request trigger - executed when specified PR events occur. + Only triggers for PRs in repositories matching the trigger context. + """ + + events: Optional[ + List[ + Literal[ + "PULL_REQUEST_EVENT_UNSPECIFIED", + "PULL_REQUEST_EVENT_OPENED", + "PULL_REQUEST_EVENT_UPDATED", + "PULL_REQUEST_EVENT_APPROVED", + "PULL_REQUEST_EVENT_MERGED", + "PULL_REQUEST_EVENT_CLOSED", + "PULL_REQUEST_EVENT_READY_FOR_REVIEW", + ] + ] + ] = None + + webhook_id: Optional[str] = FieldInfo(alias="webhookId", default=None) + """ + webhook_id is the optional ID of a webhook that this trigger is bound to. When + set, the trigger will be activated when the webhook receives events. This allows + multiple workflows to share a single webhook endpoint. + """ + + +class Time(BaseModel): + """ + Time-based trigger - executed automatically based on cron schedule. + Uses standard cron expression format (minute hour day month weekday). + """ + + cron_expression: Optional[str] = FieldInfo(alias="cronExpression", default=None) + """Cron expression must be between 1 and 100 characters: + + ``` + size(this) >= 1 && size(this) <= 100 + ``` + """ + + +class WorkflowTrigger(BaseModel): + """WorkflowTrigger defines when a workflow should be executed. + + Each trigger type defines a specific condition that will cause the workflow to execute: + - Manual: Triggered explicitly by user action via StartWorkflow RPC + - Time: Triggered automatically based on cron schedule + - PullRequest: Triggered automatically when specified PR events occur + + Trigger Semantics: + - Each trigger instance can create multiple workflow executions + - Multiple triggers of the same workflow can fire simultaneously + - Each trigger execution is independent and tracked separately + - Triggers are evaluated in the context specified by WorkflowTriggerContext + """ + + context: WorkflowTriggerContext + """WorkflowTriggerContext defines the context in which a workflow should run. + + Context determines where and how the workflow executes: + + - Projects: Execute in specific project environments + - Repositories: Execute in environments created from repository URLs + - Agent: Execute in agent-managed environments with custom prompts + - FromTrigger: Use context derived from the trigger event (PR-specific) + + Context Usage by Trigger Type: + + - Manual: Can use any context type + - Time: Typically uses Projects or Repositories context + - PullRequest: Can use any context, FromTrigger uses PR repository context + """ + + manual: Optional[object] = None + """ + Manual trigger - executed when StartWorkflow RPC is called. No additional + configuration needed. + """ + + pull_request: Optional[PullRequest] = FieldInfo(alias="pullRequest", default=None) + """ + Pull request trigger - executed when specified PR events occur. Only triggers + for PRs in repositories matching the trigger context. + """ + + time: Optional[Time] = None + """ + Time-based trigger - executed automatically based on cron schedule. Uses + standard cron expression format (minute hour day month weekday). + """ diff --git a/src/gitpod/types/workflow_trigger_context.py b/src/gitpod/types/workflow_trigger_context.py new file mode 100644 index 00000000..6d82400e --- /dev/null +++ b/src/gitpod/types/workflow_trigger_context.py @@ -0,0 +1,130 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from typing import List, Optional + +from pydantic import Field as FieldInfo + +from .._models import BaseModel + +__all__ = [ + "WorkflowTriggerContext", + "Agent", + "Projects", + "Repositories", + "RepositoriesRepoSelector", + "RepositoriesRepositoryURLs", +] + + +class Agent(BaseModel): + """ + Execute workflow in agent-managed environments. + Agent receives the specified prompt and manages execution context. + """ + + prompt: Optional[str] = None + """Agent prompt must be between 1 and 20,000 characters: + + ``` + size(this) >= 1 && size(this) <= 20000 + ``` + """ + + +class Projects(BaseModel): + """ + Execute workflow in specific project environments. + Creates environments for each specified project. + """ + + project_ids: Optional[List[str]] = FieldInfo(alias="projectIds", default=None) + + +class RepositoriesRepoSelector(BaseModel): + """ + RepositorySelector defines how to select repositories for workflow execution. + Combines a search string with an SCM host to identify repositories. + """ + + repo_search_string: Optional[str] = FieldInfo(alias="repoSearchString", default=None) + """ + Search string to match repositories using SCM-specific search patterns. For + GitHub: supports GitHub search syntax (e.g., "org:gitpod-io language:go", + "user:octocat stars:>100") For GitLab: supports GitLab search syntax See SCM + provider documentation for supported search patterns. + """ + + scm_host: Optional[str] = FieldInfo(alias="scmHost", default=None) + """ + SCM host where the search should be performed (e.g., "github.com", "gitlab.com") + """ + + +class RepositoriesRepositoryURLs(BaseModel): + """ + RepositoryURLs contains a list of explicit repository URLs. + Creates one action per repository URL. + """ + + repo_urls: Optional[List[str]] = FieldInfo(alias="repoUrls", default=None) + + +class Repositories(BaseModel): + """ + Execute workflow in environments created from repository URLs. + Supports both explicit repository URLs and search patterns. + """ + + environment_class_id: Optional[str] = FieldInfo(alias="environmentClassId", default=None) + + repo_selector: Optional[RepositoriesRepoSelector] = FieldInfo(alias="repoSelector", default=None) + """ + RepositorySelector defines how to select repositories for workflow execution. + Combines a search string with an SCM host to identify repositories. + """ + + repository_urls: Optional[RepositoriesRepositoryURLs] = FieldInfo(alias="repositoryUrls", default=None) + """ + RepositoryURLs contains a list of explicit repository URLs. Creates one action + per repository URL. + """ + + +class WorkflowTriggerContext(BaseModel): + """WorkflowTriggerContext defines the context in which a workflow should run. + + Context determines where and how the workflow executes: + - Projects: Execute in specific project environments + - Repositories: Execute in environments created from repository URLs + - Agent: Execute in agent-managed environments with custom prompts + - FromTrigger: Use context derived from the trigger event (PR-specific) + + Context Usage by Trigger Type: + - Manual: Can use any context type + - Time: Typically uses Projects or Repositories context + - PullRequest: Can use any context, FromTrigger uses PR repository context + """ + + agent: Optional[Agent] = None + """ + Execute workflow in agent-managed environments. Agent receives the specified + prompt and manages execution context. + """ + + from_trigger: Optional[object] = FieldInfo(alias="fromTrigger", default=None) + """ + Use context derived from the trigger event. Currently only supported for + PullRequest triggers - uses PR repository context. + """ + + projects: Optional[Projects] = None + """ + Execute workflow in specific project environments. Creates environments for each + specified project. + """ + + repositories: Optional[Repositories] = None + """ + Execute workflow in environments created from repository URLs. Supports both + explicit repository URLs and search patterns. + """ diff --git a/src/gitpod/types/workflow_trigger_context_param.py b/src/gitpod/types/workflow_trigger_context_param.py new file mode 100644 index 00000000..4ebb2e49 --- /dev/null +++ b/src/gitpod/types/workflow_trigger_context_param.py @@ -0,0 +1,131 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing_extensions import Annotated, TypedDict + +from .._types import SequenceNotStr +from .._utils import PropertyInfo + +__all__ = [ + "WorkflowTriggerContextParam", + "Agent", + "Projects", + "Repositories", + "RepositoriesRepoSelector", + "RepositoriesRepositoryURLs", +] + + +class Agent(TypedDict, total=False): + """ + Execute workflow in agent-managed environments. + Agent receives the specified prompt and manages execution context. + """ + + prompt: str + """Agent prompt must be between 1 and 20,000 characters: + + ``` + size(this) >= 1 && size(this) <= 20000 + ``` + """ + + +class Projects(TypedDict, total=False): + """ + Execute workflow in specific project environments. + Creates environments for each specified project. + """ + + project_ids: Annotated[SequenceNotStr[str], PropertyInfo(alias="projectIds")] + + +class RepositoriesRepoSelector(TypedDict, total=False): + """ + RepositorySelector defines how to select repositories for workflow execution. + Combines a search string with an SCM host to identify repositories. + """ + + repo_search_string: Annotated[str, PropertyInfo(alias="repoSearchString")] + """ + Search string to match repositories using SCM-specific search patterns. For + GitHub: supports GitHub search syntax (e.g., "org:gitpod-io language:go", + "user:octocat stars:>100") For GitLab: supports GitLab search syntax See SCM + provider documentation for supported search patterns. + """ + + scm_host: Annotated[str, PropertyInfo(alias="scmHost")] + """ + SCM host where the search should be performed (e.g., "github.com", "gitlab.com") + """ + + +class RepositoriesRepositoryURLs(TypedDict, total=False): + """ + RepositoryURLs contains a list of explicit repository URLs. + Creates one action per repository URL. + """ + + repo_urls: Annotated[SequenceNotStr[str], PropertyInfo(alias="repoUrls")] + + +class Repositories(TypedDict, total=False): + """ + Execute workflow in environments created from repository URLs. + Supports both explicit repository URLs and search patterns. + """ + + environment_class_id: Annotated[str, PropertyInfo(alias="environmentClassId")] + + repo_selector: Annotated[RepositoriesRepoSelector, PropertyInfo(alias="repoSelector")] + """ + RepositorySelector defines how to select repositories for workflow execution. + Combines a search string with an SCM host to identify repositories. + """ + + repository_urls: Annotated[RepositoriesRepositoryURLs, PropertyInfo(alias="repositoryUrls")] + """ + RepositoryURLs contains a list of explicit repository URLs. Creates one action + per repository URL. + """ + + +class WorkflowTriggerContextParam(TypedDict, total=False): + """WorkflowTriggerContext defines the context in which a workflow should run. + + Context determines where and how the workflow executes: + - Projects: Execute in specific project environments + - Repositories: Execute in environments created from repository URLs + - Agent: Execute in agent-managed environments with custom prompts + - FromTrigger: Use context derived from the trigger event (PR-specific) + + Context Usage by Trigger Type: + - Manual: Can use any context type + - Time: Typically uses Projects or Repositories context + - PullRequest: Can use any context, FromTrigger uses PR repository context + """ + + agent: Agent + """ + Execute workflow in agent-managed environments. Agent receives the specified + prompt and manages execution context. + """ + + from_trigger: Annotated[object, PropertyInfo(alias="fromTrigger")] + """ + Use context derived from the trigger event. Currently only supported for + PullRequest triggers - uses PR repository context. + """ + + projects: Projects + """ + Execute workflow in specific project environments. Creates environments for each + specified project. + """ + + repositories: Repositories + """ + Execute workflow in environments created from repository URLs. Supports both + explicit repository URLs and search patterns. + """ diff --git a/src/gitpod/types/workflow_trigger_param.py b/src/gitpod/types/workflow_trigger_param.py new file mode 100644 index 00000000..ed28c9f8 --- /dev/null +++ b/src/gitpod/types/workflow_trigger_param.py @@ -0,0 +1,103 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +from typing import List, Optional +from typing_extensions import Literal, Required, Annotated, TypedDict + +from .._utils import PropertyInfo +from .workflow_trigger_context_param import WorkflowTriggerContextParam + +__all__ = ["WorkflowTriggerParam", "PullRequest", "Time"] + + +class PullRequest(TypedDict, total=False): + """ + Pull request trigger - executed when specified PR events occur. + Only triggers for PRs in repositories matching the trigger context. + """ + + events: List[ + Literal[ + "PULL_REQUEST_EVENT_UNSPECIFIED", + "PULL_REQUEST_EVENT_OPENED", + "PULL_REQUEST_EVENT_UPDATED", + "PULL_REQUEST_EVENT_APPROVED", + "PULL_REQUEST_EVENT_MERGED", + "PULL_REQUEST_EVENT_CLOSED", + "PULL_REQUEST_EVENT_READY_FOR_REVIEW", + ] + ] + + webhook_id: Annotated[Optional[str], PropertyInfo(alias="webhookId")] + """ + webhook_id is the optional ID of a webhook that this trigger is bound to. When + set, the trigger will be activated when the webhook receives events. This allows + multiple workflows to share a single webhook endpoint. + """ + + +class Time(TypedDict, total=False): + """ + Time-based trigger - executed automatically based on cron schedule. + Uses standard cron expression format (minute hour day month weekday). + """ + + cron_expression: Annotated[str, PropertyInfo(alias="cronExpression")] + """Cron expression must be between 1 and 100 characters: + + ``` + size(this) >= 1 && size(this) <= 100 + ``` + """ + + +class WorkflowTriggerParam(TypedDict, total=False): + """WorkflowTrigger defines when a workflow should be executed. + + Each trigger type defines a specific condition that will cause the workflow to execute: + - Manual: Triggered explicitly by user action via StartWorkflow RPC + - Time: Triggered automatically based on cron schedule + - PullRequest: Triggered automatically when specified PR events occur + + Trigger Semantics: + - Each trigger instance can create multiple workflow executions + - Multiple triggers of the same workflow can fire simultaneously + - Each trigger execution is independent and tracked separately + - Triggers are evaluated in the context specified by WorkflowTriggerContext + """ + + context: Required[WorkflowTriggerContextParam] + """WorkflowTriggerContext defines the context in which a workflow should run. + + Context determines where and how the workflow executes: + + - Projects: Execute in specific project environments + - Repositories: Execute in environments created from repository URLs + - Agent: Execute in agent-managed environments with custom prompts + - FromTrigger: Use context derived from the trigger event (PR-specific) + + Context Usage by Trigger Type: + + - Manual: Can use any context type + - Time: Typically uses Projects or Repositories context + - PullRequest: Can use any context, FromTrigger uses PR repository context + """ + + manual: object + """ + Manual trigger - executed when StartWorkflow RPC is called. No additional + configuration needed. + """ + + pull_request: Annotated[PullRequest, PropertyInfo(alias="pullRequest")] + """ + Pull request trigger - executed when specified PR events occur. Only triggers + for PRs in repositories matching the trigger context. + """ + + time: Time + """ + Time-based trigger - executed automatically based on cron schedule. Uses + standard cron expression format (minute hour day month weekday). + """ diff --git a/tests/api_resources/environments/automations/tasks/test_executions.py b/tests/api_resources/environments/automations/tasks/test_executions.py index f4d55beb..1d5a2732 100644 --- a/tests/api_resources/environments/automations/tasks/test_executions.py +++ b/tests/api_resources/environments/automations/tasks/test_executions.py @@ -21,13 +21,13 @@ class TestExecutions: 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_retrieve(self, client: Gitpod) -> None: execution = client.environments.automations.tasks.executions.retrieve() assert_matches_type(ExecutionRetrieveResponse, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: execution = client.environments.automations.tasks.executions.retrieve( @@ -35,7 +35,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ExecutionRetrieveResponse, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.environments.automations.tasks.executions.with_raw_response.retrieve() @@ -45,7 +45,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: execution = response.parse() assert_matches_type(ExecutionRetrieveResponse, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.environments.automations.tasks.executions.with_streaming_response.retrieve() as response: @@ -57,13 +57,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: execution = client.environments.automations.tasks.executions.list() assert_matches_type(SyncTaskExecutionsPage[TaskExecution], execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: execution = client.environments.automations.tasks.executions.list( @@ -82,7 +82,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncTaskExecutionsPage[TaskExecution], execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.environments.automations.tasks.executions.with_raw_response.list() @@ -92,7 +92,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: execution = response.parse() assert_matches_type(SyncTaskExecutionsPage[TaskExecution], execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.environments.automations.tasks.executions.with_streaming_response.list() as response: @@ -104,13 +104,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_stop(self, client: Gitpod) -> None: execution = client.environments.automations.tasks.executions.stop() assert_matches_type(object, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_stop_with_all_params(self, client: Gitpod) -> None: execution = client.environments.automations.tasks.executions.stop( @@ -118,7 +118,7 @@ def test_method_stop_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_stop(self, client: Gitpod) -> None: response = client.environments.automations.tasks.executions.with_raw_response.stop() @@ -128,7 +128,7 @@ def test_raw_response_stop(self, client: Gitpod) -> None: execution = response.parse() assert_matches_type(object, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_stop(self, client: Gitpod) -> None: with client.environments.automations.tasks.executions.with_streaming_response.stop() as response: @@ -146,13 +146,13 @@ class TestAsyncExecutions: "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_retrieve(self, async_client: AsyncGitpod) -> None: execution = await async_client.environments.automations.tasks.executions.retrieve() assert_matches_type(ExecutionRetrieveResponse, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: execution = await async_client.environments.automations.tasks.executions.retrieve( @@ -160,7 +160,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(ExecutionRetrieveResponse, execution, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.executions.with_raw_response.retrieve() @@ -170,7 +170,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: execution = await response.parse() assert_matches_type(ExecutionRetrieveResponse, execution, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with ( @@ -184,13 +184,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_list(self, async_client: AsyncGitpod) -> None: execution = await async_client.environments.automations.tasks.executions.list() assert_matches_type(AsyncTaskExecutionsPage[TaskExecution], execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: execution = await async_client.environments.automations.tasks.executions.list( @@ -209,7 +209,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncTaskExecutionsPage[TaskExecution], execution, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.executions.with_raw_response.list() @@ -219,7 +219,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: execution = await response.parse() assert_matches_type(AsyncTaskExecutionsPage[TaskExecution], execution, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.executions.with_streaming_response.list() as response: @@ -231,13 +231,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_stop(self, async_client: AsyncGitpod) -> None: execution = await async_client.environments.automations.tasks.executions.stop() assert_matches_type(object, execution, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_stop_with_all_params(self, async_client: AsyncGitpod) -> None: execution = await async_client.environments.automations.tasks.executions.stop( @@ -245,7 +245,7 @@ async def test_method_stop_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(object, execution, 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_stop(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.executions.with_raw_response.stop() @@ -255,7 +255,7 @@ async def test_raw_response_stop(self, async_client: AsyncGitpod) -> None: execution = await response.parse() assert_matches_type(object, execution, 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_stop(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.executions.with_streaming_response.stop() as response: diff --git a/tests/api_resources/environments/automations/test_services.py b/tests/api_resources/environments/automations/test_services.py index c0db2dcd..3d1ccf73 100644 --- a/tests/api_resources/environments/automations/test_services.py +++ b/tests/api_resources/environments/automations/test_services.py @@ -23,13 +23,13 @@ class TestServices: 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_create(self, client: Gitpod) -> None: service = client.environments.automations.services.create() assert_matches_type(ServiceCreateResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: service = client.environments.automations.services.create( @@ -82,7 +82,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ServiceCreateResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.environments.automations.services.with_raw_response.create() @@ -92,7 +92,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: service = response.parse() assert_matches_type(ServiceCreateResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.environments.automations.services.with_streaming_response.create() as response: @@ -104,13 +104,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: service = client.environments.automations.services.retrieve() assert_matches_type(ServiceRetrieveResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: service = client.environments.automations.services.retrieve( @@ -118,7 +118,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ServiceRetrieveResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.environments.automations.services.with_raw_response.retrieve() @@ -128,7 +128,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: service = response.parse() assert_matches_type(ServiceRetrieveResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.environments.automations.services.with_streaming_response.retrieve() as response: @@ -140,13 +140,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: service = client.environments.automations.services.update() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: service = client.environments.automations.services.update( @@ -199,7 +199,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.environments.automations.services.with_raw_response.update() @@ -209,7 +209,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: service = response.parse() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.environments.automations.services.with_streaming_response.update() as response: @@ -221,13 +221,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: service = client.environments.automations.services.list() assert_matches_type(SyncServicesPage[Service], service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: service = client.environments.automations.services.list( @@ -246,7 +246,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncServicesPage[Service], service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.environments.automations.services.with_raw_response.list() @@ -256,7 +256,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: service = response.parse() assert_matches_type(SyncServicesPage[Service], service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.environments.automations.services.with_streaming_response.list() as response: @@ -268,13 +268,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: service = client.environments.automations.services.delete() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: service = client.environments.automations.services.delete( @@ -283,7 +283,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.environments.automations.services.with_raw_response.delete() @@ -293,7 +293,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: service = response.parse() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.environments.automations.services.with_streaming_response.delete() as response: @@ -305,13 +305,13 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_start(self, client: Gitpod) -> None: service = client.environments.automations.services.start() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_start_with_all_params(self, client: Gitpod) -> None: service = client.environments.automations.services.start( @@ -319,7 +319,7 @@ def test_method_start_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_start(self, client: Gitpod) -> None: response = client.environments.automations.services.with_raw_response.start() @@ -329,7 +329,7 @@ def test_raw_response_start(self, client: Gitpod) -> None: service = response.parse() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_start(self, client: Gitpod) -> None: with client.environments.automations.services.with_streaming_response.start() as response: @@ -341,13 +341,13 @@ def test_streaming_response_start(self, client: Gitpod) -> 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_stop(self, client: Gitpod) -> None: service = client.environments.automations.services.stop() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_stop_with_all_params(self, client: Gitpod) -> None: service = client.environments.automations.services.stop( @@ -355,7 +355,7 @@ def test_method_stop_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_stop(self, client: Gitpod) -> None: response = client.environments.automations.services.with_raw_response.stop() @@ -365,7 +365,7 @@ def test_raw_response_stop(self, client: Gitpod) -> None: service = response.parse() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_stop(self, client: Gitpod) -> None: with client.environments.automations.services.with_streaming_response.stop() as response: @@ -383,13 +383,13 @@ class TestAsyncServices: "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_create(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.create() assert_matches_type(ServiceCreateResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.create( @@ -442,7 +442,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(ServiceCreateResponse, service, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.services.with_raw_response.create() @@ -452,7 +452,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: service = await response.parse() assert_matches_type(ServiceCreateResponse, service, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.services.with_streaming_response.create() as response: @@ -464,13 +464,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.retrieve() assert_matches_type(ServiceRetrieveResponse, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.retrieve( @@ -478,7 +478,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(ServiceRetrieveResponse, service, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.services.with_raw_response.retrieve() @@ -488,7 +488,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: service = await response.parse() assert_matches_type(ServiceRetrieveResponse, service, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.services.with_streaming_response.retrieve() as response: @@ -500,13 +500,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.update() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.update( @@ -559,7 +559,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, service, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.services.with_raw_response.update() @@ -569,7 +569,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: service = await response.parse() assert_matches_type(object, service, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.services.with_streaming_response.update() as response: @@ -581,13 +581,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.list() assert_matches_type(AsyncServicesPage[Service], service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.list( @@ -606,7 +606,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncServicesPage[Service], service, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.services.with_raw_response.list() @@ -616,7 +616,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: service = await response.parse() assert_matches_type(AsyncServicesPage[Service], service, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.services.with_streaming_response.list() as response: @@ -628,13 +628,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.delete() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.delete( @@ -643,7 +643,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, service, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.services.with_raw_response.delete() @@ -653,7 +653,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: service = await response.parse() assert_matches_type(object, service, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.services.with_streaming_response.delete() as response: @@ -665,13 +665,13 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_start(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.start() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_start_with_all_params(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.start( @@ -679,7 +679,7 @@ async def test_method_start_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, service, 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_start(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.services.with_raw_response.start() @@ -689,7 +689,7 @@ async def test_raw_response_start(self, async_client: AsyncGitpod) -> None: service = await response.parse() assert_matches_type(object, service, 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_start(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.services.with_streaming_response.start() as response: @@ -701,13 +701,13 @@ async def test_streaming_response_start(self, async_client: AsyncGitpod) -> 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 async def test_method_stop(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.stop() assert_matches_type(object, service, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_stop_with_all_params(self, async_client: AsyncGitpod) -> None: service = await async_client.environments.automations.services.stop( @@ -715,7 +715,7 @@ async def test_method_stop_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(object, service, 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_stop(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.services.with_raw_response.stop() @@ -725,7 +725,7 @@ async def test_raw_response_stop(self, async_client: AsyncGitpod) -> None: service = await response.parse() assert_matches_type(object, service, 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_stop(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.services.with_streaming_response.stop() as response: diff --git a/tests/api_resources/environments/automations/test_tasks.py b/tests/api_resources/environments/automations/test_tasks.py index 289d4f4c..242dc25e 100644 --- a/tests/api_resources/environments/automations/test_tasks.py +++ b/tests/api_resources/environments/automations/test_tasks.py @@ -24,13 +24,13 @@ class TestTasks: 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_create(self, client: Gitpod) -> None: task = client.environments.automations.tasks.create() assert_matches_type(TaskCreateResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: task = client.environments.automations.tasks.create( @@ -76,7 +76,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(TaskCreateResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.environments.automations.tasks.with_raw_response.create() @@ -86,7 +86,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: task = response.parse() assert_matches_type(TaskCreateResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.environments.automations.tasks.with_streaming_response.create() as response: @@ -98,13 +98,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: task = client.environments.automations.tasks.retrieve() assert_matches_type(TaskRetrieveResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: task = client.environments.automations.tasks.retrieve( @@ -112,7 +112,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(TaskRetrieveResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.environments.automations.tasks.with_raw_response.retrieve() @@ -122,7 +122,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: task = response.parse() assert_matches_type(TaskRetrieveResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.environments.automations.tasks.with_streaming_response.retrieve() as response: @@ -134,13 +134,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: task = client.environments.automations.tasks.update() assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: task = client.environments.automations.tasks.update( @@ -182,7 +182,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.environments.automations.tasks.with_raw_response.update() @@ -192,7 +192,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: task = response.parse() assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.environments.automations.tasks.with_streaming_response.update() as response: @@ -204,13 +204,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: task = client.environments.automations.tasks.list() assert_matches_type(SyncTasksPage[Task], task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: task = client.environments.automations.tasks.list( @@ -228,7 +228,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncTasksPage[Task], task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.environments.automations.tasks.with_raw_response.list() @@ -238,7 +238,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: task = response.parse() assert_matches_type(SyncTasksPage[Task], task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.environments.automations.tasks.with_streaming_response.list() as response: @@ -250,13 +250,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: task = client.environments.automations.tasks.delete() assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: task = client.environments.automations.tasks.delete( @@ -264,7 +264,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.environments.automations.tasks.with_raw_response.delete() @@ -274,7 +274,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: task = response.parse() assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.environments.automations.tasks.with_streaming_response.delete() as response: @@ -286,13 +286,13 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_start(self, client: Gitpod) -> None: task = client.environments.automations.tasks.start() assert_matches_type(TaskStartResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_start_with_all_params(self, client: Gitpod) -> None: task = client.environments.automations.tasks.start( @@ -300,7 +300,7 @@ def test_method_start_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(TaskStartResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_start(self, client: Gitpod) -> None: response = client.environments.automations.tasks.with_raw_response.start() @@ -310,7 +310,7 @@ def test_raw_response_start(self, client: Gitpod) -> None: task = response.parse() assert_matches_type(TaskStartResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_start(self, client: Gitpod) -> None: with client.environments.automations.tasks.with_streaming_response.start() as response: @@ -328,13 +328,13 @@ class TestAsyncTasks: "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_create(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.create() assert_matches_type(TaskCreateResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.create( @@ -380,7 +380,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(TaskCreateResponse, task, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.with_raw_response.create() @@ -390,7 +390,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: task = await response.parse() assert_matches_type(TaskCreateResponse, task, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.with_streaming_response.create() as response: @@ -402,13 +402,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.retrieve() assert_matches_type(TaskRetrieveResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.retrieve( @@ -416,7 +416,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(TaskRetrieveResponse, task, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.with_raw_response.retrieve() @@ -426,7 +426,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: task = await response.parse() assert_matches_type(TaskRetrieveResponse, task, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.with_streaming_response.retrieve() as response: @@ -438,13 +438,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.update() assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.update( @@ -486,7 +486,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, task, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.with_raw_response.update() @@ -496,7 +496,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: task = await response.parse() assert_matches_type(object, task, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.with_streaming_response.update() as response: @@ -508,13 +508,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.list() assert_matches_type(AsyncTasksPage[Task], task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.list( @@ -532,7 +532,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncTasksPage[Task], task, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.with_raw_response.list() @@ -542,7 +542,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: task = await response.parse() assert_matches_type(AsyncTasksPage[Task], task, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.with_streaming_response.list() as response: @@ -554,13 +554,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.delete() assert_matches_type(object, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.delete( @@ -568,7 +568,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, task, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.with_raw_response.delete() @@ -578,7 +578,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: task = await response.parse() assert_matches_type(object, task, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.with_streaming_response.delete() as response: @@ -590,13 +590,13 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_start(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.start() assert_matches_type(TaskStartResponse, task, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_start_with_all_params(self, async_client: AsyncGitpod) -> None: task = await async_client.environments.automations.tasks.start( @@ -604,7 +604,7 @@ async def test_method_start_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(TaskStartResponse, task, 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_start(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.tasks.with_raw_response.start() @@ -614,7 +614,7 @@ async def test_raw_response_start(self, async_client: AsyncGitpod) -> None: task = await response.parse() assert_matches_type(TaskStartResponse, task, 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_start(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.tasks.with_streaming_response.start() as response: diff --git a/tests/api_resources/environments/test_automations.py b/tests/api_resources/environments/test_automations.py index 8a1bfcfb..15f3fe3a 100644 --- a/tests/api_resources/environments/test_automations.py +++ b/tests/api_resources/environments/test_automations.py @@ -17,13 +17,13 @@ class TestAutomations: 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_upsert(self, client: Gitpod) -> None: automation = client.environments.automations.upsert() assert_matches_type(AutomationUpsertResponse, automation, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_upsert_with_all_params(self, client: Gitpod) -> None: automation = client.environments.automations.upsert( @@ -69,7 +69,7 @@ def test_method_upsert_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(AutomationUpsertResponse, automation, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_upsert(self, client: Gitpod) -> None: response = client.environments.automations.with_raw_response.upsert() @@ -79,7 +79,7 @@ def test_raw_response_upsert(self, client: Gitpod) -> None: automation = response.parse() assert_matches_type(AutomationUpsertResponse, automation, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_upsert(self, client: Gitpod) -> None: with client.environments.automations.with_streaming_response.upsert() as response: @@ -97,13 +97,13 @@ class TestAsyncAutomations: "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_upsert(self, async_client: AsyncGitpod) -> None: automation = await async_client.environments.automations.upsert() assert_matches_type(AutomationUpsertResponse, automation, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_upsert_with_all_params(self, async_client: AsyncGitpod) -> None: automation = await async_client.environments.automations.upsert( @@ -149,7 +149,7 @@ async def test_method_upsert_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(AutomationUpsertResponse, automation, 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_upsert(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.automations.with_raw_response.upsert() @@ -159,7 +159,7 @@ async def test_raw_response_upsert(self, async_client: AsyncGitpod) -> None: automation = await response.parse() assert_matches_type(AutomationUpsertResponse, automation, 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_upsert(self, async_client: AsyncGitpod) -> None: async with async_client.environments.automations.with_streaming_response.upsert() as response: diff --git a/tests/api_resources/environments/test_classes.py b/tests/api_resources/environments/test_classes.py index 9f70511b..03ca3bc0 100644 --- a/tests/api_resources/environments/test_classes.py +++ b/tests/api_resources/environments/test_classes.py @@ -18,13 +18,13 @@ class TestClasses: 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_list(self, client: Gitpod) -> None: class_ = client.environments.classes.list() assert_matches_type(SyncEnvironmentClassesPage[EnvironmentClass], class_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: class_ = client.environments.classes.list( @@ -44,7 +44,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncEnvironmentClassesPage[EnvironmentClass], class_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.environments.classes.with_raw_response.list() @@ -54,7 +54,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: class_ = response.parse() assert_matches_type(SyncEnvironmentClassesPage[EnvironmentClass], class_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.environments.classes.with_streaming_response.list() as response: @@ -72,13 +72,13 @@ class TestAsyncClasses: "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_list(self, async_client: AsyncGitpod) -> None: class_ = await async_client.environments.classes.list() assert_matches_type(AsyncEnvironmentClassesPage[EnvironmentClass], class_, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: class_ = await async_client.environments.classes.list( @@ -98,7 +98,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncEnvironmentClassesPage[EnvironmentClass], class_, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.classes.with_raw_response.list() @@ -108,7 +108,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: class_ = await response.parse() assert_matches_type(AsyncEnvironmentClassesPage[EnvironmentClass], class_, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.environments.classes.with_streaming_response.list() as response: diff --git a/tests/api_resources/groups/test_memberships.py b/tests/api_resources/groups/test_memberships.py index 88c7c32b..dd922c3b 100644 --- a/tests/api_resources/groups/test_memberships.py +++ b/tests/api_resources/groups/test_memberships.py @@ -22,13 +22,13 @@ class TestMemberships: 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_create(self, client: Gitpod) -> None: membership = client.groups.memberships.create() assert_matches_type(MembershipCreateResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: membership = client.groups.memberships.create( @@ -40,7 +40,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(MembershipCreateResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.groups.memberships.with_raw_response.create() @@ -50,7 +50,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: membership = response.parse() assert_matches_type(MembershipCreateResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.groups.memberships.with_streaming_response.create() as response: @@ -62,7 +62,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: membership = client.groups.memberships.retrieve( @@ -70,7 +70,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(MembershipRetrieveResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: membership = client.groups.memberships.retrieve( @@ -82,7 +82,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(MembershipRetrieveResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.groups.memberships.with_raw_response.retrieve( @@ -94,7 +94,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: membership = response.parse() assert_matches_type(MembershipRetrieveResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.groups.memberships.with_streaming_response.retrieve( @@ -108,18 +108,19 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: membership = client.groups.memberships.list() assert_matches_type(SyncMembersPage[GroupMembership], membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: membership = client.groups.memberships.list( token="token", page_size=0, + filter={"search": "search"}, group_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", pagination={ "token": "token", @@ -128,7 +129,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncMembersPage[GroupMembership], membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.groups.memberships.with_raw_response.list() @@ -138,7 +139,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: membership = response.parse() assert_matches_type(SyncMembersPage[GroupMembership], membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.groups.memberships.with_streaming_response.list() as response: @@ -150,13 +151,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: membership = client.groups.memberships.delete() assert_matches_type(object, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: membership = client.groups.memberships.delete( @@ -164,7 +165,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.groups.memberships.with_raw_response.delete() @@ -174,7 +175,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: membership = response.parse() assert_matches_type(object, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.groups.memberships.with_streaming_response.delete() as response: @@ -192,13 +193,13 @@ class TestAsyncMemberships: "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_create(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.create() assert_matches_type(MembershipCreateResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.create( @@ -210,7 +211,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(MembershipCreateResponse, membership, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.memberships.with_raw_response.create() @@ -220,7 +221,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: membership = await response.parse() assert_matches_type(MembershipCreateResponse, membership, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.groups.memberships.with_streaming_response.create() as response: @@ -232,7 +233,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.retrieve( @@ -240,7 +241,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(MembershipRetrieveResponse, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.retrieve( @@ -252,7 +253,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(MembershipRetrieveResponse, membership, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.memberships.with_raw_response.retrieve( @@ -264,7 +265,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: membership = await response.parse() assert_matches_type(MembershipRetrieveResponse, membership, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.groups.memberships.with_streaming_response.retrieve( @@ -278,18 +279,19 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_list(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.list() assert_matches_type(AsyncMembersPage[GroupMembership], membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.list( token="token", page_size=0, + filter={"search": "search"}, group_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", pagination={ "token": "token", @@ -298,7 +300,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncMembersPage[GroupMembership], membership, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.memberships.with_raw_response.list() @@ -308,7 +310,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: membership = await response.parse() assert_matches_type(AsyncMembersPage[GroupMembership], membership, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.groups.memberships.with_streaming_response.list() as response: @@ -320,13 +322,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.delete() assert_matches_type(object, membership, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: membership = await async_client.groups.memberships.delete( @@ -334,7 +336,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, membership, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.memberships.with_raw_response.delete() @@ -344,7 +346,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: membership = await response.parse() assert_matches_type(object, membership, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.groups.memberships.with_streaming_response.delete() as response: diff --git a/tests/api_resources/groups/test_role_assignments.py b/tests/api_resources/groups/test_role_assignments.py index a21be7e3..f654fb3a 100644 --- a/tests/api_resources/groups/test_role_assignments.py +++ b/tests/api_resources/groups/test_role_assignments.py @@ -21,13 +21,13 @@ class TestRoleAssignments: 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_create(self, client: Gitpod) -> None: role_assignment = client.groups.role_assignments.create() assert_matches_type(RoleAssignmentCreateResponse, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: role_assignment = client.groups.role_assignments.create( @@ -38,7 +38,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(RoleAssignmentCreateResponse, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.groups.role_assignments.with_raw_response.create() @@ -48,7 +48,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: role_assignment = response.parse() assert_matches_type(RoleAssignmentCreateResponse, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.groups.role_assignments.with_streaming_response.create() as response: @@ -60,13 +60,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: role_assignment = client.groups.role_assignments.list() assert_matches_type(SyncAssignmentsPage[RoleAssignment], role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: role_assignment = client.groups.role_assignments.list( @@ -75,6 +75,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: filter={ "group_id": "groupId", "resource_id": "resourceId", + "resource_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], "resource_roles": ["RESOURCE_ROLE_UNSPECIFIED"], "resource_types": ["RESOURCE_TYPE_RUNNER"], "user_id": "userId", @@ -86,7 +87,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncAssignmentsPage[RoleAssignment], role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.groups.role_assignments.with_raw_response.list() @@ -96,7 +97,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: role_assignment = response.parse() assert_matches_type(SyncAssignmentsPage[RoleAssignment], role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.groups.role_assignments.with_streaming_response.list() as response: @@ -108,13 +109,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: role_assignment = client.groups.role_assignments.delete() assert_matches_type(object, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: role_assignment = client.groups.role_assignments.delete( @@ -122,7 +123,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.groups.role_assignments.with_raw_response.delete() @@ -132,7 +133,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: role_assignment = response.parse() assert_matches_type(object, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.groups.role_assignments.with_streaming_response.delete() as response: @@ -150,13 +151,13 @@ class TestAsyncRoleAssignments: "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_create(self, async_client: AsyncGitpod) -> None: role_assignment = await async_client.groups.role_assignments.create() assert_matches_type(RoleAssignmentCreateResponse, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: role_assignment = await async_client.groups.role_assignments.create( @@ -167,7 +168,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(RoleAssignmentCreateResponse, role_assignment, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.role_assignments.with_raw_response.create() @@ -177,7 +178,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: role_assignment = await response.parse() assert_matches_type(RoleAssignmentCreateResponse, role_assignment, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.groups.role_assignments.with_streaming_response.create() as response: @@ -189,13 +190,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: role_assignment = await async_client.groups.role_assignments.list() assert_matches_type(AsyncAssignmentsPage[RoleAssignment], role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: role_assignment = await async_client.groups.role_assignments.list( @@ -204,6 +205,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N filter={ "group_id": "groupId", "resource_id": "resourceId", + "resource_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], "resource_roles": ["RESOURCE_ROLE_UNSPECIFIED"], "resource_types": ["RESOURCE_TYPE_RUNNER"], "user_id": "userId", @@ -215,7 +217,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncAssignmentsPage[RoleAssignment], role_assignment, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.role_assignments.with_raw_response.list() @@ -225,7 +227,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: role_assignment = await response.parse() assert_matches_type(AsyncAssignmentsPage[RoleAssignment], role_assignment, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.groups.role_assignments.with_streaming_response.list() as response: @@ -237,13 +239,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: role_assignment = await async_client.groups.role_assignments.delete() assert_matches_type(object, role_assignment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: role_assignment = await async_client.groups.role_assignments.delete( @@ -251,7 +253,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, role_assignment, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.role_assignments.with_raw_response.delete() @@ -261,7 +263,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: role_assignment = await response.parse() assert_matches_type(object, role_assignment, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.groups.role_assignments.with_streaming_response.delete() as response: diff --git a/tests/api_resources/groups/test_shares.py b/tests/api_resources/groups/test_shares.py index 3e0c57f4..b0f649b9 100644 --- a/tests/api_resources/groups/test_shares.py +++ b/tests/api_resources/groups/test_shares.py @@ -16,13 +16,13 @@ class TestShares: 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_create(self, client: Gitpod) -> None: share = client.groups.shares.create() assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: share = client.groups.shares.create( @@ -34,7 +34,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.groups.shares.with_raw_response.create() @@ -44,7 +44,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: share = response.parse() assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.groups.shares.with_streaming_response.create() as response: @@ -56,13 +56,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: share = client.groups.shares.delete() assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: share = client.groups.shares.delete( @@ -73,7 +73,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.groups.shares.with_raw_response.delete() @@ -83,7 +83,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: share = response.parse() assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.groups.shares.with_streaming_response.delete() as response: @@ -101,13 +101,13 @@ class TestAsyncShares: "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_create(self, async_client: AsyncGitpod) -> None: share = await async_client.groups.shares.create() assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: share = await async_client.groups.shares.create( @@ -119,7 +119,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, share, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.shares.with_raw_response.create() @@ -129,7 +129,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: share = await response.parse() assert_matches_type(object, share, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.groups.shares.with_streaming_response.create() as response: @@ -141,13 +141,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_delete(self, async_client: AsyncGitpod) -> None: share = await async_client.groups.shares.delete() assert_matches_type(object, share, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: share = await async_client.groups.shares.delete( @@ -158,7 +158,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, share, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.shares.with_raw_response.delete() @@ -168,7 +168,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: share = await response.parse() assert_matches_type(object, share, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.groups.shares.with_streaming_response.delete() as response: diff --git a/tests/api_resources/organizations/test_announcement_banner.py b/tests/api_resources/organizations/test_announcement_banner.py index 2e1c5b8e..5d6e44f8 100644 --- a/tests/api_resources/organizations/test_announcement_banner.py +++ b/tests/api_resources/organizations/test_announcement_banner.py @@ -20,7 +20,7 @@ class TestAnnouncementBanner: 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_update(self, client: Gitpod) -> None: announcement_banner = client.organizations.announcement_banner.update( @@ -28,7 +28,7 @@ def test_method_update(self, client: Gitpod) -> None: ) assert_matches_type(AnnouncementBannerUpdateResponse, announcement_banner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: announcement_banner = client.organizations.announcement_banner.update( @@ -38,7 +38,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(AnnouncementBannerUpdateResponse, announcement_banner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.organizations.announcement_banner.with_raw_response.update( @@ -50,7 +50,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: announcement_banner = response.parse() assert_matches_type(AnnouncementBannerUpdateResponse, announcement_banner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.organizations.announcement_banner.with_streaming_response.update( @@ -64,7 +64,7 @@ def test_streaming_response_update(self, client: Gitpod) -> 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(self, client: Gitpod) -> None: announcement_banner = client.organizations.announcement_banner.get( @@ -72,7 +72,7 @@ def test_method_get(self, client: Gitpod) -> None: ) assert_matches_type(AnnouncementBannerGetResponse, announcement_banner, 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: Gitpod) -> None: response = client.organizations.announcement_banner.with_raw_response.get( @@ -84,7 +84,7 @@ def test_raw_response_get(self, client: Gitpod) -> None: announcement_banner = response.parse() assert_matches_type(AnnouncementBannerGetResponse, announcement_banner, 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: Gitpod) -> None: with client.organizations.announcement_banner.with_streaming_response.get( @@ -104,7 +104,7 @@ class TestAsyncAnnouncementBanner: "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_update(self, async_client: AsyncGitpod) -> None: announcement_banner = await async_client.organizations.announcement_banner.update( @@ -112,7 +112,7 @@ async def test_method_update(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(AnnouncementBannerUpdateResponse, announcement_banner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: announcement_banner = await async_client.organizations.announcement_banner.update( @@ -122,7 +122,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(AnnouncementBannerUpdateResponse, announcement_banner, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.announcement_banner.with_raw_response.update( @@ -134,7 +134,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: announcement_banner = await response.parse() assert_matches_type(AnnouncementBannerUpdateResponse, announcement_banner, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.announcement_banner.with_streaming_response.update( @@ -148,7 +148,7 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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(self, async_client: AsyncGitpod) -> None: announcement_banner = await async_client.organizations.announcement_banner.get( @@ -156,7 +156,7 @@ async def test_method_get(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(AnnouncementBannerGetResponse, announcement_banner, 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: AsyncGitpod) -> None: response = await async_client.organizations.announcement_banner.with_raw_response.get( @@ -168,7 +168,7 @@ async def test_raw_response_get(self, async_client: AsyncGitpod) -> None: announcement_banner = await response.parse() assert_matches_type(AnnouncementBannerGetResponse, announcement_banner, 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: AsyncGitpod) -> None: async with async_client.organizations.announcement_banner.with_streaming_response.get( diff --git a/tests/api_resources/organizations/test_custom_domains.py b/tests/api_resources/organizations/test_custom_domains.py index dd7d86bc..220b14f4 100644 --- a/tests/api_resources/organizations/test_custom_domains.py +++ b/tests/api_resources/organizations/test_custom_domains.py @@ -21,7 +21,7 @@ class TestCustomDomains: 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_create(self, client: Gitpod) -> None: custom_domain = client.organizations.custom_domains.create( @@ -30,7 +30,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(CustomDomainCreateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: custom_domain = client.organizations.custom_domains.create( @@ -42,7 +42,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(CustomDomainCreateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.organizations.custom_domains.with_raw_response.create( @@ -55,7 +55,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: custom_domain = response.parse() assert_matches_type(CustomDomainCreateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.organizations.custom_domains.with_streaming_response.create( @@ -70,7 +70,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: custom_domain = client.organizations.custom_domains.retrieve( @@ -78,7 +78,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(CustomDomainRetrieveResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.organizations.custom_domains.with_raw_response.retrieve( @@ -90,7 +90,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: custom_domain = response.parse() assert_matches_type(CustomDomainRetrieveResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.organizations.custom_domains.with_streaming_response.retrieve( @@ -104,7 +104,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: custom_domain = client.organizations.custom_domains.update( @@ -113,7 +113,7 @@ def test_method_update(self, client: Gitpod) -> None: ) assert_matches_type(CustomDomainUpdateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: custom_domain = client.organizations.custom_domains.update( @@ -125,7 +125,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(CustomDomainUpdateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.organizations.custom_domains.with_raw_response.update( @@ -138,7 +138,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: custom_domain = response.parse() assert_matches_type(CustomDomainUpdateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.organizations.custom_domains.with_streaming_response.update( @@ -153,7 +153,7 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: custom_domain = client.organizations.custom_domains.delete( @@ -161,7 +161,7 @@ def test_method_delete(self, client: Gitpod) -> None: ) assert_matches_type(object, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.organizations.custom_domains.with_raw_response.delete( @@ -173,7 +173,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: custom_domain = response.parse() assert_matches_type(object, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.organizations.custom_domains.with_streaming_response.delete( @@ -193,7 +193,7 @@ class TestAsyncCustomDomains: "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_create(self, async_client: AsyncGitpod) -> None: custom_domain = await async_client.organizations.custom_domains.create( @@ -202,7 +202,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(CustomDomainCreateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: custom_domain = await async_client.organizations.custom_domains.create( @@ -214,7 +214,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(CustomDomainCreateResponse, custom_domain, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.custom_domains.with_raw_response.create( @@ -227,7 +227,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: custom_domain = await response.parse() assert_matches_type(CustomDomainCreateResponse, custom_domain, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.custom_domains.with_streaming_response.create( @@ -242,7 +242,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: custom_domain = await async_client.organizations.custom_domains.retrieve( @@ -250,7 +250,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(CustomDomainRetrieveResponse, custom_domain, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.custom_domains.with_raw_response.retrieve( @@ -262,7 +262,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: custom_domain = await response.parse() assert_matches_type(CustomDomainRetrieveResponse, custom_domain, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.custom_domains.with_streaming_response.retrieve( @@ -276,7 +276,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: custom_domain = await async_client.organizations.custom_domains.update( @@ -285,7 +285,7 @@ async def test_method_update(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(CustomDomainUpdateResponse, custom_domain, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: custom_domain = await async_client.organizations.custom_domains.update( @@ -297,7 +297,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(CustomDomainUpdateResponse, custom_domain, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.custom_domains.with_raw_response.update( @@ -310,7 +310,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: custom_domain = await response.parse() assert_matches_type(CustomDomainUpdateResponse, custom_domain, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.custom_domains.with_streaming_response.update( @@ -325,7 +325,7 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_delete(self, async_client: AsyncGitpod) -> None: custom_domain = await async_client.organizations.custom_domains.delete( @@ -333,7 +333,7 @@ async def test_method_delete(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, custom_domain, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.custom_domains.with_raw_response.delete( @@ -345,7 +345,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: custom_domain = await response.parse() assert_matches_type(object, custom_domain, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.custom_domains.with_streaming_response.delete( diff --git a/tests/api_resources/organizations/test_domain_verifications.py b/tests/api_resources/organizations/test_domain_verifications.py index c6c7043e..3a0bb1e5 100644 --- a/tests/api_resources/organizations/test_domain_verifications.py +++ b/tests/api_resources/organizations/test_domain_verifications.py @@ -23,7 +23,7 @@ class TestDomainVerifications: 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_create(self, client: Gitpod) -> None: domain_verification = client.organizations.domain_verifications.create( @@ -32,7 +32,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(DomainVerificationCreateResponse, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.organizations.domain_verifications.with_raw_response.create( @@ -45,7 +45,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: domain_verification = response.parse() assert_matches_type(DomainVerificationCreateResponse, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.organizations.domain_verifications.with_streaming_response.create( @@ -60,7 +60,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: domain_verification = client.organizations.domain_verifications.retrieve( @@ -68,7 +68,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(DomainVerificationRetrieveResponse, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.organizations.domain_verifications.with_raw_response.retrieve( @@ -80,7 +80,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: domain_verification = response.parse() assert_matches_type(DomainVerificationRetrieveResponse, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.organizations.domain_verifications.with_streaming_response.retrieve( @@ -94,7 +94,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: domain_verification = client.organizations.domain_verifications.list( @@ -102,7 +102,7 @@ def test_method_list(self, client: Gitpod) -> None: ) assert_matches_type(SyncDomainVerificationsPage[DomainVerification], domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: domain_verification = client.organizations.domain_verifications.list( @@ -116,7 +116,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncDomainVerificationsPage[DomainVerification], domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.organizations.domain_verifications.with_raw_response.list( @@ -128,7 +128,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: domain_verification = response.parse() assert_matches_type(SyncDomainVerificationsPage[DomainVerification], domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.organizations.domain_verifications.with_streaming_response.list( @@ -142,7 +142,7 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: domain_verification = client.organizations.domain_verifications.delete( @@ -150,7 +150,7 @@ def test_method_delete(self, client: Gitpod) -> None: ) assert_matches_type(object, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.organizations.domain_verifications.with_raw_response.delete( @@ -162,7 +162,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: domain_verification = response.parse() assert_matches_type(object, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.organizations.domain_verifications.with_streaming_response.delete( @@ -176,7 +176,7 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_verify(self, client: Gitpod) -> None: domain_verification = client.organizations.domain_verifications.verify( @@ -184,7 +184,7 @@ def test_method_verify(self, client: Gitpod) -> None: ) assert_matches_type(DomainVerificationVerifyResponse, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_verify(self, client: Gitpod) -> None: response = client.organizations.domain_verifications.with_raw_response.verify( @@ -196,7 +196,7 @@ def test_raw_response_verify(self, client: Gitpod) -> None: domain_verification = response.parse() assert_matches_type(DomainVerificationVerifyResponse, domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_verify(self, client: Gitpod) -> None: with client.organizations.domain_verifications.with_streaming_response.verify( @@ -216,7 +216,7 @@ class TestAsyncDomainVerifications: "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_create(self, async_client: AsyncGitpod) -> None: domain_verification = await async_client.organizations.domain_verifications.create( @@ -225,7 +225,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(DomainVerificationCreateResponse, domain_verification, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.domain_verifications.with_raw_response.create( @@ -238,7 +238,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: domain_verification = await response.parse() assert_matches_type(DomainVerificationCreateResponse, domain_verification, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.domain_verifications.with_streaming_response.create( @@ -253,7 +253,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: domain_verification = await async_client.organizations.domain_verifications.retrieve( @@ -261,7 +261,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(DomainVerificationRetrieveResponse, domain_verification, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.domain_verifications.with_raw_response.retrieve( @@ -273,7 +273,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: domain_verification = await response.parse() assert_matches_type(DomainVerificationRetrieveResponse, domain_verification, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.domain_verifications.with_streaming_response.retrieve( @@ -287,7 +287,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_list(self, async_client: AsyncGitpod) -> None: domain_verification = await async_client.organizations.domain_verifications.list( @@ -295,7 +295,7 @@ async def test_method_list(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(AsyncDomainVerificationsPage[DomainVerification], domain_verification, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: domain_verification = await async_client.organizations.domain_verifications.list( @@ -309,7 +309,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncDomainVerificationsPage[DomainVerification], domain_verification, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.domain_verifications.with_raw_response.list( @@ -321,7 +321,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: domain_verification = await response.parse() assert_matches_type(AsyncDomainVerificationsPage[DomainVerification], domain_verification, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.domain_verifications.with_streaming_response.list( @@ -337,7 +337,7 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: domain_verification = await async_client.organizations.domain_verifications.delete( @@ -345,7 +345,7 @@ async def test_method_delete(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, domain_verification, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.domain_verifications.with_raw_response.delete( @@ -357,7 +357,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: domain_verification = await response.parse() assert_matches_type(object, domain_verification, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.domain_verifications.with_streaming_response.delete( @@ -371,7 +371,7 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_verify(self, async_client: AsyncGitpod) -> None: domain_verification = await async_client.organizations.domain_verifications.verify( @@ -379,7 +379,7 @@ async def test_method_verify(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(DomainVerificationVerifyResponse, domain_verification, 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_verify(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.domain_verifications.with_raw_response.verify( @@ -391,7 +391,7 @@ async def test_raw_response_verify(self, async_client: AsyncGitpod) -> None: domain_verification = await response.parse() assert_matches_type(DomainVerificationVerifyResponse, domain_verification, 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_verify(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.domain_verifications.with_streaming_response.verify( diff --git a/tests/api_resources/organizations/test_invites.py b/tests/api_resources/organizations/test_invites.py index df2e8805..6002e9bb 100644 --- a/tests/api_resources/organizations/test_invites.py +++ b/tests/api_resources/organizations/test_invites.py @@ -21,7 +21,7 @@ class TestInvites: 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_create(self, client: Gitpod) -> None: invite = client.organizations.invites.create( @@ -29,7 +29,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(InviteCreateResponse, invite, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.organizations.invites.with_raw_response.create( @@ -41,7 +41,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: invite = response.parse() assert_matches_type(InviteCreateResponse, invite, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.organizations.invites.with_streaming_response.create( @@ -55,7 +55,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: invite = client.organizations.invites.retrieve( @@ -63,7 +63,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(InviteRetrieveResponse, invite, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.organizations.invites.with_raw_response.retrieve( @@ -75,7 +75,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: invite = response.parse() assert_matches_type(InviteRetrieveResponse, invite, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.organizations.invites.with_streaming_response.retrieve( @@ -89,7 +89,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_summary(self, client: Gitpod) -> None: invite = client.organizations.invites.get_summary( @@ -97,7 +97,7 @@ def test_method_get_summary(self, client: Gitpod) -> None: ) assert_matches_type(InviteGetSummaryResponse, invite, 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_summary(self, client: Gitpod) -> None: response = client.organizations.invites.with_raw_response.get_summary( @@ -109,7 +109,7 @@ def test_raw_response_get_summary(self, client: Gitpod) -> None: invite = response.parse() assert_matches_type(InviteGetSummaryResponse, invite, 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_summary(self, client: Gitpod) -> None: with client.organizations.invites.with_streaming_response.get_summary( @@ -129,7 +129,7 @@ class TestAsyncInvites: "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_create(self, async_client: AsyncGitpod) -> None: invite = await async_client.organizations.invites.create( @@ -137,7 +137,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(InviteCreateResponse, invite, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.invites.with_raw_response.create( @@ -149,7 +149,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: invite = await response.parse() assert_matches_type(InviteCreateResponse, invite, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.invites.with_streaming_response.create( @@ -163,7 +163,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: invite = await async_client.organizations.invites.retrieve( @@ -171,7 +171,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(InviteRetrieveResponse, invite, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.invites.with_raw_response.retrieve( @@ -183,7 +183,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: invite = await response.parse() assert_matches_type(InviteRetrieveResponse, invite, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.invites.with_streaming_response.retrieve( @@ -197,7 +197,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_summary(self, async_client: AsyncGitpod) -> None: invite = await async_client.organizations.invites.get_summary( @@ -205,7 +205,7 @@ async def test_method_get_summary(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(InviteGetSummaryResponse, invite, 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_summary(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.invites.with_raw_response.get_summary( @@ -217,7 +217,7 @@ async def test_raw_response_get_summary(self, async_client: AsyncGitpod) -> None invite = await response.parse() assert_matches_type(InviteGetSummaryResponse, invite, 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_summary(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.invites.with_streaming_response.get_summary( diff --git a/tests/api_resources/organizations/test_policies.py b/tests/api_resources/organizations/test_policies.py index 21c8ce08..7bd6cad2 100644 --- a/tests/api_resources/organizations/test_policies.py +++ b/tests/api_resources/organizations/test_policies.py @@ -19,7 +19,7 @@ class TestPolicies: 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_retrieve(self, client: Gitpod) -> None: policy = client.organizations.policies.retrieve( @@ -27,7 +27,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(PolicyRetrieveResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.organizations.policies.with_raw_response.retrieve( @@ -39,7 +39,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(PolicyRetrieveResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.organizations.policies.with_streaming_response.retrieve( @@ -53,7 +53,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: policy = client.organizations.policies.update( @@ -61,7 +61,7 @@ def test_method_update(self, client: Gitpod) -> None: ) assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: policy = client.organizations.policies.update( @@ -78,11 +78,6 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: default_environment_image="defaultEnvironmentImage", delete_archived_environments_after="+9125115.360s", editor_version_restrictions={"foo": {"allowed_versions": ["string"]}}, - executable_deny_list={ - "action": "KERNEL_CONTROLS_ACTION_UNSPECIFIED", - "enabled": True, - "executables": ["string"], - }, maximum_environment_lifetime="+9125115.360s", maximum_environments_per_user="20", maximum_environment_timeout="3600s", @@ -101,10 +96,15 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: "tags": "tags", } }, + veto_exec_policy={ + "action": "KERNEL_CONTROLS_ACTION_UNSPECIFIED", + "enabled": True, + "executables": ["string"], + }, ) assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.organizations.policies.with_raw_response.update( @@ -116,7 +116,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.organizations.policies.with_streaming_response.update( @@ -136,7 +136,7 @@ class TestAsyncPolicies: "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_retrieve(self, async_client: AsyncGitpod) -> None: policy = await async_client.organizations.policies.retrieve( @@ -144,7 +144,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(PolicyRetrieveResponse, policy, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.policies.with_raw_response.retrieve( @@ -156,7 +156,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(PolicyRetrieveResponse, policy, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.policies.with_streaming_response.retrieve( @@ -170,7 +170,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: policy = await async_client.organizations.policies.update( @@ -178,7 +178,7 @@ async def test_method_update(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.organizations.policies.update( @@ -195,11 +195,6 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> default_environment_image="defaultEnvironmentImage", delete_archived_environments_after="+9125115.360s", editor_version_restrictions={"foo": {"allowed_versions": ["string"]}}, - executable_deny_list={ - "action": "KERNEL_CONTROLS_ACTION_UNSPECIFIED", - "enabled": True, - "executables": ["string"], - }, maximum_environment_lifetime="+9125115.360s", maximum_environments_per_user="20", maximum_environment_timeout="3600s", @@ -218,10 +213,15 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> "tags": "tags", } }, + veto_exec_policy={ + "action": "KERNEL_CONTROLS_ACTION_UNSPECIFIED", + "enabled": True, + "executables": ["string"], + }, ) assert_matches_type(object, policy, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.policies.with_raw_response.update( @@ -233,7 +233,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(object, policy, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.policies.with_streaming_response.update( diff --git a/tests/api_resources/organizations/test_scim_configurations.py b/tests/api_resources/organizations/test_scim_configurations.py index 4404e237..2bd96136 100644 --- a/tests/api_resources/organizations/test_scim_configurations.py +++ b/tests/api_resources/organizations/test_scim_configurations.py @@ -24,7 +24,7 @@ class TestScimConfigurations: 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_create(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.create( @@ -33,7 +33,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(ScimConfigurationCreateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.create( @@ -44,7 +44,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ScimConfigurationCreateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.organizations.scim_configurations.with_raw_response.create( @@ -57,7 +57,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: scim_configuration = response.parse() assert_matches_type(ScimConfigurationCreateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.organizations.scim_configurations.with_streaming_response.create( @@ -72,7 +72,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.retrieve( @@ -80,7 +80,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(ScimConfigurationRetrieveResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.organizations.scim_configurations.with_raw_response.retrieve( @@ -92,7 +92,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: scim_configuration = response.parse() assert_matches_type(ScimConfigurationRetrieveResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.organizations.scim_configurations.with_streaming_response.retrieve( @@ -106,7 +106,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.update( @@ -114,7 +114,7 @@ def test_method_update(self, client: Gitpod) -> None: ) assert_matches_type(ScimConfigurationUpdateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.update( @@ -125,7 +125,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ScimConfigurationUpdateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.organizations.scim_configurations.with_raw_response.update( @@ -137,7 +137,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: scim_configuration = response.parse() assert_matches_type(ScimConfigurationUpdateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.organizations.scim_configurations.with_streaming_response.update( @@ -151,13 +151,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.list() assert_matches_type(SyncScimConfigurationsPage[ScimConfiguration], scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.list( @@ -170,7 +170,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncScimConfigurationsPage[ScimConfiguration], scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.organizations.scim_configurations.with_raw_response.list() @@ -180,7 +180,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: scim_configuration = response.parse() assert_matches_type(SyncScimConfigurationsPage[ScimConfiguration], scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.organizations.scim_configurations.with_streaming_response.list() as response: @@ -192,7 +192,7 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.delete( @@ -200,7 +200,7 @@ def test_method_delete(self, client: Gitpod) -> None: ) assert_matches_type(object, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.organizations.scim_configurations.with_raw_response.delete( @@ -212,7 +212,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: scim_configuration = response.parse() assert_matches_type(object, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.organizations.scim_configurations.with_streaming_response.delete( @@ -226,7 +226,7 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_regenerate_token(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.regenerate_token( @@ -234,7 +234,7 @@ def test_method_regenerate_token(self, client: Gitpod) -> None: ) assert_matches_type(ScimConfigurationRegenerateTokenResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_regenerate_token_with_all_params(self, client: Gitpod) -> None: scim_configuration = client.organizations.scim_configurations.regenerate_token( @@ -243,7 +243,7 @@ def test_method_regenerate_token_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ScimConfigurationRegenerateTokenResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_regenerate_token(self, client: Gitpod) -> None: response = client.organizations.scim_configurations.with_raw_response.regenerate_token( @@ -255,7 +255,7 @@ def test_raw_response_regenerate_token(self, client: Gitpod) -> None: scim_configuration = response.parse() assert_matches_type(ScimConfigurationRegenerateTokenResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_regenerate_token(self, client: Gitpod) -> None: with client.organizations.scim_configurations.with_streaming_response.regenerate_token( @@ -275,7 +275,7 @@ class TestAsyncScimConfigurations: "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_create(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.create( @@ -284,7 +284,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(ScimConfigurationCreateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.create( @@ -295,7 +295,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(ScimConfigurationCreateResponse, scim_configuration, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.scim_configurations.with_raw_response.create( @@ -308,7 +308,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: scim_configuration = await response.parse() assert_matches_type(ScimConfigurationCreateResponse, scim_configuration, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.scim_configurations.with_streaming_response.create( @@ -323,7 +323,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.retrieve( @@ -331,7 +331,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(ScimConfigurationRetrieveResponse, scim_configuration, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.scim_configurations.with_raw_response.retrieve( @@ -343,7 +343,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: scim_configuration = await response.parse() assert_matches_type(ScimConfigurationRetrieveResponse, scim_configuration, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.scim_configurations.with_streaming_response.retrieve( @@ -357,7 +357,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.update( @@ -365,7 +365,7 @@ async def test_method_update(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(ScimConfigurationUpdateResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.update( @@ -376,7 +376,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(ScimConfigurationUpdateResponse, scim_configuration, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.scim_configurations.with_raw_response.update( @@ -388,7 +388,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: scim_configuration = await response.parse() assert_matches_type(ScimConfigurationUpdateResponse, scim_configuration, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.scim_configurations.with_streaming_response.update( @@ -402,13 +402,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.list() assert_matches_type(AsyncScimConfigurationsPage[ScimConfiguration], scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.list( @@ -421,7 +421,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncScimConfigurationsPage[ScimConfiguration], scim_configuration, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.scim_configurations.with_raw_response.list() @@ -431,7 +431,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: scim_configuration = await response.parse() assert_matches_type(AsyncScimConfigurationsPage[ScimConfiguration], scim_configuration, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.scim_configurations.with_streaming_response.list() as response: @@ -443,7 +443,7 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.delete( @@ -451,7 +451,7 @@ async def test_method_delete(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, scim_configuration, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.scim_configurations.with_raw_response.delete( @@ -463,7 +463,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: scim_configuration = await response.parse() assert_matches_type(object, scim_configuration, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.scim_configurations.with_streaming_response.delete( @@ -477,7 +477,7 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_regenerate_token(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.regenerate_token( @@ -485,7 +485,7 @@ async def test_method_regenerate_token(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(ScimConfigurationRegenerateTokenResponse, scim_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_regenerate_token_with_all_params(self, async_client: AsyncGitpod) -> None: scim_configuration = await async_client.organizations.scim_configurations.regenerate_token( @@ -494,7 +494,7 @@ async def test_method_regenerate_token_with_all_params(self, async_client: Async ) assert_matches_type(ScimConfigurationRegenerateTokenResponse, scim_configuration, 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_regenerate_token(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.scim_configurations.with_raw_response.regenerate_token( @@ -506,7 +506,7 @@ async def test_raw_response_regenerate_token(self, async_client: AsyncGitpod) -> scim_configuration = await response.parse() assert_matches_type(ScimConfigurationRegenerateTokenResponse, scim_configuration, 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_regenerate_token(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.scim_configurations.with_streaming_response.regenerate_token( diff --git a/tests/api_resources/organizations/test_sso_configurations.py b/tests/api_resources/organizations/test_sso_configurations.py index 9dd1f95a..7c52f6f9 100644 --- a/tests/api_resources/organizations/test_sso_configurations.py +++ b/tests/api_resources/organizations/test_sso_configurations.py @@ -22,7 +22,7 @@ class TestSSOConfigurations: 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_create(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.create( @@ -33,7 +33,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(SSOConfigurationCreateResponse, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.create( @@ -48,7 +48,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SSOConfigurationCreateResponse, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.organizations.sso_configurations.with_raw_response.create( @@ -63,7 +63,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: sso_configuration = response.parse() assert_matches_type(SSOConfigurationCreateResponse, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.organizations.sso_configurations.with_streaming_response.create( @@ -80,7 +80,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.retrieve( @@ -88,7 +88,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(SSOConfigurationRetrieveResponse, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.organizations.sso_configurations.with_raw_response.retrieve( @@ -100,7 +100,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: sso_configuration = response.parse() assert_matches_type(SSOConfigurationRetrieveResponse, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.organizations.sso_configurations.with_streaming_response.retrieve( @@ -114,7 +114,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.update( @@ -122,7 +122,7 @@ def test_method_update(self, client: Gitpod) -> None: ) assert_matches_type(object, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.update( @@ -139,7 +139,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.organizations.sso_configurations.with_raw_response.update( @@ -151,7 +151,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: sso_configuration = response.parse() assert_matches_type(object, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.organizations.sso_configurations.with_streaming_response.update( @@ -165,7 +165,7 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.list( @@ -173,7 +173,7 @@ def test_method_list(self, client: Gitpod) -> None: ) assert_matches_type(SyncSSOConfigurationsPage[SSOConfiguration], sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.list( @@ -187,7 +187,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncSSOConfigurationsPage[SSOConfiguration], sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.organizations.sso_configurations.with_raw_response.list( @@ -199,7 +199,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: sso_configuration = response.parse() assert_matches_type(SyncSSOConfigurationsPage[SSOConfiguration], sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.organizations.sso_configurations.with_streaming_response.list( @@ -213,7 +213,7 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: sso_configuration = client.organizations.sso_configurations.delete( @@ -221,7 +221,7 @@ def test_method_delete(self, client: Gitpod) -> None: ) assert_matches_type(object, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.organizations.sso_configurations.with_raw_response.delete( @@ -233,7 +233,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: sso_configuration = response.parse() assert_matches_type(object, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.organizations.sso_configurations.with_streaming_response.delete( @@ -253,7 +253,7 @@ class TestAsyncSSOConfigurations: "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_create(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.create( @@ -264,7 +264,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(SSOConfigurationCreateResponse, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.create( @@ -279,7 +279,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(SSOConfigurationCreateResponse, sso_configuration, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.sso_configurations.with_raw_response.create( @@ -294,7 +294,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: sso_configuration = await response.parse() assert_matches_type(SSOConfigurationCreateResponse, sso_configuration, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.sso_configurations.with_streaming_response.create( @@ -311,7 +311,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.retrieve( @@ -319,7 +319,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(SSOConfigurationRetrieveResponse, sso_configuration, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.sso_configurations.with_raw_response.retrieve( @@ -331,7 +331,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: sso_configuration = await response.parse() assert_matches_type(SSOConfigurationRetrieveResponse, sso_configuration, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.sso_configurations.with_streaming_response.retrieve( @@ -345,7 +345,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.update( @@ -353,7 +353,7 @@ async def test_method_update(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.update( @@ -370,7 +370,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, sso_configuration, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.sso_configurations.with_raw_response.update( @@ -382,7 +382,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: sso_configuration = await response.parse() assert_matches_type(object, sso_configuration, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.sso_configurations.with_streaming_response.update( @@ -396,7 +396,7 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.list( @@ -404,7 +404,7 @@ async def test_method_list(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(AsyncSSOConfigurationsPage[SSOConfiguration], sso_configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.list( @@ -418,7 +418,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncSSOConfigurationsPage[SSOConfiguration], sso_configuration, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.sso_configurations.with_raw_response.list( @@ -430,7 +430,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: sso_configuration = await response.parse() assert_matches_type(AsyncSSOConfigurationsPage[SSOConfiguration], sso_configuration, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.sso_configurations.with_streaming_response.list( @@ -444,7 +444,7 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: sso_configuration = await async_client.organizations.sso_configurations.delete( @@ -452,7 +452,7 @@ async def test_method_delete(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, sso_configuration, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.sso_configurations.with_raw_response.delete( @@ -464,7 +464,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: sso_configuration = await response.parse() assert_matches_type(object, sso_configuration, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.sso_configurations.with_streaming_response.delete( diff --git a/tests/api_resources/projects/test_environment_clases.py b/tests/api_resources/projects/test_environment_clases.py index fada14da..325c4ac5 100644 --- a/tests/api_resources/projects/test_environment_clases.py +++ b/tests/api_resources/projects/test_environment_clases.py @@ -18,13 +18,13 @@ class TestEnvironmentClases: 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_update(self, client: Gitpod) -> None: environment_clase = client.projects.environment_clases.update() assert_matches_type(object, environment_clase, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: environment_clase = client.projects.environment_clases.update( @@ -44,7 +44,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment_clase, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.projects.environment_clases.with_raw_response.update() @@ -54,7 +54,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: environment_clase = response.parse() assert_matches_type(object, environment_clase, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.projects.environment_clases.with_streaming_response.update() as response: @@ -66,7 +66,7 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: environment_clase = client.projects.environment_clases.list() @@ -74,7 +74,7 @@ def test_method_list(self, client: Gitpod) -> None: SyncProjectEnvironmentClassesPage[ProjectEnvironmentClass], environment_clase, path=["response"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: environment_clase = client.projects.environment_clases.list( @@ -90,7 +90,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: SyncProjectEnvironmentClassesPage[ProjectEnvironmentClass], environment_clase, path=["response"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.projects.environment_clases.with_raw_response.list() @@ -102,7 +102,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: SyncProjectEnvironmentClassesPage[ProjectEnvironmentClass], environment_clase, path=["response"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.projects.environment_clases.with_streaming_response.list() as response: @@ -122,13 +122,13 @@ class TestAsyncEnvironmentClases: "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_update(self, async_client: AsyncGitpod) -> None: environment_clase = await async_client.projects.environment_clases.update() assert_matches_type(object, environment_clase, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: environment_clase = await async_client.projects.environment_clases.update( @@ -148,7 +148,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, environment_clase, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.environment_clases.with_raw_response.update() @@ -158,7 +158,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: environment_clase = await response.parse() assert_matches_type(object, environment_clase, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.projects.environment_clases.with_streaming_response.update() as response: @@ -170,7 +170,7 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: environment_clase = await async_client.projects.environment_clases.list() @@ -178,7 +178,7 @@ async def test_method_list(self, async_client: AsyncGitpod) -> None: AsyncProjectEnvironmentClassesPage[ProjectEnvironmentClass], environment_clase, path=["response"] ) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: environment_clase = await async_client.projects.environment_clases.list( @@ -194,7 +194,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N AsyncProjectEnvironmentClassesPage[ProjectEnvironmentClass], environment_clase, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.environment_clases.with_raw_response.list() @@ -206,7 +206,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: AsyncProjectEnvironmentClassesPage[ProjectEnvironmentClass], environment_clase, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.projects.environment_clases.with_streaming_response.list() as response: diff --git a/tests/api_resources/projects/test_policies.py b/tests/api_resources/projects/test_policies.py index 17b49580..057a5773 100644 --- a/tests/api_resources/projects/test_policies.py +++ b/tests/api_resources/projects/test_policies.py @@ -22,13 +22,13 @@ class TestPolicies: 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_create(self, client: Gitpod) -> None: policy = client.projects.policies.create() assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: policy = client.projects.policies.create( @@ -38,7 +38,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.projects.policies.with_raw_response.create() @@ -48,7 +48,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.projects.policies.with_streaming_response.create() as response: @@ -60,13 +60,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: policy = client.projects.policies.update() assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: policy = client.projects.policies.update( @@ -76,7 +76,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.projects.policies.with_raw_response.update() @@ -86,7 +86,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.projects.policies.with_streaming_response.update() as response: @@ -98,13 +98,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: policy = client.projects.policies.list() assert_matches_type(SyncPoliciesPage[ProjectPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: policy = client.projects.policies.list( @@ -118,7 +118,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncPoliciesPage[ProjectPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.projects.policies.with_raw_response.list() @@ -128,7 +128,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(SyncPoliciesPage[ProjectPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.projects.policies.with_streaming_response.list() as response: @@ -140,13 +140,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: policy = client.projects.policies.delete() assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: policy = client.projects.policies.delete( @@ -155,7 +155,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.projects.policies.with_raw_response.delete() @@ -165,7 +165,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.projects.policies.with_streaming_response.delete() as response: @@ -183,13 +183,13 @@ class TestAsyncPolicies: "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_create(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.create() assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.create( @@ -199,7 +199,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(PolicyCreateResponse, policy, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.policies.with_raw_response.create() @@ -209,7 +209,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(PolicyCreateResponse, policy, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.projects.policies.with_streaming_response.create() as response: @@ -221,13 +221,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_update(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.update() assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.update( @@ -237,7 +237,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(PolicyUpdateResponse, policy, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.policies.with_raw_response.update() @@ -247,7 +247,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(PolicyUpdateResponse, policy, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.projects.policies.with_streaming_response.update() as response: @@ -259,13 +259,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.list() assert_matches_type(AsyncPoliciesPage[ProjectPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.list( @@ -279,7 +279,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncPoliciesPage[ProjectPolicy], policy, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.policies.with_raw_response.list() @@ -289,7 +289,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(AsyncPoliciesPage[ProjectPolicy], policy, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.projects.policies.with_streaming_response.list() as response: @@ -301,13 +301,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.delete() assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.projects.policies.delete( @@ -316,7 +316,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, policy, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.policies.with_raw_response.delete() @@ -326,7 +326,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(object, policy, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.projects.policies.with_streaming_response.delete() as response: diff --git a/tests/api_resources/runners/configurations/test_environment_classes.py b/tests/api_resources/runners/configurations/test_environment_classes.py index 919e93d8..db474c48 100644 --- a/tests/api_resources/runners/configurations/test_environment_classes.py +++ b/tests/api_resources/runners/configurations/test_environment_classes.py @@ -22,13 +22,13 @@ class TestEnvironmentClasses: 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_create(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.create() assert_matches_type(EnvironmentClassCreateResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.create( @@ -48,7 +48,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(EnvironmentClassCreateResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.runners.configurations.environment_classes.with_raw_response.create() @@ -58,7 +58,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: environment_class = response.parse() assert_matches_type(EnvironmentClassCreateResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.runners.configurations.environment_classes.with_streaming_response.create() as response: @@ -70,13 +70,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.retrieve() assert_matches_type(EnvironmentClassRetrieveResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.retrieve( @@ -84,7 +84,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(EnvironmentClassRetrieveResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.runners.configurations.environment_classes.with_raw_response.retrieve() @@ -94,7 +94,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: environment_class = response.parse() assert_matches_type(EnvironmentClassRetrieveResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.runners.configurations.environment_classes.with_streaming_response.retrieve() as response: @@ -106,13 +106,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.update() assert_matches_type(object, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.update( @@ -123,7 +123,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.runners.configurations.environment_classes.with_raw_response.update() @@ -133,7 +133,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: environment_class = response.parse() assert_matches_type(object, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.runners.configurations.environment_classes.with_streaming_response.update() as response: @@ -145,13 +145,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.list() assert_matches_type(SyncEnvironmentClassesPage[EnvironmentClass], environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: environment_class = client.runners.configurations.environment_classes.list( @@ -171,7 +171,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncEnvironmentClassesPage[EnvironmentClass], environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.runners.configurations.environment_classes.with_raw_response.list() @@ -181,7 +181,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: environment_class = response.parse() assert_matches_type(SyncEnvironmentClassesPage[EnvironmentClass], environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.runners.configurations.environment_classes.with_streaming_response.list() as response: @@ -199,13 +199,13 @@ class TestAsyncEnvironmentClasses: "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_create(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.create() assert_matches_type(EnvironmentClassCreateResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.create( @@ -225,7 +225,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(EnvironmentClassCreateResponse, environment_class, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.environment_classes.with_raw_response.create() @@ -235,7 +235,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: environment_class = await response.parse() assert_matches_type(EnvironmentClassCreateResponse, environment_class, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.environment_classes.with_streaming_response.create() as response: @@ -247,13 +247,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.retrieve() assert_matches_type(EnvironmentClassRetrieveResponse, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.retrieve( @@ -261,7 +261,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(EnvironmentClassRetrieveResponse, environment_class, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.environment_classes.with_raw_response.retrieve() @@ -271,7 +271,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: environment_class = await response.parse() assert_matches_type(EnvironmentClassRetrieveResponse, environment_class, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with ( @@ -285,13 +285,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.update() assert_matches_type(object, environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.update( @@ -302,7 +302,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, environment_class, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.environment_classes.with_raw_response.update() @@ -312,7 +312,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: environment_class = await response.parse() assert_matches_type(object, environment_class, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.environment_classes.with_streaming_response.update() as response: @@ -324,13 +324,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.list() assert_matches_type(AsyncEnvironmentClassesPage[EnvironmentClass], environment_class, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: environment_class = await async_client.runners.configurations.environment_classes.list( @@ -350,7 +350,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncEnvironmentClassesPage[EnvironmentClass], environment_class, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.environment_classes.with_raw_response.list() @@ -360,7 +360,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: environment_class = await response.parse() assert_matches_type(AsyncEnvironmentClassesPage[EnvironmentClass], environment_class, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.environment_classes.with_streaming_response.list() as response: diff --git a/tests/api_resources/runners/configurations/test_host_authentication_tokens.py b/tests/api_resources/runners/configurations/test_host_authentication_tokens.py index ccfcf9f2..bc411e61 100644 --- a/tests/api_resources/runners/configurations/test_host_authentication_tokens.py +++ b/tests/api_resources/runners/configurations/test_host_authentication_tokens.py @@ -23,13 +23,13 @@ class TestHostAuthenticationTokens: 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_create(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.create() assert_matches_type(HostAuthenticationTokenCreateResponse, host_authentication_token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.create( @@ -49,7 +49,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(HostAuthenticationTokenCreateResponse, host_authentication_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_create(self, client: Gitpod) -> None: response = client.runners.configurations.host_authentication_tokens.with_raw_response.create() @@ -59,7 +59,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: host_authentication_token = response.parse() assert_matches_type(HostAuthenticationTokenCreateResponse, host_authentication_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_create(self, client: Gitpod) -> None: with client.runners.configurations.host_authentication_tokens.with_streaming_response.create() as response: @@ -71,13 +71,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.retrieve() assert_matches_type(HostAuthenticationTokenRetrieveResponse, host_authentication_token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.retrieve( @@ -85,7 +85,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(HostAuthenticationTokenRetrieveResponse, host_authentication_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_retrieve(self, client: Gitpod) -> None: response = client.runners.configurations.host_authentication_tokens.with_raw_response.retrieve() @@ -95,7 +95,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: host_authentication_token = response.parse() assert_matches_type(HostAuthenticationTokenRetrieveResponse, host_authentication_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_retrieve(self, client: Gitpod) -> None: with client.runners.configurations.host_authentication_tokens.with_streaming_response.retrieve() as response: @@ -107,13 +107,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.update() assert_matches_type(object, host_authentication_token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.update( @@ -125,7 +125,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, host_authentication_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_update(self, client: Gitpod) -> None: response = client.runners.configurations.host_authentication_tokens.with_raw_response.update() @@ -135,7 +135,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: host_authentication_token = response.parse() assert_matches_type(object, host_authentication_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_update(self, client: Gitpod) -> None: with client.runners.configurations.host_authentication_tokens.with_streaming_response.update() as response: @@ -147,13 +147,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.list() assert_matches_type(SyncTokensPage[HostAuthenticationToken], host_authentication_token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.list( @@ -171,7 +171,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncTokensPage[HostAuthenticationToken], host_authentication_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_list(self, client: Gitpod) -> None: response = client.runners.configurations.host_authentication_tokens.with_raw_response.list() @@ -181,7 +181,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: host_authentication_token = response.parse() assert_matches_type(SyncTokensPage[HostAuthenticationToken], host_authentication_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_list(self, client: Gitpod) -> None: with client.runners.configurations.host_authentication_tokens.with_streaming_response.list() as response: @@ -193,13 +193,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.delete() assert_matches_type(object, host_authentication_token, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: host_authentication_token = client.runners.configurations.host_authentication_tokens.delete( @@ -207,7 +207,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, host_authentication_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_delete(self, client: Gitpod) -> None: response = client.runners.configurations.host_authentication_tokens.with_raw_response.delete() @@ -217,7 +217,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: host_authentication_token = response.parse() assert_matches_type(object, host_authentication_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_delete(self, client: Gitpod) -> None: with client.runners.configurations.host_authentication_tokens.with_streaming_response.delete() as response: @@ -235,13 +235,13 @@ class TestAsyncHostAuthenticationTokens: "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_create(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.create() assert_matches_type(HostAuthenticationTokenCreateResponse, host_authentication_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_create_with_all_params(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.create( @@ -261,7 +261,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(HostAuthenticationTokenCreateResponse, host_authentication_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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.host_authentication_tokens.with_raw_response.create() @@ -271,7 +271,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: host_authentication_token = await response.parse() assert_matches_type(HostAuthenticationTokenCreateResponse, host_authentication_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_create(self, async_client: AsyncGitpod) -> None: async with ( @@ -285,13 +285,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.retrieve() assert_matches_type(HostAuthenticationTokenRetrieveResponse, host_authentication_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_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.retrieve( @@ -299,7 +299,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(HostAuthenticationTokenRetrieveResponse, host_authentication_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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.host_authentication_tokens.with_raw_response.retrieve() @@ -309,7 +309,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: host_authentication_token = await response.parse() assert_matches_type(HostAuthenticationTokenRetrieveResponse, host_authentication_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_retrieve(self, async_client: AsyncGitpod) -> None: async with ( @@ -323,13 +323,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.update() assert_matches_type(object, host_authentication_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_update_with_all_params(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.update( @@ -341,7 +341,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, host_authentication_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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.host_authentication_tokens.with_raw_response.update() @@ -351,7 +351,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: host_authentication_token = await response.parse() assert_matches_type(object, host_authentication_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_update(self, async_client: AsyncGitpod) -> None: async with ( @@ -365,13 +365,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.list() assert_matches_type(AsyncTokensPage[HostAuthenticationToken], host_authentication_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_list_with_all_params(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.list( @@ -389,7 +389,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncTokensPage[HostAuthenticationToken], host_authentication_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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.host_authentication_tokens.with_raw_response.list() @@ -399,7 +399,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: host_authentication_token = await response.parse() assert_matches_type(AsyncTokensPage[HostAuthenticationToken], host_authentication_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_list(self, async_client: AsyncGitpod) -> None: async with ( @@ -413,13 +413,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.delete() assert_matches_type(object, host_authentication_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_delete_with_all_params(self, async_client: AsyncGitpod) -> None: host_authentication_token = await async_client.runners.configurations.host_authentication_tokens.delete( @@ -427,7 +427,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, host_authentication_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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.host_authentication_tokens.with_raw_response.delete() @@ -437,7 +437,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: host_authentication_token = await response.parse() assert_matches_type(object, host_authentication_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_delete(self, async_client: AsyncGitpod) -> None: async with ( diff --git a/tests/api_resources/runners/configurations/test_schema.py b/tests/api_resources/runners/configurations/test_schema.py index e83271f8..7c5be8ad 100644 --- a/tests/api_resources/runners/configurations/test_schema.py +++ b/tests/api_resources/runners/configurations/test_schema.py @@ -17,13 +17,13 @@ class TestSchema: 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_retrieve(self, client: Gitpod) -> None: schema = client.runners.configurations.schema.retrieve() assert_matches_type(SchemaRetrieveResponse, schema, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: schema = client.runners.configurations.schema.retrieve( @@ -31,7 +31,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SchemaRetrieveResponse, schema, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.runners.configurations.schema.with_raw_response.retrieve() @@ -41,7 +41,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: schema = response.parse() assert_matches_type(SchemaRetrieveResponse, schema, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.runners.configurations.schema.with_streaming_response.retrieve() as response: @@ -59,13 +59,13 @@ class TestAsyncSchema: "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_retrieve(self, async_client: AsyncGitpod) -> None: schema = await async_client.runners.configurations.schema.retrieve() assert_matches_type(SchemaRetrieveResponse, schema, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: schema = await async_client.runners.configurations.schema.retrieve( @@ -73,7 +73,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(SchemaRetrieveResponse, schema, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.schema.with_raw_response.retrieve() @@ -83,7 +83,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: schema = await response.parse() assert_matches_type(SchemaRetrieveResponse, schema, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.schema.with_streaming_response.retrieve() as response: diff --git a/tests/api_resources/runners/configurations/test_scm_integrations.py b/tests/api_resources/runners/configurations/test_scm_integrations.py index d68d3e88..fd94c6f0 100644 --- a/tests/api_resources/runners/configurations/test_scm_integrations.py +++ b/tests/api_resources/runners/configurations/test_scm_integrations.py @@ -22,13 +22,13 @@ class TestScmIntegrations: 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_create(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.create() assert_matches_type(ScmIntegrationCreateResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.create( @@ -43,7 +43,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ScmIntegrationCreateResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.runners.configurations.scm_integrations.with_raw_response.create() @@ -53,7 +53,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: scm_integration = response.parse() assert_matches_type(ScmIntegrationCreateResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.runners.configurations.scm_integrations.with_streaming_response.create() as response: @@ -65,13 +65,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.retrieve() assert_matches_type(ScmIntegrationRetrieveResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.retrieve( @@ -79,7 +79,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ScmIntegrationRetrieveResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.runners.configurations.scm_integrations.with_raw_response.retrieve() @@ -89,7 +89,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: scm_integration = response.parse() assert_matches_type(ScmIntegrationRetrieveResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.runners.configurations.scm_integrations.with_streaming_response.retrieve() as response: @@ -101,13 +101,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.update() assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.update( @@ -120,7 +120,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.runners.configurations.scm_integrations.with_raw_response.update() @@ -130,7 +130,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: scm_integration = response.parse() assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.runners.configurations.scm_integrations.with_streaming_response.update() as response: @@ -142,13 +142,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.list() assert_matches_type(SyncIntegrationsPage[ScmIntegration], scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.list( @@ -162,7 +162,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncIntegrationsPage[ScmIntegration], scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.runners.configurations.scm_integrations.with_raw_response.list() @@ -172,7 +172,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: scm_integration = response.parse() assert_matches_type(SyncIntegrationsPage[ScmIntegration], scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.runners.configurations.scm_integrations.with_streaming_response.list() as response: @@ -184,13 +184,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.delete() assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: scm_integration = client.runners.configurations.scm_integrations.delete( @@ -198,7 +198,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.runners.configurations.scm_integrations.with_raw_response.delete() @@ -208,7 +208,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: scm_integration = response.parse() assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.runners.configurations.scm_integrations.with_streaming_response.delete() as response: @@ -226,13 +226,13 @@ class TestAsyncScmIntegrations: "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_create(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.create() assert_matches_type(ScmIntegrationCreateResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.create( @@ -247,7 +247,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(ScmIntegrationCreateResponse, scm_integration, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.scm_integrations.with_raw_response.create() @@ -257,7 +257,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: scm_integration = await response.parse() assert_matches_type(ScmIntegrationCreateResponse, scm_integration, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.scm_integrations.with_streaming_response.create() as response: @@ -269,13 +269,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.retrieve() assert_matches_type(ScmIntegrationRetrieveResponse, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.retrieve( @@ -283,7 +283,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(ScmIntegrationRetrieveResponse, scm_integration, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.scm_integrations.with_raw_response.retrieve() @@ -293,7 +293,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: scm_integration = await response.parse() assert_matches_type(ScmIntegrationRetrieveResponse, scm_integration, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.scm_integrations.with_streaming_response.retrieve() as response: @@ -305,13 +305,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.update() assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.update( @@ -324,7 +324,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, scm_integration, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.scm_integrations.with_raw_response.update() @@ -334,7 +334,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: scm_integration = await response.parse() assert_matches_type(object, scm_integration, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.scm_integrations.with_streaming_response.update() as response: @@ -346,13 +346,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.list() assert_matches_type(AsyncIntegrationsPage[ScmIntegration], scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.list( @@ -366,7 +366,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncIntegrationsPage[ScmIntegration], scm_integration, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.scm_integrations.with_raw_response.list() @@ -376,7 +376,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: scm_integration = await response.parse() assert_matches_type(AsyncIntegrationsPage[ScmIntegration], scm_integration, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.scm_integrations.with_streaming_response.list() as response: @@ -388,13 +388,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.delete() assert_matches_type(object, scm_integration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: scm_integration = await async_client.runners.configurations.scm_integrations.delete( @@ -402,7 +402,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, scm_integration, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.scm_integrations.with_raw_response.delete() @@ -412,7 +412,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: scm_integration = await response.parse() assert_matches_type(object, scm_integration, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.scm_integrations.with_streaming_response.delete() as response: diff --git a/tests/api_resources/runners/test_configurations.py b/tests/api_resources/runners/test_configurations.py index 0672e8e1..3cecfabd 100644 --- a/tests/api_resources/runners/test_configurations.py +++ b/tests/api_resources/runners/test_configurations.py @@ -17,13 +17,13 @@ class TestConfigurations: 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_validate(self, client: Gitpod) -> None: configuration = client.runners.configurations.validate() assert_matches_type(ConfigurationValidateResponse, configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_validate_with_all_params(self, client: Gitpod) -> None: configuration = client.runners.configurations.validate( @@ -55,7 +55,7 @@ def test_method_validate_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ConfigurationValidateResponse, configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_validate(self, client: Gitpod) -> None: response = client.runners.configurations.with_raw_response.validate() @@ -65,7 +65,7 @@ def test_raw_response_validate(self, client: Gitpod) -> None: configuration = response.parse() assert_matches_type(ConfigurationValidateResponse, configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_validate(self, client: Gitpod) -> None: with client.runners.configurations.with_streaming_response.validate() as response: @@ -83,13 +83,13 @@ class TestAsyncConfigurations: "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_validate(self, async_client: AsyncGitpod) -> None: configuration = await async_client.runners.configurations.validate() assert_matches_type(ConfigurationValidateResponse, configuration, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_validate_with_all_params(self, async_client: AsyncGitpod) -> None: configuration = await async_client.runners.configurations.validate( @@ -121,7 +121,7 @@ async def test_method_validate_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(ConfigurationValidateResponse, configuration, 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_validate(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.configurations.with_raw_response.validate() @@ -131,7 +131,7 @@ async def test_raw_response_validate(self, async_client: AsyncGitpod) -> None: configuration = await response.parse() assert_matches_type(ConfigurationValidateResponse, configuration, 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_validate(self, async_client: AsyncGitpod) -> None: async with async_client.runners.configurations.with_streaming_response.validate() as response: diff --git a/tests/api_resources/runners/test_policies.py b/tests/api_resources/runners/test_policies.py index 8fa81fa5..a689f4a5 100644 --- a/tests/api_resources/runners/test_policies.py +++ b/tests/api_resources/runners/test_policies.py @@ -22,13 +22,13 @@ class TestPolicies: 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_create(self, client: Gitpod) -> None: policy = client.runners.policies.create() assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: policy = client.runners.policies.create( @@ -38,7 +38,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.runners.policies.with_raw_response.create() @@ -48,7 +48,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.runners.policies.with_streaming_response.create() as response: @@ -60,13 +60,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: policy = client.runners.policies.update() assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: policy = client.runners.policies.update( @@ -76,7 +76,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.runners.policies.with_raw_response.update() @@ -86,7 +86,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.runners.policies.with_streaming_response.update() as response: @@ -98,13 +98,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: policy = client.runners.policies.list() assert_matches_type(SyncPoliciesPage[RunnerPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: policy = client.runners.policies.list( @@ -118,7 +118,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncPoliciesPage[RunnerPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.runners.policies.with_raw_response.list() @@ -128,7 +128,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(SyncPoliciesPage[RunnerPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.runners.policies.with_streaming_response.list() as response: @@ -140,13 +140,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: policy = client.runners.policies.delete() assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: policy = client.runners.policies.delete( @@ -155,7 +155,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.runners.policies.with_raw_response.delete() @@ -165,7 +165,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: policy = response.parse() assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.runners.policies.with_streaming_response.delete() as response: @@ -183,13 +183,13 @@ class TestAsyncPolicies: "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_create(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.create() assert_matches_type(PolicyCreateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.create( @@ -199,7 +199,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(PolicyCreateResponse, policy, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.policies.with_raw_response.create() @@ -209,7 +209,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(PolicyCreateResponse, policy, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.runners.policies.with_streaming_response.create() as response: @@ -221,13 +221,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_update(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.update() assert_matches_type(PolicyUpdateResponse, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.update( @@ -237,7 +237,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(PolicyUpdateResponse, policy, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.policies.with_raw_response.update() @@ -247,7 +247,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(PolicyUpdateResponse, policy, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.runners.policies.with_streaming_response.update() as response: @@ -259,13 +259,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.list() assert_matches_type(AsyncPoliciesPage[RunnerPolicy], policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.list( @@ -279,7 +279,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncPoliciesPage[RunnerPolicy], policy, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.policies.with_raw_response.list() @@ -289,7 +289,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(AsyncPoliciesPage[RunnerPolicy], policy, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.runners.policies.with_streaming_response.list() as response: @@ -301,13 +301,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.delete() assert_matches_type(object, policy, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: policy = await async_client.runners.policies.delete( @@ -316,7 +316,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, policy, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.policies.with_raw_response.delete() @@ -326,7 +326,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: policy = await response.parse() assert_matches_type(object, policy, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.runners.policies.with_streaming_response.delete() as response: diff --git a/tests/api_resources/test_accounts.py b/tests/api_resources/test_accounts.py index 41f2192e..deade9f3 100644 --- a/tests/api_resources/test_accounts.py +++ b/tests/api_resources/test_accounts.py @@ -31,13 +31,13 @@ class TestAccounts: 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_retrieve(self, client: Gitpod) -> None: account = client.accounts.retrieve() assert_matches_type(AccountRetrieveResponse, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: account = client.accounts.retrieve( @@ -45,7 +45,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(AccountRetrieveResponse, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.accounts.with_raw_response.retrieve() @@ -55,7 +55,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: account = response.parse() assert_matches_type(AccountRetrieveResponse, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.accounts.with_streaming_response.retrieve() as response: @@ -67,7 +67,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: account = client.accounts.delete( @@ -75,7 +75,7 @@ def test_method_delete(self, client: Gitpod) -> None: ) assert_matches_type(object, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: account = client.accounts.delete( @@ -84,7 +84,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.accounts.with_raw_response.delete( @@ -96,7 +96,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: account = response.parse() assert_matches_type(object, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.accounts.with_streaming_response.delete( @@ -110,7 +110,7 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_sso_login_url(self, client: Gitpod) -> None: account = client.accounts.get_sso_login_url( @@ -118,7 +118,7 @@ def test_method_get_sso_login_url(self, client: Gitpod) -> None: ) assert_matches_type(AccountGetSSOLoginURLResponse, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_sso_login_url_with_all_params(self, client: Gitpod) -> None: account = client.accounts.get_sso_login_url( @@ -127,7 +127,7 @@ def test_method_get_sso_login_url_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(AccountGetSSOLoginURLResponse, account, 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_sso_login_url(self, client: Gitpod) -> None: response = client.accounts.with_raw_response.get_sso_login_url( @@ -139,7 +139,7 @@ def test_raw_response_get_sso_login_url(self, client: Gitpod) -> None: account = response.parse() assert_matches_type(AccountGetSSOLoginURLResponse, account, 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_sso_login_url(self, client: Gitpod) -> None: with client.accounts.with_streaming_response.get_sso_login_url( @@ -153,13 +153,13 @@ def test_streaming_response_get_sso_login_url(self, client: Gitpod) -> 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_list_joinable_organizations(self, client: Gitpod) -> None: account = client.accounts.list_joinable_organizations() assert_matches_type(SyncJoinableOrganizationsPage[JoinableOrganization], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_joinable_organizations_with_all_params(self, client: Gitpod) -> None: account = client.accounts.list_joinable_organizations( @@ -172,7 +172,7 @@ def test_method_list_joinable_organizations_with_all_params(self, client: Gitpod ) assert_matches_type(SyncJoinableOrganizationsPage[JoinableOrganization], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_joinable_organizations(self, client: Gitpod) -> None: response = client.accounts.with_raw_response.list_joinable_organizations() @@ -182,7 +182,7 @@ def test_raw_response_list_joinable_organizations(self, client: Gitpod) -> None: account = response.parse() assert_matches_type(SyncJoinableOrganizationsPage[JoinableOrganization], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_joinable_organizations(self, client: Gitpod) -> None: with client.accounts.with_streaming_response.list_joinable_organizations() as response: @@ -194,13 +194,13 @@ def test_streaming_response_list_joinable_organizations(self, client: Gitpod) -> 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_list_login_providers(self, client: Gitpod) -> None: account = client.accounts.list_login_providers() assert_matches_type(SyncLoginProvidersPage[LoginProvider], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_login_providers_with_all_params(self, client: Gitpod) -> None: account = client.accounts.list_login_providers( @@ -217,7 +217,7 @@ def test_method_list_login_providers_with_all_params(self, client: Gitpod) -> No ) assert_matches_type(SyncLoginProvidersPage[LoginProvider], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_login_providers(self, client: Gitpod) -> None: response = client.accounts.with_raw_response.list_login_providers() @@ -227,7 +227,7 @@ def test_raw_response_list_login_providers(self, client: Gitpod) -> None: account = response.parse() assert_matches_type(SyncLoginProvidersPage[LoginProvider], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_login_providers(self, client: Gitpod) -> None: with client.accounts.with_streaming_response.list_login_providers() as response: @@ -239,7 +239,7 @@ def test_streaming_response_list_login_providers(self, client: Gitpod) -> 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_list_sso_logins(self, client: Gitpod) -> None: account = client.accounts.list_sso_logins( @@ -247,7 +247,7 @@ def test_method_list_sso_logins(self, client: Gitpod) -> None: ) assert_matches_type(SyncLoginsPage[AccountListSSOLoginsResponse], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_sso_logins_with_all_params(self, client: Gitpod) -> None: account = client.accounts.list_sso_logins( @@ -262,7 +262,7 @@ def test_method_list_sso_logins_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncLoginsPage[AccountListSSOLoginsResponse], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_sso_logins(self, client: Gitpod) -> None: response = client.accounts.with_raw_response.list_sso_logins( @@ -274,7 +274,7 @@ def test_raw_response_list_sso_logins(self, client: Gitpod) -> None: account = response.parse() assert_matches_type(SyncLoginsPage[AccountListSSOLoginsResponse], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_sso_logins(self, client: Gitpod) -> None: with client.accounts.with_streaming_response.list_sso_logins( @@ -294,13 +294,13 @@ class TestAsyncAccounts: "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_retrieve(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.retrieve() assert_matches_type(AccountRetrieveResponse, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.retrieve( @@ -308,7 +308,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(AccountRetrieveResponse, account, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.accounts.with_raw_response.retrieve() @@ -318,7 +318,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: account = await response.parse() assert_matches_type(AccountRetrieveResponse, account, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.accounts.with_streaming_response.retrieve() as response: @@ -330,7 +330,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_delete(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.delete( @@ -338,7 +338,7 @@ async def test_method_delete(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.delete( @@ -347,7 +347,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, account, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.accounts.with_raw_response.delete( @@ -359,7 +359,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: account = await response.parse() assert_matches_type(object, account, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.accounts.with_streaming_response.delete( @@ -373,7 +373,7 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_sso_login_url(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.get_sso_login_url( @@ -381,7 +381,7 @@ async def test_method_get_sso_login_url(self, async_client: AsyncGitpod) -> None ) assert_matches_type(AccountGetSSOLoginURLResponse, account, 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_sso_login_url_with_all_params(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.get_sso_login_url( @@ -390,7 +390,7 @@ async def test_method_get_sso_login_url_with_all_params(self, async_client: Asyn ) assert_matches_type(AccountGetSSOLoginURLResponse, account, 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_sso_login_url(self, async_client: AsyncGitpod) -> None: response = await async_client.accounts.with_raw_response.get_sso_login_url( @@ -402,7 +402,7 @@ async def test_raw_response_get_sso_login_url(self, async_client: AsyncGitpod) - account = await response.parse() assert_matches_type(AccountGetSSOLoginURLResponse, account, 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_sso_login_url(self, async_client: AsyncGitpod) -> None: async with async_client.accounts.with_streaming_response.get_sso_login_url( @@ -416,13 +416,13 @@ async def test_streaming_response_get_sso_login_url(self, async_client: AsyncGit 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_list_joinable_organizations(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.list_joinable_organizations() assert_matches_type(AsyncJoinableOrganizationsPage[JoinableOrganization], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_joinable_organizations_with_all_params(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.list_joinable_organizations( @@ -435,7 +435,7 @@ async def test_method_list_joinable_organizations_with_all_params(self, async_cl ) assert_matches_type(AsyncJoinableOrganizationsPage[JoinableOrganization], account, 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_list_joinable_organizations(self, async_client: AsyncGitpod) -> None: response = await async_client.accounts.with_raw_response.list_joinable_organizations() @@ -445,7 +445,7 @@ async def test_raw_response_list_joinable_organizations(self, async_client: Asyn account = await response.parse() assert_matches_type(AsyncJoinableOrganizationsPage[JoinableOrganization], account, 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_list_joinable_organizations(self, async_client: AsyncGitpod) -> None: async with async_client.accounts.with_streaming_response.list_joinable_organizations() as response: @@ -457,13 +457,13 @@ async def test_streaming_response_list_joinable_organizations(self, async_client 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_list_login_providers(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.list_login_providers() assert_matches_type(AsyncLoginProvidersPage[LoginProvider], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_login_providers_with_all_params(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.list_login_providers( @@ -480,7 +480,7 @@ async def test_method_list_login_providers_with_all_params(self, async_client: A ) assert_matches_type(AsyncLoginProvidersPage[LoginProvider], account, 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_list_login_providers(self, async_client: AsyncGitpod) -> None: response = await async_client.accounts.with_raw_response.list_login_providers() @@ -490,7 +490,7 @@ async def test_raw_response_list_login_providers(self, async_client: AsyncGitpod account = await response.parse() assert_matches_type(AsyncLoginProvidersPage[LoginProvider], account, 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_list_login_providers(self, async_client: AsyncGitpod) -> None: async with async_client.accounts.with_streaming_response.list_login_providers() as response: @@ -502,7 +502,7 @@ async def test_streaming_response_list_login_providers(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_method_list_sso_logins(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.list_sso_logins( @@ -510,7 +510,7 @@ async def test_method_list_sso_logins(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(AsyncLoginsPage[AccountListSSOLoginsResponse], account, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_sso_logins_with_all_params(self, async_client: AsyncGitpod) -> None: account = await async_client.accounts.list_sso_logins( @@ -525,7 +525,7 @@ async def test_method_list_sso_logins_with_all_params(self, async_client: AsyncG ) assert_matches_type(AsyncLoginsPage[AccountListSSOLoginsResponse], account, 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_list_sso_logins(self, async_client: AsyncGitpod) -> None: response = await async_client.accounts.with_raw_response.list_sso_logins( @@ -537,7 +537,7 @@ async def test_raw_response_list_sso_logins(self, async_client: AsyncGitpod) -> account = await response.parse() assert_matches_type(AsyncLoginsPage[AccountListSSOLoginsResponse], account, 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_list_sso_logins(self, async_client: AsyncGitpod) -> None: async with async_client.accounts.with_streaming_response.list_sso_logins( diff --git a/tests/api_resources/test_agents.py b/tests/api_resources/test_agents.py index 979d8ae1..857f285b 100644 --- a/tests/api_resources/test_agents.py +++ b/tests/api_resources/test_agents.py @@ -28,13 +28,13 @@ class TestAgents: 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_create_execution_conversation_token(self, client: Gitpod) -> None: agent = client.agents.create_execution_conversation_token() assert_matches_type(AgentCreateExecutionConversationTokenResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_execution_conversation_token_with_all_params(self, client: Gitpod) -> None: agent = client.agents.create_execution_conversation_token( @@ -42,7 +42,7 @@ def test_method_create_execution_conversation_token_with_all_params(self, client ) assert_matches_type(AgentCreateExecutionConversationTokenResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_execution_conversation_token(self, client: Gitpod) -> None: response = client.agents.with_raw_response.create_execution_conversation_token() @@ -52,7 +52,7 @@ def test_raw_response_create_execution_conversation_token(self, client: Gitpod) agent = response.parse() assert_matches_type(AgentCreateExecutionConversationTokenResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_execution_conversation_token(self, client: Gitpod) -> None: with client.agents.with_streaming_response.create_execution_conversation_token() as response: @@ -64,13 +64,13 @@ def test_streaming_response_create_execution_conversation_token(self, client: Gi 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_create_prompt(self, client: Gitpod) -> None: agent = client.agents.create_prompt() assert_matches_type(AgentCreatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_prompt_with_all_params(self, client: Gitpod) -> None: agent = client.agents.create_prompt( @@ -84,7 +84,7 @@ def test_method_create_prompt_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(AgentCreatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_prompt(self, client: Gitpod) -> None: response = client.agents.with_raw_response.create_prompt() @@ -94,7 +94,7 @@ def test_raw_response_create_prompt(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(AgentCreatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_prompt(self, client: Gitpod) -> None: with client.agents.with_streaming_response.create_prompt() as response: @@ -106,13 +106,13 @@ def test_streaming_response_create_prompt(self, client: Gitpod) -> 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_delete_execution(self, client: Gitpod) -> None: agent = client.agents.delete_execution() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_execution_with_all_params(self, client: Gitpod) -> None: agent = client.agents.delete_execution( @@ -120,7 +120,7 @@ def test_method_delete_execution_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete_execution(self, client: Gitpod) -> None: response = client.agents.with_raw_response.delete_execution() @@ -130,7 +130,7 @@ def test_raw_response_delete_execution(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete_execution(self, client: Gitpod) -> None: with client.agents.with_streaming_response.delete_execution() as response: @@ -142,13 +142,13 @@ def test_streaming_response_delete_execution(self, client: Gitpod) -> 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_delete_prompt(self, client: Gitpod) -> None: agent = client.agents.delete_prompt() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_prompt_with_all_params(self, client: Gitpod) -> None: agent = client.agents.delete_prompt( @@ -156,7 +156,7 @@ def test_method_delete_prompt_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete_prompt(self, client: Gitpod) -> None: response = client.agents.with_raw_response.delete_prompt() @@ -166,7 +166,7 @@ def test_raw_response_delete_prompt(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete_prompt(self, client: Gitpod) -> None: with client.agents.with_streaming_response.delete_prompt() as response: @@ -178,13 +178,13 @@ def test_streaming_response_delete_prompt(self, client: Gitpod) -> 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_list_executions(self, client: Gitpod) -> None: agent = client.agents.list_executions() assert_matches_type(SyncAgentExecutionsPage[AgentExecution], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_executions_with_all_params(self, client: Gitpod) -> None: agent = client.agents.list_executions( @@ -206,7 +206,7 @@ def test_method_list_executions_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncAgentExecutionsPage[AgentExecution], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_executions(self, client: Gitpod) -> None: response = client.agents.with_raw_response.list_executions() @@ -216,7 +216,7 @@ def test_raw_response_list_executions(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(SyncAgentExecutionsPage[AgentExecution], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_executions(self, client: Gitpod) -> None: with client.agents.with_streaming_response.list_executions() as response: @@ -228,13 +228,13 @@ def test_streaming_response_list_executions(self, client: Gitpod) -> 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_list_prompts(self, client: Gitpod) -> None: agent = client.agents.list_prompts() assert_matches_type(SyncPromptsPage[Prompt], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_prompts_with_all_params(self, client: Gitpod) -> None: agent = client.agents.list_prompts( @@ -243,6 +243,7 @@ def test_method_list_prompts_with_all_params(self, client: Gitpod) -> None: filter={ "command": "command", "command_prefix": "commandPrefix", + "exclude_prompt_content": True, "is_command": True, "is_skill": True, "is_template": True, @@ -254,7 +255,7 @@ def test_method_list_prompts_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncPromptsPage[Prompt], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_prompts(self, client: Gitpod) -> None: response = client.agents.with_raw_response.list_prompts() @@ -264,7 +265,7 @@ def test_raw_response_list_prompts(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(SyncPromptsPage[Prompt], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_prompts(self, client: Gitpod) -> None: with client.agents.with_streaming_response.list_prompts() as response: @@ -276,13 +277,13 @@ def test_streaming_response_list_prompts(self, client: Gitpod) -> 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_retrieve_execution(self, client: Gitpod) -> None: agent = client.agents.retrieve_execution() assert_matches_type(AgentRetrieveExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_execution_with_all_params(self, client: Gitpod) -> None: agent = client.agents.retrieve_execution( @@ -290,7 +291,7 @@ def test_method_retrieve_execution_with_all_params(self, client: Gitpod) -> None ) assert_matches_type(AgentRetrieveExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve_execution(self, client: Gitpod) -> None: response = client.agents.with_raw_response.retrieve_execution() @@ -300,7 +301,7 @@ def test_raw_response_retrieve_execution(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(AgentRetrieveExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve_execution(self, client: Gitpod) -> None: with client.agents.with_streaming_response.retrieve_execution() as response: @@ -312,13 +313,13 @@ def test_streaming_response_retrieve_execution(self, client: Gitpod) -> 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_retrieve_prompt(self, client: Gitpod) -> None: agent = client.agents.retrieve_prompt() assert_matches_type(AgentRetrievePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_prompt_with_all_params(self, client: Gitpod) -> None: agent = client.agents.retrieve_prompt( @@ -326,7 +327,7 @@ def test_method_retrieve_prompt_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(AgentRetrievePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve_prompt(self, client: Gitpod) -> None: response = client.agents.with_raw_response.retrieve_prompt() @@ -336,7 +337,7 @@ def test_raw_response_retrieve_prompt(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(AgentRetrievePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve_prompt(self, client: Gitpod) -> None: with client.agents.with_streaming_response.retrieve_prompt() as response: @@ -348,17 +349,21 @@ def test_streaming_response_retrieve_prompt(self, client: Gitpod) -> 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_send_to_execution(self, client: Gitpod) -> None: agent = client.agents.send_to_execution() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_send_to_execution_with_all_params(self, client: Gitpod) -> None: agent = client.agents.send_to_execution( agent_execution_id="6fa1a3c7-fbb7-49d1-ba56-1890dc7c4c35", + agent_message={ + "payload": "payload", + "type": "TYPE_UNSPECIFIED", + }, user_input={ "id": "id", "created_at": parse_datetime("2019-12-27T18:11:19.117Z"), @@ -377,10 +382,14 @@ def test_method_send_to_execution_with_all_params(self, client: Gitpod) -> None: ], "text": {"content": "Generate a report based on the latest logs."}, }, + wake_event={ + "timer": {"fired_at": parse_datetime("2019-12-27T18:11:19.117Z")}, + "interest_id": "interestId", + }, ) assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_send_to_execution(self, client: Gitpod) -> None: response = client.agents.with_raw_response.send_to_execution() @@ -390,7 +399,7 @@ def test_raw_response_send_to_execution(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_send_to_execution(self, client: Gitpod) -> None: with client.agents.with_streaming_response.send_to_execution() as response: @@ -402,13 +411,13 @@ def test_streaming_response_send_to_execution(self, client: Gitpod) -> 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_start_execution(self, client: Gitpod) -> None: agent = client.agents.start_execution() assert_matches_type(AgentStartExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_start_execution_with_all_params(self, client: Gitpod) -> None: agent = client.agents.start_execution( @@ -441,11 +450,12 @@ def test_method_start_execution_with_all_params(self, client: Gitpod) -> None: mode="AGENT_MODE_UNSPECIFIED", name="name", runner_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + session_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", workflow_action_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", ) assert_matches_type(AgentStartExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_start_execution(self, client: Gitpod) -> None: response = client.agents.with_raw_response.start_execution() @@ -455,7 +465,7 @@ def test_raw_response_start_execution(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(AgentStartExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_start_execution(self, client: Gitpod) -> None: with client.agents.with_streaming_response.start_execution() as response: @@ -467,13 +477,13 @@ def test_streaming_response_start_execution(self, client: Gitpod) -> 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_stop_execution(self, client: Gitpod) -> None: agent = client.agents.stop_execution() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_stop_execution_with_all_params(self, client: Gitpod) -> None: agent = client.agents.stop_execution( @@ -481,7 +491,7 @@ def test_method_stop_execution_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_stop_execution(self, client: Gitpod) -> None: response = client.agents.with_raw_response.stop_execution() @@ -491,7 +501,7 @@ def test_raw_response_stop_execution(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_stop_execution(self, client: Gitpod) -> None: with client.agents.with_streaming_response.stop_execution() as response: @@ -503,13 +513,13 @@ def test_streaming_response_stop_execution(self, client: Gitpod) -> 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_update_prompt(self, client: Gitpod) -> None: agent = client.agents.update_prompt() assert_matches_type(AgentUpdatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_prompt_with_all_params(self, client: Gitpod) -> None: agent = client.agents.update_prompt( @@ -528,7 +538,7 @@ def test_method_update_prompt_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(AgentUpdatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update_prompt(self, client: Gitpod) -> None: response = client.agents.with_raw_response.update_prompt() @@ -538,7 +548,7 @@ def test_raw_response_update_prompt(self, client: Gitpod) -> None: agent = response.parse() assert_matches_type(AgentUpdatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update_prompt(self, client: Gitpod) -> None: with client.agents.with_streaming_response.update_prompt() as response: @@ -556,13 +566,13 @@ class TestAsyncAgents: "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_create_execution_conversation_token(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.create_execution_conversation_token() assert_matches_type(AgentCreateExecutionConversationTokenResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_execution_conversation_token_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.create_execution_conversation_token( @@ -570,7 +580,7 @@ async def test_method_create_execution_conversation_token_with_all_params(self, ) assert_matches_type(AgentCreateExecutionConversationTokenResponse, agent, 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_create_execution_conversation_token(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.create_execution_conversation_token() @@ -580,7 +590,7 @@ async def test_raw_response_create_execution_conversation_token(self, async_clie agent = await response.parse() assert_matches_type(AgentCreateExecutionConversationTokenResponse, agent, 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_create_execution_conversation_token(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.create_execution_conversation_token() as response: @@ -592,13 +602,13 @@ async def test_streaming_response_create_execution_conversation_token(self, asyn 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_create_prompt(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.create_prompt() assert_matches_type(AgentCreatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_prompt_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.create_prompt( @@ -612,7 +622,7 @@ async def test_method_create_prompt_with_all_params(self, async_client: AsyncGit ) assert_matches_type(AgentCreatePromptResponse, agent, 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_create_prompt(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.create_prompt() @@ -622,7 +632,7 @@ async def test_raw_response_create_prompt(self, async_client: AsyncGitpod) -> No agent = await response.parse() assert_matches_type(AgentCreatePromptResponse, agent, 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_create_prompt(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.create_prompt() as response: @@ -634,13 +644,13 @@ async def test_streaming_response_create_prompt(self, async_client: AsyncGitpod) 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_delete_execution(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.delete_execution() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_execution_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.delete_execution( @@ -648,7 +658,7 @@ async def test_method_delete_execution_with_all_params(self, async_client: Async ) assert_matches_type(object, agent, 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_delete_execution(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.delete_execution() @@ -658,7 +668,7 @@ async def test_raw_response_delete_execution(self, async_client: AsyncGitpod) -> agent = await response.parse() assert_matches_type(object, agent, 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_delete_execution(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.delete_execution() as response: @@ -670,13 +680,13 @@ async def test_streaming_response_delete_execution(self, async_client: AsyncGitp 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_delete_prompt(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.delete_prompt() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_prompt_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.delete_prompt( @@ -684,7 +694,7 @@ async def test_method_delete_prompt_with_all_params(self, async_client: AsyncGit ) assert_matches_type(object, agent, 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_delete_prompt(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.delete_prompt() @@ -694,7 +704,7 @@ async def test_raw_response_delete_prompt(self, async_client: AsyncGitpod) -> No agent = await response.parse() assert_matches_type(object, agent, 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_delete_prompt(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.delete_prompt() as response: @@ -706,13 +716,13 @@ async def test_streaming_response_delete_prompt(self, async_client: AsyncGitpod) 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_list_executions(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.list_executions() assert_matches_type(AsyncAgentExecutionsPage[AgentExecution], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_executions_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.list_executions( @@ -734,7 +744,7 @@ async def test_method_list_executions_with_all_params(self, async_client: AsyncG ) assert_matches_type(AsyncAgentExecutionsPage[AgentExecution], agent, 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_list_executions(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.list_executions() @@ -744,7 +754,7 @@ async def test_raw_response_list_executions(self, async_client: AsyncGitpod) -> agent = await response.parse() assert_matches_type(AsyncAgentExecutionsPage[AgentExecution], agent, 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_list_executions(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.list_executions() as response: @@ -756,13 +766,13 @@ async def test_streaming_response_list_executions(self, async_client: AsyncGitpo 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_list_prompts(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.list_prompts() assert_matches_type(AsyncPromptsPage[Prompt], agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_prompts_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.list_prompts( @@ -771,6 +781,7 @@ async def test_method_list_prompts_with_all_params(self, async_client: AsyncGitp filter={ "command": "command", "command_prefix": "commandPrefix", + "exclude_prompt_content": True, "is_command": True, "is_skill": True, "is_template": True, @@ -782,7 +793,7 @@ async def test_method_list_prompts_with_all_params(self, async_client: AsyncGitp ) assert_matches_type(AsyncPromptsPage[Prompt], agent, 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_list_prompts(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.list_prompts() @@ -792,7 +803,7 @@ async def test_raw_response_list_prompts(self, async_client: AsyncGitpod) -> Non agent = await response.parse() assert_matches_type(AsyncPromptsPage[Prompt], agent, 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_list_prompts(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.list_prompts() as response: @@ -804,13 +815,13 @@ async def test_streaming_response_list_prompts(self, async_client: AsyncGitpod) 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_retrieve_execution(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.retrieve_execution() assert_matches_type(AgentRetrieveExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_execution_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.retrieve_execution( @@ -818,7 +829,7 @@ async def test_method_retrieve_execution_with_all_params(self, async_client: Asy ) assert_matches_type(AgentRetrieveExecutionResponse, agent, 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_retrieve_execution(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.retrieve_execution() @@ -828,7 +839,7 @@ async def test_raw_response_retrieve_execution(self, async_client: AsyncGitpod) agent = await response.parse() assert_matches_type(AgentRetrieveExecutionResponse, agent, 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_retrieve_execution(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.retrieve_execution() as response: @@ -840,13 +851,13 @@ async def test_streaming_response_retrieve_execution(self, async_client: AsyncGi 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_retrieve_prompt(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.retrieve_prompt() assert_matches_type(AgentRetrievePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_prompt_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.retrieve_prompt( @@ -854,7 +865,7 @@ async def test_method_retrieve_prompt_with_all_params(self, async_client: AsyncG ) assert_matches_type(AgentRetrievePromptResponse, agent, 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_retrieve_prompt(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.retrieve_prompt() @@ -864,7 +875,7 @@ async def test_raw_response_retrieve_prompt(self, async_client: AsyncGitpod) -> agent = await response.parse() assert_matches_type(AgentRetrievePromptResponse, agent, 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_retrieve_prompt(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.retrieve_prompt() as response: @@ -876,17 +887,21 @@ async def test_streaming_response_retrieve_prompt(self, async_client: AsyncGitpo 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_send_to_execution(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.send_to_execution() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_send_to_execution_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.send_to_execution( agent_execution_id="6fa1a3c7-fbb7-49d1-ba56-1890dc7c4c35", + agent_message={ + "payload": "payload", + "type": "TYPE_UNSPECIFIED", + }, user_input={ "id": "id", "created_at": parse_datetime("2019-12-27T18:11:19.117Z"), @@ -905,10 +920,14 @@ async def test_method_send_to_execution_with_all_params(self, async_client: Asyn ], "text": {"content": "Generate a report based on the latest logs."}, }, + wake_event={ + "timer": {"fired_at": parse_datetime("2019-12-27T18:11:19.117Z")}, + "interest_id": "interestId", + }, ) assert_matches_type(object, agent, 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_send_to_execution(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.send_to_execution() @@ -918,7 +937,7 @@ async def test_raw_response_send_to_execution(self, async_client: AsyncGitpod) - agent = await response.parse() assert_matches_type(object, agent, 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_send_to_execution(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.send_to_execution() as response: @@ -930,13 +949,13 @@ async def test_streaming_response_send_to_execution(self, async_client: AsyncGit 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_start_execution(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.start_execution() assert_matches_type(AgentStartExecutionResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_start_execution_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.start_execution( @@ -969,11 +988,12 @@ async def test_method_start_execution_with_all_params(self, async_client: AsyncG mode="AGENT_MODE_UNSPECIFIED", name="name", runner_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + session_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", workflow_action_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", ) assert_matches_type(AgentStartExecutionResponse, agent, 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_start_execution(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.start_execution() @@ -983,7 +1003,7 @@ async def test_raw_response_start_execution(self, async_client: AsyncGitpod) -> agent = await response.parse() assert_matches_type(AgentStartExecutionResponse, agent, 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_start_execution(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.start_execution() as response: @@ -995,13 +1015,13 @@ async def test_streaming_response_start_execution(self, async_client: AsyncGitpo 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_stop_execution(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.stop_execution() assert_matches_type(object, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_stop_execution_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.stop_execution( @@ -1009,7 +1029,7 @@ async def test_method_stop_execution_with_all_params(self, async_client: AsyncGi ) assert_matches_type(object, agent, 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_stop_execution(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.stop_execution() @@ -1019,7 +1039,7 @@ async def test_raw_response_stop_execution(self, async_client: AsyncGitpod) -> N agent = await response.parse() assert_matches_type(object, agent, 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_stop_execution(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.stop_execution() as response: @@ -1031,13 +1051,13 @@ async def test_streaming_response_stop_execution(self, async_client: AsyncGitpod 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_update_prompt(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.update_prompt() assert_matches_type(AgentUpdatePromptResponse, agent, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_prompt_with_all_params(self, async_client: AsyncGitpod) -> None: agent = await async_client.agents.update_prompt( @@ -1056,7 +1076,7 @@ async def test_method_update_prompt_with_all_params(self, async_client: AsyncGit ) assert_matches_type(AgentUpdatePromptResponse, agent, 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_update_prompt(self, async_client: AsyncGitpod) -> None: response = await async_client.agents.with_raw_response.update_prompt() @@ -1066,7 +1086,7 @@ async def test_raw_response_update_prompt(self, async_client: AsyncGitpod) -> No agent = await response.parse() assert_matches_type(AgentUpdatePromptResponse, agent, 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_update_prompt(self, async_client: AsyncGitpod) -> None: async with async_client.agents.with_streaming_response.update_prompt() as response: diff --git a/tests/api_resources/test_automations.py b/tests/api_resources/test_automations.py new file mode 100644 index 00000000..e9a5fa93 --- /dev/null +++ b/tests/api_resources/test_automations.py @@ -0,0 +1,1549 @@ +# File generated from our OpenAPI spec by Stainless. See CONTRIBUTING.md for details. + +from __future__ import annotations + +import os +from typing import Any, cast + +import pytest + +from gitpod import Gitpod, AsyncGitpod +from tests.utils import assert_matches_type +from gitpod.types import ( + Workflow, + WorkflowExecution, + WorkflowExecutionAction, + AutomationCreateResponse, + AutomationUpdateResponse, + AutomationRetrieveResponse, + AutomationStartExecutionResponse, + AutomationRetrieveExecutionResponse, + AutomationListExecutionOutputsResponse, + AutomationRetrieveExecutionActionResponse, +) +from gitpod.pagination import ( + SyncOutputsPage, + AsyncOutputsPage, + SyncWorkflowsPage, + AsyncWorkflowsPage, + SyncWorkflowExecutionsPage, + AsyncWorkflowExecutionsPage, + SyncWorkflowExecutionActionsPage, + AsyncWorkflowExecutionActionsPage, +) + +base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010") + + +class TestAutomations: + parametrize = pytest.mark.parametrize("client", [False, True], indirect=True, ids=["loose", "strict"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_create(self, client: Gitpod) -> None: + automation = client.automations.create( + action={"limits": {}}, + ) + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_create_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.create( + action={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + description="description", + executor={ + "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "principal": "PRINCIPAL_UNSPECIFIED", + }, + name="name", + report={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + triggers=[ + { + "context": { + "agent": {"prompt": "prompt"}, + "from_trigger": {}, + "projects": {"project_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"]}, + "repositories": { + "environment_class_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "repo_selector": { + "repo_search_string": "x", + "scm_host": "x", + }, + "repository_urls": {"repo_urls": ["x"]}, + }, + }, + "manual": {}, + "pull_request": { + "events": ["PULL_REQUEST_EVENT_UNSPECIFIED"], + "webhook_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + }, + "time": {"cron_expression": "cronExpression"}, + } + ], + ) + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_create(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.create( + action={"limits": {}}, + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_create(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.create( + action={"limits": {}}, + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_retrieve(self, client: Gitpod) -> None: + automation = client.automations.retrieve() + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.retrieve( + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_retrieve(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.retrieve() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_retrieve(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.retrieve() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_update(self, client: Gitpod) -> None: + automation = client.automations.update() + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_update_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.update( + action={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + description="description", + executor={ + "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "principal": "PRINCIPAL_UNSPECIFIED", + }, + name="name", + report={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + triggers=[ + { + "context": { + "agent": {"prompt": "prompt"}, + "from_trigger": {}, + "projects": {"project_ids": ["new-project-id"]}, + "repositories": { + "environment_class_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "repo_selector": { + "repo_search_string": "x", + "scm_host": "x", + }, + "repository_urls": {"repo_urls": ["x"]}, + }, + }, + "manual": {}, + "pull_request": { + "events": ["PULL_REQUEST_EVENT_UNSPECIFIED"], + "webhook_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + }, + "time": {"cron_expression": "cronExpression"}, + } + ], + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_update(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.update() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_update(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.update() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list(self, client: Gitpod) -> None: + automation = client.automations.list() + assert_matches_type(SyncWorkflowsPage[Workflow], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.list( + token="token", + page_size=0, + filter={ + "creator_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "search": "search", + "status_phases": ["WORKFLOW_EXECUTION_PHASE_UNSPECIFIED"], + "workflow_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + }, + pagination={ + "token": "token", + "page_size": 100, + }, + ) + assert_matches_type(SyncWorkflowsPage[Workflow], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_list(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.list() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(SyncWorkflowsPage[Workflow], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_list(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.list() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(SyncWorkflowsPage[Workflow], automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_delete(self, client: Gitpod) -> None: + automation = client.automations.delete() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_delete_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.delete( + force=True, + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_delete(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.delete() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_delete(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.delete() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(object, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_cancel_execution(self, client: Gitpod) -> None: + automation = client.automations.cancel_execution() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_cancel_execution_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.cancel_execution( + workflow_execution_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + ) + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_cancel_execution(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.cancel_execution() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_cancel_execution(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.cancel_execution() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(object, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_cancel_execution_action(self, client: Gitpod) -> None: + automation = client.automations.cancel_execution_action() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_cancel_execution_action_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.cancel_execution_action( + workflow_execution_action_id="a1b2c3d4-5e6f-7890-abcd-ef1234567890", + ) + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_cancel_execution_action(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.cancel_execution_action() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_cancel_execution_action(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.cancel_execution_action() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(object, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_execution_actions(self, client: Gitpod) -> None: + automation = client.automations.list_execution_actions() + assert_matches_type(SyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_execution_actions_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.list_execution_actions( + token="token", + page_size=0, + filter={ + "phases": ["WORKFLOW_EXECUTION_ACTION_PHASE_UNSPECIFIED"], + "workflow_execution_action_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "workflow_execution_ids": ["d2c94c27-3b76-4a42-b88c-95a85e392c68"], + "workflow_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + }, + pagination={ + "token": "token", + "page_size": 20, + }, + ) + assert_matches_type(SyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_list_execution_actions(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.list_execution_actions() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(SyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_list_execution_actions(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.list_execution_actions() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type( + SyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"] + ) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_execution_outputs(self, client: Gitpod) -> None: + automation = client.automations.list_execution_outputs() + assert_matches_type(SyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_execution_outputs_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.list_execution_outputs( + token="token", + page_size=0, + filter={"workflow_execution_ids": ["d2c94c27-3b76-4a42-b88c-95a85e392c68"]}, + pagination={ + "token": "token", + "page_size": 50, + }, + ) + assert_matches_type(SyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_list_execution_outputs(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.list_execution_outputs() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(SyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_list_execution_outputs(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.list_execution_outputs() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(SyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_executions(self, client: Gitpod) -> None: + automation = client.automations.list_executions() + assert_matches_type(SyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_executions_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.list_executions( + token="token", + page_size=0, + filter={ + "has_failed_actions": True, + "search": "search", + "status_phases": ["WORKFLOW_EXECUTION_PHASE_UNSPECIFIED"], + "workflow_execution_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "workflow_ids": ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"], + }, + pagination={ + "token": "token", + "page_size": 20, + }, + sort={ + "field": "field", + "order": "SORT_ORDER_UNSPECIFIED", + }, + ) + assert_matches_type(SyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_list_executions(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.list_executions() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(SyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_list_executions(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.list_executions() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(SyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_retrieve_execution(self, client: Gitpod) -> None: + automation = client.automations.retrieve_execution() + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_retrieve_execution_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.retrieve_execution( + workflow_execution_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + ) + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_retrieve_execution(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.retrieve_execution() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_retrieve_execution(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.retrieve_execution() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_retrieve_execution_action(self, client: Gitpod) -> None: + automation = client.automations.retrieve_execution_action() + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_retrieve_execution_action_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.retrieve_execution_action( + workflow_execution_action_id="a1b2c3d4-5e6f-7890-abcd-ef1234567890", + ) + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_retrieve_execution_action(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.retrieve_execution_action() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_retrieve_execution_action(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.retrieve_execution_action() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_start_execution(self, client: Gitpod) -> None: + automation = client.automations.start_execution() + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_start_execution_with_all_params(self, client: Gitpod) -> None: + automation = client.automations.start_execution( + context_override={ + "agent": {"prompt": "prompt"}, + "from_trigger": {}, + "projects": {"project_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"]}, + "repositories": { + "environment_class_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "repo_selector": { + "repo_search_string": "x", + "scm_host": "x", + }, + "repository_urls": {"repo_urls": ["x"]}, + }, + }, + parameters={"foo": "string"}, + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_start_execution(self, client: Gitpod) -> None: + response = client.automations.with_raw_response.start_execution() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = response.parse() + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_start_execution(self, client: Gitpod) -> None: + with client.automations.with_streaming_response.start_execution() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = response.parse() + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + +class TestAsyncAutomations: + parametrize = pytest.mark.parametrize( + "async_client", [False, True, {"http_client": "aiohttp"}], indirect=True, ids=["loose", "strict", "aiohttp"] + ) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_create(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.create( + action={"limits": {}}, + ) + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.create( + action={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + description="description", + executor={ + "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "principal": "PRINCIPAL_UNSPECIFIED", + }, + name="name", + report={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + triggers=[ + { + "context": { + "agent": {"prompt": "prompt"}, + "from_trigger": {}, + "projects": {"project_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"]}, + "repositories": { + "environment_class_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "repo_selector": { + "repo_search_string": "x", + "scm_host": "x", + }, + "repository_urls": {"repo_urls": ["x"]}, + }, + }, + "manual": {}, + "pull_request": { + "events": ["PULL_REQUEST_EVENT_UNSPECIFIED"], + "webhook_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + }, + "time": {"cron_expression": "cronExpression"}, + } + ], + ) + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.create( + action={"limits": {}}, + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_create(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.create( + action={"limits": {}}, + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AutomationCreateResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.retrieve() + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.retrieve( + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.retrieve() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.retrieve() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AutomationRetrieveResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_update(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.update() + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.update( + action={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + description="description", + executor={ + "id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "principal": "PRINCIPAL_UNSPECIFIED", + }, + name="name", + report={ + "limits": { + "max_parallel": 0, + "max_total": 0, + "per_execution": {"max_time": "+9125115.360s"}, + }, + "steps": [ + { + "agent": {"prompt": "prompt"}, + "pull_request": { + "branch": "branch", + "description": "description", + "draft": True, + "title": "title", + }, + "report": { + "outputs": [ + { + "acceptance_criteria": "acceptanceCriteria", + "boolean": {}, + "command": "command", + "float": { + "max": 0, + "min": 0, + }, + "integer": { + "max": 0, + "min": 0, + }, + "key": "key", + "prompt": "prompt", + "string": {"pattern": "pattern"}, + "title": "title", + } + ] + }, + "task": {"command": "command"}, + } + ], + }, + triggers=[ + { + "context": { + "agent": {"prompt": "prompt"}, + "from_trigger": {}, + "projects": {"project_ids": ["new-project-id"]}, + "repositories": { + "environment_class_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "repo_selector": { + "repo_search_string": "x", + "scm_host": "x", + }, + "repository_urls": {"repo_urls": ["x"]}, + }, + }, + "manual": {}, + "pull_request": { + "events": ["PULL_REQUEST_EVENT_UNSPECIFIED"], + "webhook_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + }, + "time": {"cron_expression": "cronExpression"}, + } + ], + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.update() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_update(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.update() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AutomationUpdateResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list() + assert_matches_type(AsyncWorkflowsPage[Workflow], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list( + token="token", + page_size=0, + filter={ + "creator_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "search": "search", + "status_phases": ["WORKFLOW_EXECUTION_PHASE_UNSPECIFIED"], + "workflow_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + }, + pagination={ + "token": "token", + "page_size": 100, + }, + ) + assert_matches_type(AsyncWorkflowsPage[Workflow], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.list() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AsyncWorkflowsPage[Workflow], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_list(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.list() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AsyncWorkflowsPage[Workflow], automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_delete(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.delete() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.delete( + force=True, + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.delete() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.delete() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(object, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_cancel_execution(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.cancel_execution() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_cancel_execution_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.cancel_execution( + workflow_execution_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + ) + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_cancel_execution(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.cancel_execution() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_cancel_execution(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.cancel_execution() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(object, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_cancel_execution_action(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.cancel_execution_action() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_cancel_execution_action_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.cancel_execution_action( + workflow_execution_action_id="a1b2c3d4-5e6f-7890-abcd-ef1234567890", + ) + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_cancel_execution_action(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.cancel_execution_action() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(object, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_cancel_execution_action(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.cancel_execution_action() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(object, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_execution_actions(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list_execution_actions() + assert_matches_type(AsyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_execution_actions_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list_execution_actions( + token="token", + page_size=0, + filter={ + "phases": ["WORKFLOW_EXECUTION_ACTION_PHASE_UNSPECIFIED"], + "workflow_execution_action_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "workflow_execution_ids": ["d2c94c27-3b76-4a42-b88c-95a85e392c68"], + "workflow_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + }, + pagination={ + "token": "token", + "page_size": 20, + }, + ) + assert_matches_type(AsyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_list_execution_actions(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.list_execution_actions() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AsyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_list_execution_actions(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.list_execution_actions() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type( + AsyncWorkflowExecutionActionsPage[WorkflowExecutionAction], automation, path=["response"] + ) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_execution_outputs(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list_execution_outputs() + assert_matches_type(AsyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_execution_outputs_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list_execution_outputs( + token="token", + page_size=0, + filter={"workflow_execution_ids": ["d2c94c27-3b76-4a42-b88c-95a85e392c68"]}, + pagination={ + "token": "token", + "page_size": 50, + }, + ) + assert_matches_type(AsyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_list_execution_outputs(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.list_execution_outputs() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AsyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_list_execution_outputs(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.list_execution_outputs() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AsyncOutputsPage[AutomationListExecutionOutputsResponse], automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_executions(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list_executions() + assert_matches_type(AsyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_executions_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.list_executions( + token="token", + page_size=0, + filter={ + "has_failed_actions": True, + "search": "search", + "status_phases": ["WORKFLOW_EXECUTION_PHASE_UNSPECIFIED"], + "workflow_execution_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "workflow_ids": ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"], + }, + pagination={ + "token": "token", + "page_size": 20, + }, + sort={ + "field": "field", + "order": "SORT_ORDER_UNSPECIFIED", + }, + ) + assert_matches_type(AsyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_list_executions(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.list_executions() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AsyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_list_executions(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.list_executions() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AsyncWorkflowExecutionsPage[WorkflowExecution], automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_retrieve_execution(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.retrieve_execution() + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_retrieve_execution_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.retrieve_execution( + workflow_execution_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + ) + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_retrieve_execution(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.retrieve_execution() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_retrieve_execution(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.retrieve_execution() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AutomationRetrieveExecutionResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_retrieve_execution_action(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.retrieve_execution_action() + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_retrieve_execution_action_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.retrieve_execution_action( + workflow_execution_action_id="a1b2c3d4-5e6f-7890-abcd-ef1234567890", + ) + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_retrieve_execution_action(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.retrieve_execution_action() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_retrieve_execution_action(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.retrieve_execution_action() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AutomationRetrieveExecutionActionResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_start_execution(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.start_execution() + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_start_execution_with_all_params(self, async_client: AsyncGitpod) -> None: + automation = await async_client.automations.start_execution( + context_override={ + "agent": {"prompt": "prompt"}, + "from_trigger": {}, + "projects": {"project_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"]}, + "repositories": { + "environment_class_id": "182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", + "repo_selector": { + "repo_search_string": "x", + "scm_host": "x", + }, + "repository_urls": {"repo_urls": ["x"]}, + }, + }, + parameters={"foo": "string"}, + workflow_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_start_execution(self, async_client: AsyncGitpod) -> None: + response = await async_client.automations.with_raw_response.start_execution() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + automation = await response.parse() + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_start_execution(self, async_client: AsyncGitpod) -> None: + async with async_client.automations.with_streaming_response.start_execution() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + automation = await response.parse() + assert_matches_type(AutomationStartExecutionResponse, automation, path=["response"]) + + assert cast(Any, response.is_closed) is True diff --git a/tests/api_resources/test_editors.py b/tests/api_resources/test_editors.py index 5a6ebcd0..d2a2bcba 100644 --- a/tests/api_resources/test_editors.py +++ b/tests/api_resources/test_editors.py @@ -22,7 +22,7 @@ class TestEditors: 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_retrieve(self, client: Gitpod) -> None: editor = client.editors.retrieve( @@ -30,7 +30,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(EditorRetrieveResponse, editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.editors.with_raw_response.retrieve( @@ -42,7 +42,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: editor = response.parse() assert_matches_type(EditorRetrieveResponse, editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.editors.with_streaming_response.retrieve( @@ -56,13 +56,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: editor = client.editors.list() assert_matches_type(SyncEditorsPage[Editor], editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: editor = client.editors.list( @@ -76,7 +76,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncEditorsPage[Editor], editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.editors.with_raw_response.list() @@ -86,7 +86,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: editor = response.parse() assert_matches_type(SyncEditorsPage[Editor], editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.editors.with_streaming_response.list() as response: @@ -98,7 +98,7 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_resolve_url(self, client: Gitpod) -> None: editor = client.editors.resolve_url( @@ -108,7 +108,7 @@ def test_method_resolve_url(self, client: Gitpod) -> None: ) assert_matches_type(EditorResolveURLResponse, editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_resolve_url_with_all_params(self, client: Gitpod) -> None: editor = client.editors.resolve_url( @@ -119,7 +119,7 @@ def test_method_resolve_url_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(EditorResolveURLResponse, editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_resolve_url(self, client: Gitpod) -> None: response = client.editors.with_raw_response.resolve_url( @@ -133,7 +133,7 @@ def test_raw_response_resolve_url(self, client: Gitpod) -> None: editor = response.parse() assert_matches_type(EditorResolveURLResponse, editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_resolve_url(self, client: Gitpod) -> None: with client.editors.with_streaming_response.resolve_url( @@ -155,7 +155,7 @@ class TestAsyncEditors: "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_retrieve(self, async_client: AsyncGitpod) -> None: editor = await async_client.editors.retrieve( @@ -163,7 +163,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(EditorRetrieveResponse, editor, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.editors.with_raw_response.retrieve( @@ -175,7 +175,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: editor = await response.parse() assert_matches_type(EditorRetrieveResponse, editor, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.editors.with_streaming_response.retrieve( @@ -189,13 +189,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_list(self, async_client: AsyncGitpod) -> None: editor = await async_client.editors.list() assert_matches_type(AsyncEditorsPage[Editor], editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: editor = await async_client.editors.list( @@ -209,7 +209,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncEditorsPage[Editor], editor, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.editors.with_raw_response.list() @@ -219,7 +219,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: editor = await response.parse() assert_matches_type(AsyncEditorsPage[Editor], editor, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.editors.with_streaming_response.list() as response: @@ -231,7 +231,7 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_resolve_url(self, async_client: AsyncGitpod) -> None: editor = await async_client.editors.resolve_url( @@ -241,7 +241,7 @@ async def test_method_resolve_url(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(EditorResolveURLResponse, editor, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_resolve_url_with_all_params(self, async_client: AsyncGitpod) -> None: editor = await async_client.editors.resolve_url( @@ -252,7 +252,7 @@ async def test_method_resolve_url_with_all_params(self, async_client: AsyncGitpo ) assert_matches_type(EditorResolveURLResponse, editor, 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_resolve_url(self, async_client: AsyncGitpod) -> None: response = await async_client.editors.with_raw_response.resolve_url( @@ -266,7 +266,7 @@ async def test_raw_response_resolve_url(self, async_client: AsyncGitpod) -> None editor = await response.parse() assert_matches_type(EditorResolveURLResponse, editor, 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_resolve_url(self, async_client: AsyncGitpod) -> None: async with async_client.editors.with_streaming_response.resolve_url( diff --git a/tests/api_resources/test_environments.py b/tests/api_resources/test_environments.py index 869f22c1..5d6ba940 100644 --- a/tests/api_resources/test_environments.py +++ b/tests/api_resources/test_environments.py @@ -26,17 +26,18 @@ class TestEnvironments: 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_create(self, client: Gitpod) -> None: environment = client.environments.create() assert_matches_type(EnvironmentCreateResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: environment = client.environments.create( name="name", + session_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", spec={ "admission": "ADMISSION_LEVEL_UNSPECIFIED", "automations_file": { @@ -129,7 +130,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(EnvironmentCreateResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.environments.with_raw_response.create() @@ -139,7 +140,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(EnvironmentCreateResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.environments.with_streaming_response.create() as response: @@ -151,7 +152,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: environment = client.environments.retrieve( @@ -159,7 +160,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(EnvironmentRetrieveResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.environments.with_raw_response.retrieve( @@ -171,7 +172,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(EnvironmentRetrieveResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.environments.with_streaming_response.retrieve( @@ -185,13 +186,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: environment = client.environments.update() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: environment = client.environments.update( @@ -253,7 +254,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.environments.with_raw_response.update() @@ -263,7 +264,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.environments.with_streaming_response.update() as response: @@ -275,13 +276,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: environment = client.environments.list() assert_matches_type(SyncEnvironmentsPage[Environment], environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: environment = client.environments.list( @@ -304,7 +305,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncEnvironmentsPage[Environment], environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.environments.with_raw_response.list() @@ -314,7 +315,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(SyncEnvironmentsPage[Environment], environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.environments.with_streaming_response.list() as response: @@ -326,13 +327,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: environment = client.environments.delete() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: environment = client.environments.delete( @@ -341,7 +342,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.environments.with_raw_response.delete() @@ -351,7 +352,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.environments.with_streaming_response.delete() as response: @@ -363,7 +364,7 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_create_environment_token(self, client: Gitpod) -> None: environment = client.environments.create_environment_token( @@ -371,7 +372,7 @@ def test_method_create_environment_token(self, client: Gitpod) -> None: ) assert_matches_type(EnvironmentCreateEnvironmentTokenResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_environment_token(self, client: Gitpod) -> None: response = client.environments.with_raw_response.create_environment_token( @@ -383,7 +384,7 @@ def test_raw_response_create_environment_token(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(EnvironmentCreateEnvironmentTokenResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_environment_token(self, client: Gitpod) -> None: with client.environments.with_streaming_response.create_environment_token( @@ -397,13 +398,13 @@ def test_streaming_response_create_environment_token(self, client: Gitpod) -> No 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_create_from_project(self, client: Gitpod) -> None: environment = client.environments.create_from_project() assert_matches_type(EnvironmentCreateFromProjectResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_from_project_with_all_params(self, client: Gitpod) -> None: environment = client.environments.create_from_project( @@ -501,7 +502,7 @@ def test_method_create_from_project_with_all_params(self, client: Gitpod) -> Non ) assert_matches_type(EnvironmentCreateFromProjectResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_from_project(self, client: Gitpod) -> None: response = client.environments.with_raw_response.create_from_project() @@ -511,7 +512,7 @@ def test_raw_response_create_from_project(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(EnvironmentCreateFromProjectResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_from_project(self, client: Gitpod) -> None: with client.environments.with_streaming_response.create_from_project() as response: @@ -523,13 +524,13 @@ def test_streaming_response_create_from_project(self, client: Gitpod) -> 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_create_logs_token(self, client: Gitpod) -> None: environment = client.environments.create_logs_token() assert_matches_type(EnvironmentCreateLogsTokenResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_logs_token_with_all_params(self, client: Gitpod) -> None: environment = client.environments.create_logs_token( @@ -537,7 +538,7 @@ def test_method_create_logs_token_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(EnvironmentCreateLogsTokenResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_logs_token(self, client: Gitpod) -> None: response = client.environments.with_raw_response.create_logs_token() @@ -547,7 +548,7 @@ def test_raw_response_create_logs_token(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(EnvironmentCreateLogsTokenResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_logs_token(self, client: Gitpod) -> None: with client.environments.with_streaming_response.create_logs_token() as response: @@ -559,13 +560,13 @@ def test_streaming_response_create_logs_token(self, client: Gitpod) -> 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_mark_active(self, client: Gitpod) -> None: environment = client.environments.mark_active() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_mark_active_with_all_params(self, client: Gitpod) -> None: environment = client.environments.mark_active( @@ -577,7 +578,7 @@ def test_method_mark_active_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_mark_active(self, client: Gitpod) -> None: response = client.environments.with_raw_response.mark_active() @@ -587,7 +588,7 @@ def test_raw_response_mark_active(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_mark_active(self, client: Gitpod) -> None: with client.environments.with_streaming_response.mark_active() as response: @@ -599,13 +600,13 @@ def test_streaming_response_mark_active(self, client: Gitpod) -> 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_start(self, client: Gitpod) -> None: environment = client.environments.start() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_start_with_all_params(self, client: Gitpod) -> None: environment = client.environments.start( @@ -613,7 +614,7 @@ def test_method_start_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_start(self, client: Gitpod) -> None: response = client.environments.with_raw_response.start() @@ -623,7 +624,7 @@ def test_raw_response_start(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_start(self, client: Gitpod) -> None: with client.environments.with_streaming_response.start() as response: @@ -635,13 +636,13 @@ def test_streaming_response_start(self, client: Gitpod) -> 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_stop(self, client: Gitpod) -> None: environment = client.environments.stop() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_stop_with_all_params(self, client: Gitpod) -> None: environment = client.environments.stop( @@ -649,7 +650,7 @@ def test_method_stop_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_stop(self, client: Gitpod) -> None: response = client.environments.with_raw_response.stop() @@ -659,7 +660,7 @@ def test_raw_response_stop(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_stop(self, client: Gitpod) -> None: with client.environments.with_streaming_response.stop() as response: @@ -671,13 +672,13 @@ def test_streaming_response_stop(self, client: Gitpod) -> 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_unarchive(self, client: Gitpod) -> None: environment = client.environments.unarchive() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_unarchive_with_all_params(self, client: Gitpod) -> None: environment = client.environments.unarchive( @@ -685,7 +686,7 @@ def test_method_unarchive_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_unarchive(self, client: Gitpod) -> None: response = client.environments.with_raw_response.unarchive() @@ -695,7 +696,7 @@ def test_raw_response_unarchive(self, client: Gitpod) -> None: environment = response.parse() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_unarchive(self, client: Gitpod) -> None: with client.environments.with_streaming_response.unarchive() as response: @@ -713,17 +714,18 @@ class TestAsyncEnvironments: "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_create(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.create() assert_matches_type(EnvironmentCreateResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.create( name="name", + session_id="182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e", spec={ "admission": "ADMISSION_LEVEL_UNSPECIFIED", "automations_file": { @@ -816,7 +818,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(EnvironmentCreateResponse, environment, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.create() @@ -826,7 +828,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(EnvironmentCreateResponse, environment, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.create() as response: @@ -838,7 +840,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.retrieve( @@ -846,7 +848,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(EnvironmentRetrieveResponse, environment, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.retrieve( @@ -858,7 +860,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(EnvironmentRetrieveResponse, environment, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.retrieve( @@ -872,13 +874,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.update() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.update( @@ -940,7 +942,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, environment, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.update() @@ -950,7 +952,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(object, environment, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.update() as response: @@ -962,13 +964,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.list() assert_matches_type(AsyncEnvironmentsPage[Environment], environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.list( @@ -991,7 +993,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncEnvironmentsPage[Environment], environment, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.list() @@ -1001,7 +1003,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(AsyncEnvironmentsPage[Environment], environment, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.list() as response: @@ -1013,13 +1015,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.delete() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.delete( @@ -1028,7 +1030,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, environment, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.delete() @@ -1038,7 +1040,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(object, environment, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.delete() as response: @@ -1050,7 +1052,7 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_create_environment_token(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.create_environment_token( @@ -1058,7 +1060,7 @@ async def test_method_create_environment_token(self, async_client: AsyncGitpod) ) assert_matches_type(EnvironmentCreateEnvironmentTokenResponse, environment, 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_create_environment_token(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.create_environment_token( @@ -1070,7 +1072,7 @@ async def test_raw_response_create_environment_token(self, async_client: AsyncGi environment = await response.parse() assert_matches_type(EnvironmentCreateEnvironmentTokenResponse, environment, 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_create_environment_token(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.create_environment_token( @@ -1084,13 +1086,13 @@ async def test_streaming_response_create_environment_token(self, async_client: A 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_create_from_project(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.create_from_project() assert_matches_type(EnvironmentCreateFromProjectResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_from_project_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.create_from_project( @@ -1188,7 +1190,7 @@ async def test_method_create_from_project_with_all_params(self, async_client: As ) assert_matches_type(EnvironmentCreateFromProjectResponse, environment, 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_create_from_project(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.create_from_project() @@ -1198,7 +1200,7 @@ async def test_raw_response_create_from_project(self, async_client: AsyncGitpod) environment = await response.parse() assert_matches_type(EnvironmentCreateFromProjectResponse, environment, 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_create_from_project(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.create_from_project() as response: @@ -1210,13 +1212,13 @@ async def test_streaming_response_create_from_project(self, async_client: AsyncG 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_create_logs_token(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.create_logs_token() assert_matches_type(EnvironmentCreateLogsTokenResponse, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_logs_token_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.create_logs_token( @@ -1224,7 +1226,7 @@ async def test_method_create_logs_token_with_all_params(self, async_client: Asyn ) assert_matches_type(EnvironmentCreateLogsTokenResponse, environment, 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_create_logs_token(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.create_logs_token() @@ -1234,7 +1236,7 @@ async def test_raw_response_create_logs_token(self, async_client: AsyncGitpod) - environment = await response.parse() assert_matches_type(EnvironmentCreateLogsTokenResponse, environment, 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_create_logs_token(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.create_logs_token() as response: @@ -1246,13 +1248,13 @@ async def test_streaming_response_create_logs_token(self, async_client: AsyncGit 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_mark_active(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.mark_active() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_mark_active_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.mark_active( @@ -1264,7 +1266,7 @@ async def test_method_mark_active_with_all_params(self, async_client: AsyncGitpo ) assert_matches_type(object, environment, 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_mark_active(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.mark_active() @@ -1274,7 +1276,7 @@ async def test_raw_response_mark_active(self, async_client: AsyncGitpod) -> None environment = await response.parse() assert_matches_type(object, environment, 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_mark_active(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.mark_active() as response: @@ -1286,13 +1288,13 @@ async def test_streaming_response_mark_active(self, async_client: AsyncGitpod) - 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_start(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.start() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_start_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.start( @@ -1300,7 +1302,7 @@ async def test_method_start_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, environment, 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_start(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.start() @@ -1310,7 +1312,7 @@ async def test_raw_response_start(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(object, environment, 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_start(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.start() as response: @@ -1322,13 +1324,13 @@ async def test_streaming_response_start(self, async_client: AsyncGitpod) -> 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 async def test_method_stop(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.stop() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_stop_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.stop( @@ -1336,7 +1338,7 @@ async def test_method_stop_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(object, environment, 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_stop(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.stop() @@ -1346,7 +1348,7 @@ async def test_raw_response_stop(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(object, environment, 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_stop(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.stop() as response: @@ -1358,13 +1360,13 @@ async def test_streaming_response_stop(self, async_client: AsyncGitpod) -> 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 async def test_method_unarchive(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.unarchive() assert_matches_type(object, environment, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_unarchive_with_all_params(self, async_client: AsyncGitpod) -> None: environment = await async_client.environments.unarchive( @@ -1372,7 +1374,7 @@ async def test_method_unarchive_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(object, environment, 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_unarchive(self, async_client: AsyncGitpod) -> None: response = await async_client.environments.with_raw_response.unarchive() @@ -1382,7 +1384,7 @@ async def test_raw_response_unarchive(self, async_client: AsyncGitpod) -> None: environment = await response.parse() assert_matches_type(object, environment, 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_unarchive(self, async_client: AsyncGitpod) -> None: async with async_client.environments.with_streaming_response.unarchive() as response: diff --git a/tests/api_resources/test_errors.py b/tests/api_resources/test_errors.py index 4cc33cae..5e342a29 100644 --- a/tests/api_resources/test_errors.py +++ b/tests/api_resources/test_errors.py @@ -17,13 +17,13 @@ class TestErrors: 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_report_errors(self, client: Gitpod) -> None: error = client.errors.report_errors() assert_matches_type(object, error, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_report_errors_with_all_params(self, client: Gitpod) -> None: error = client.errors.report_errors( @@ -95,7 +95,7 @@ def test_method_report_errors_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, error, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_report_errors(self, client: Gitpod) -> None: response = client.errors.with_raw_response.report_errors() @@ -105,7 +105,7 @@ def test_raw_response_report_errors(self, client: Gitpod) -> None: error = response.parse() assert_matches_type(object, error, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_report_errors(self, client: Gitpod) -> None: with client.errors.with_streaming_response.report_errors() as response: @@ -123,13 +123,13 @@ class TestAsyncErrors: "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_report_errors(self, async_client: AsyncGitpod) -> None: error = await async_client.errors.report_errors() assert_matches_type(object, error, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_report_errors_with_all_params(self, async_client: AsyncGitpod) -> None: error = await async_client.errors.report_errors( @@ -201,7 +201,7 @@ async def test_method_report_errors_with_all_params(self, async_client: AsyncGit ) assert_matches_type(object, error, 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_report_errors(self, async_client: AsyncGitpod) -> None: response = await async_client.errors.with_raw_response.report_errors() @@ -211,7 +211,7 @@ async def test_raw_response_report_errors(self, async_client: AsyncGitpod) -> No error = await response.parse() assert_matches_type(object, error, 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_report_errors(self, async_client: AsyncGitpod) -> None: async with async_client.errors.with_streaming_response.report_errors() as response: diff --git a/tests/api_resources/test_events.py b/tests/api_resources/test_events.py index 64aff13d..dc84a57e 100644 --- a/tests/api_resources/test_events.py +++ b/tests/api_resources/test_events.py @@ -10,8 +10,8 @@ from gitpod import Gitpod, AsyncGitpod from tests.utils import assert_matches_type from gitpod.types import EventListResponse, EventWatchResponse +from gitpod._utils import parse_datetime from gitpod.pagination import SyncEntriesPage, AsyncEntriesPage -from gitpod._decoders.jsonl import JSONLDecoder, AsyncJSONLDecoder base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010") @@ -19,13 +19,13 @@ class TestEvents: 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_list(self, client: Gitpod) -> None: event = client.events.list() assert_matches_type(SyncEntriesPage[EventListResponse], event, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: event = client.events.list( @@ -34,17 +34,23 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: filter={ "actor_ids": ["d2c94c27-3b76-4a42-b88c-95a85e392c68"], "actor_principals": ["PRINCIPAL_USER"], + "from": parse_datetime("2019-12-27T18:11:19.117Z"), "subject_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], "subject_types": ["RESOURCE_TYPE_UNSPECIFIED"], + "to": parse_datetime("2019-12-27T18:11:19.117Z"), }, pagination={ "token": "token", "page_size": 20, }, + sort={ + "field": "field", + "order": "SORT_ORDER_UNSPECIFIED", + }, ) assert_matches_type(SyncEntriesPage[EventListResponse], event, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.events.with_raw_response.list() @@ -54,7 +60,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: event = response.parse() assert_matches_type(SyncEntriesPage[EventListResponse], event, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.events.with_streaming_response.list() as response: @@ -66,31 +72,41 @@ def test_streaming_response_list(self, client: Gitpod) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_watch(self, client: Gitpod) -> None: event_stream = client.events.watch() - assert_matches_type(JSONLDecoder[EventWatchResponse], event_stream, path=["response"]) + for item in event_stream: + assert_matches_type(EventWatchResponse, item, path=["response"]) - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_watch_with_all_params(self, client: Gitpod) -> None: event_stream = client.events.watch( environment_id="environmentId", organization=True, + resource_type_filters=[ + { + "creator_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "resource_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "resource_type": "RESOURCE_TYPE_UNSPECIFIED", + } + ], ) - assert_matches_type(JSONLDecoder[EventWatchResponse], event_stream, path=["response"]) + for item in event_stream: + assert_matches_type(EventWatchResponse, item, path=["response"]) - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_watch(self, client: Gitpod) -> None: response = client.events.with_raw_response.watch() assert response.http_request.headers.get("X-Stainless-Lang") == "python" stream = response.parse() - stream.close() + for item in stream: + assert_matches_type(EventWatchResponse, item, path=["line"]) - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_watch(self, client: Gitpod) -> None: with client.events.with_streaming_response.watch() as response: @@ -98,7 +114,8 @@ def test_streaming_response_watch(self, client: Gitpod) -> None: assert response.http_request.headers.get("X-Stainless-Lang") == "python" stream = response.parse() - stream.close() + for item in stream: + assert_matches_type(EventWatchResponse, item, path=["item"]) assert cast(Any, response.is_closed) is True @@ -108,13 +125,13 @@ class TestAsyncEvents: "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_list(self, async_client: AsyncGitpod) -> None: event = await async_client.events.list() assert_matches_type(AsyncEntriesPage[EventListResponse], event, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: event = await async_client.events.list( @@ -123,17 +140,23 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N filter={ "actor_ids": ["d2c94c27-3b76-4a42-b88c-95a85e392c68"], "actor_principals": ["PRINCIPAL_USER"], + "from": parse_datetime("2019-12-27T18:11:19.117Z"), "subject_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], "subject_types": ["RESOURCE_TYPE_UNSPECIFIED"], + "to": parse_datetime("2019-12-27T18:11:19.117Z"), }, pagination={ "token": "token", "page_size": 20, }, + sort={ + "field": "field", + "order": "SORT_ORDER_UNSPECIFIED", + }, ) assert_matches_type(AsyncEntriesPage[EventListResponse], event, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.events.with_raw_response.list() @@ -143,7 +166,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: event = await response.parse() assert_matches_type(AsyncEntriesPage[EventListResponse], event, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.events.with_streaming_response.list() as response: @@ -155,31 +178,41 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> None: assert cast(Any, response.is_closed) is True - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_watch(self, async_client: AsyncGitpod) -> None: event_stream = await async_client.events.watch() - assert_matches_type(AsyncJSONLDecoder[EventWatchResponse], event_stream, path=["response"]) + async for item in event_stream: + assert_matches_type(EventWatchResponse, item, path=["response"]) - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_watch_with_all_params(self, async_client: AsyncGitpod) -> None: event_stream = await async_client.events.watch( environment_id="environmentId", organization=True, + resource_type_filters=[ + { + "creator_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "resource_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "resource_type": "RESOURCE_TYPE_UNSPECIFIED", + } + ], ) - assert_matches_type(AsyncJSONLDecoder[EventWatchResponse], event_stream, path=["response"]) + async for item in event_stream: + assert_matches_type(EventWatchResponse, item, path=["response"]) - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_raw_response_watch(self, async_client: AsyncGitpod) -> None: response = await async_client.events.with_raw_response.watch() assert response.http_request.headers.get("X-Stainless-Lang") == "python" stream = await response.parse() - await stream.close() + async for item in stream: + assert_matches_type(EventWatchResponse, item, path=["line"]) - @pytest.mark.skip(reason="Prism doesn't support application/jsonl responses") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_streaming_response_watch(self, async_client: AsyncGitpod) -> None: async with async_client.events.with_streaming_response.watch() as response: @@ -187,6 +220,7 @@ async def test_streaming_response_watch(self, async_client: AsyncGitpod) -> None assert response.http_request.headers.get("X-Stainless-Lang") == "python" stream = await response.parse() - await stream.close() + async for item in stream: + assert_matches_type(EventWatchResponse, item, path=["item"]) assert cast(Any, response.is_closed) is True diff --git a/tests/api_resources/test_gateways.py b/tests/api_resources/test_gateways.py index b18ceec7..9896a40b 100644 --- a/tests/api_resources/test_gateways.py +++ b/tests/api_resources/test_gateways.py @@ -18,13 +18,13 @@ class TestGateways: 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_list(self, client: Gitpod) -> None: gateway = client.gateways.list() assert_matches_type(SyncGatewaysPage[Gateway], gateway, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: gateway = client.gateways.list( @@ -37,7 +37,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncGatewaysPage[Gateway], gateway, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.gateways.with_raw_response.list() @@ -47,7 +47,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: gateway = response.parse() assert_matches_type(SyncGatewaysPage[Gateway], gateway, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.gateways.with_streaming_response.list() as response: @@ -65,13 +65,13 @@ class TestAsyncGateways: "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_list(self, async_client: AsyncGitpod) -> None: gateway = await async_client.gateways.list() assert_matches_type(AsyncGatewaysPage[Gateway], gateway, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: gateway = await async_client.gateways.list( @@ -84,7 +84,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncGatewaysPage[Gateway], gateway, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.gateways.with_raw_response.list() @@ -94,7 +94,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: gateway = await response.parse() assert_matches_type(AsyncGatewaysPage[Gateway], gateway, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.gateways.with_streaming_response.list() as response: diff --git a/tests/api_resources/test_groups.py b/tests/api_resources/test_groups.py index 4a8a1bb4..9e478183 100644 --- a/tests/api_resources/test_groups.py +++ b/tests/api_resources/test_groups.py @@ -23,13 +23,13 @@ class TestGroups: 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_create(self, client: Gitpod) -> None: group = client.groups.create() assert_matches_type(GroupCreateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: group = client.groups.create( @@ -39,7 +39,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(GroupCreateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.groups.with_raw_response.create() @@ -49,7 +49,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: group = response.parse() assert_matches_type(GroupCreateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.groups.with_streaming_response.create() as response: @@ -61,13 +61,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: group = client.groups.retrieve() assert_matches_type(GroupRetrieveResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: group = client.groups.retrieve( @@ -75,7 +75,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(GroupRetrieveResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.groups.with_raw_response.retrieve() @@ -85,7 +85,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: group = response.parse() assert_matches_type(GroupRetrieveResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.groups.with_streaming_response.retrieve() as response: @@ -97,13 +97,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: group = client.groups.update() assert_matches_type(GroupUpdateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: group = client.groups.update( @@ -113,7 +113,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(GroupUpdateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.groups.with_raw_response.update() @@ -123,7 +123,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: group = response.parse() assert_matches_type(GroupUpdateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.groups.with_streaming_response.update() as response: @@ -135,18 +135,19 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: group = client.groups.list() assert_matches_type(SyncGroupsPage[Group], group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: group = client.groups.list( token="token", page_size=0, + filter={"search": "search"}, pagination={ "token": "token", "page_size": 20, @@ -154,7 +155,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncGroupsPage[Group], group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.groups.with_raw_response.list() @@ -164,7 +165,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: group = response.parse() assert_matches_type(SyncGroupsPage[Group], group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.groups.with_streaming_response.list() as response: @@ -176,13 +177,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: group = client.groups.delete() assert_matches_type(object, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: group = client.groups.delete( @@ -190,7 +191,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.groups.with_raw_response.delete() @@ -200,7 +201,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: group = response.parse() assert_matches_type(object, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.groups.with_streaming_response.delete() as response: @@ -218,13 +219,13 @@ class TestAsyncGroups: "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_create(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.create() assert_matches_type(GroupCreateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.create( @@ -234,7 +235,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(GroupCreateResponse, group, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.with_raw_response.create() @@ -244,7 +245,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: group = await response.parse() assert_matches_type(GroupCreateResponse, group, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.groups.with_streaming_response.create() as response: @@ -256,13 +257,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.retrieve() assert_matches_type(GroupRetrieveResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.retrieve( @@ -270,7 +271,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(GroupRetrieveResponse, group, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.with_raw_response.retrieve() @@ -280,7 +281,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: group = await response.parse() assert_matches_type(GroupRetrieveResponse, group, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.groups.with_streaming_response.retrieve() as response: @@ -292,13 +293,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.update() assert_matches_type(GroupUpdateResponse, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.update( @@ -308,7 +309,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(GroupUpdateResponse, group, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.with_raw_response.update() @@ -318,7 +319,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: group = await response.parse() assert_matches_type(GroupUpdateResponse, group, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.groups.with_streaming_response.update() as response: @@ -330,18 +331,19 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.list() assert_matches_type(AsyncGroupsPage[Group], group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.list( token="token", page_size=0, + filter={"search": "search"}, pagination={ "token": "token", "page_size": 20, @@ -349,7 +351,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncGroupsPage[Group], group, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.with_raw_response.list() @@ -359,7 +361,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: group = await response.parse() assert_matches_type(AsyncGroupsPage[Group], group, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.groups.with_streaming_response.list() as response: @@ -371,13 +373,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.delete() assert_matches_type(object, group, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: group = await async_client.groups.delete( @@ -385,7 +387,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, group, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.groups.with_raw_response.delete() @@ -395,7 +397,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: group = await response.parse() assert_matches_type(object, group, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.groups.with_streaming_response.delete() as response: diff --git a/tests/api_resources/test_identity.py b/tests/api_resources/test_identity.py index de7afdff..a3a45017 100644 --- a/tests/api_resources/test_identity.py +++ b/tests/api_resources/test_identity.py @@ -21,13 +21,13 @@ class TestIdentity: 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_exchange_token(self, client: Gitpod) -> None: identity = client.identity.exchange_token() assert_matches_type(IdentityExchangeTokenResponse, identity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_exchange_token_with_all_params(self, client: Gitpod) -> None: identity = client.identity.exchange_token( @@ -35,7 +35,7 @@ def test_method_exchange_token_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(IdentityExchangeTokenResponse, identity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_exchange_token(self, client: Gitpod) -> None: response = client.identity.with_raw_response.exchange_token() @@ -45,7 +45,7 @@ def test_raw_response_exchange_token(self, client: Gitpod) -> None: identity = response.parse() assert_matches_type(IdentityExchangeTokenResponse, identity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_exchange_token(self, client: Gitpod) -> None: with client.identity.with_streaming_response.exchange_token() as response: @@ -57,13 +57,13 @@ def test_streaming_response_exchange_token(self, client: Gitpod) -> 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_authenticated_identity(self, client: Gitpod) -> None: identity = client.identity.get_authenticated_identity() assert_matches_type(IdentityGetAuthenticatedIdentityResponse, identity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_authenticated_identity_with_all_params(self, client: Gitpod) -> None: identity = client.identity.get_authenticated_identity( @@ -71,7 +71,7 @@ def test_method_get_authenticated_identity_with_all_params(self, client: Gitpod) ) assert_matches_type(IdentityGetAuthenticatedIdentityResponse, identity, 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_authenticated_identity(self, client: Gitpod) -> None: response = client.identity.with_raw_response.get_authenticated_identity() @@ -81,7 +81,7 @@ def test_raw_response_get_authenticated_identity(self, client: Gitpod) -> None: identity = response.parse() assert_matches_type(IdentityGetAuthenticatedIdentityResponse, identity, 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_authenticated_identity(self, client: Gitpod) -> None: with client.identity.with_streaming_response.get_authenticated_identity() as response: @@ -93,13 +93,13 @@ def test_streaming_response_get_authenticated_identity(self, client: Gitpod) -> 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_token(self, client: Gitpod) -> None: identity = client.identity.get_id_token() assert_matches_type(IdentityGetIDTokenResponse, identity, 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_token_with_all_params(self, client: Gitpod) -> None: identity = client.identity.get_id_token( @@ -108,7 +108,7 @@ def test_method_get_id_token_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(IdentityGetIDTokenResponse, identity, 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_token(self, client: Gitpod) -> None: response = client.identity.with_raw_response.get_id_token() @@ -118,7 +118,7 @@ def test_raw_response_get_id_token(self, client: Gitpod) -> None: identity = response.parse() assert_matches_type(IdentityGetIDTokenResponse, identity, 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_token(self, client: Gitpod) -> None: with client.identity.with_streaming_response.get_id_token() as response: @@ -136,13 +136,13 @@ class TestAsyncIdentity: "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_exchange_token(self, async_client: AsyncGitpod) -> None: identity = await async_client.identity.exchange_token() assert_matches_type(IdentityExchangeTokenResponse, identity, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_exchange_token_with_all_params(self, async_client: AsyncGitpod) -> None: identity = await async_client.identity.exchange_token( @@ -150,7 +150,7 @@ async def test_method_exchange_token_with_all_params(self, async_client: AsyncGi ) assert_matches_type(IdentityExchangeTokenResponse, identity, 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_exchange_token(self, async_client: AsyncGitpod) -> None: response = await async_client.identity.with_raw_response.exchange_token() @@ -160,7 +160,7 @@ async def test_raw_response_exchange_token(self, async_client: AsyncGitpod) -> N identity = await response.parse() assert_matches_type(IdentityExchangeTokenResponse, identity, 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_exchange_token(self, async_client: AsyncGitpod) -> None: async with async_client.identity.with_streaming_response.exchange_token() as response: @@ -172,13 +172,13 @@ async def test_streaming_response_exchange_token(self, async_client: AsyncGitpod 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_authenticated_identity(self, async_client: AsyncGitpod) -> None: identity = await async_client.identity.get_authenticated_identity() assert_matches_type(IdentityGetAuthenticatedIdentityResponse, identity, 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_authenticated_identity_with_all_params(self, async_client: AsyncGitpod) -> None: identity = await async_client.identity.get_authenticated_identity( @@ -186,7 +186,7 @@ async def test_method_get_authenticated_identity_with_all_params(self, async_cli ) assert_matches_type(IdentityGetAuthenticatedIdentityResponse, identity, 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_authenticated_identity(self, async_client: AsyncGitpod) -> None: response = await async_client.identity.with_raw_response.get_authenticated_identity() @@ -196,7 +196,7 @@ async def test_raw_response_get_authenticated_identity(self, async_client: Async identity = await response.parse() assert_matches_type(IdentityGetAuthenticatedIdentityResponse, identity, 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_authenticated_identity(self, async_client: AsyncGitpod) -> None: async with async_client.identity.with_streaming_response.get_authenticated_identity() as response: @@ -208,13 +208,13 @@ async def test_streaming_response_get_authenticated_identity(self, async_client: 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_token(self, async_client: AsyncGitpod) -> None: identity = await async_client.identity.get_id_token() assert_matches_type(IdentityGetIDTokenResponse, identity, 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_token_with_all_params(self, async_client: AsyncGitpod) -> None: identity = await async_client.identity.get_id_token( @@ -223,7 +223,7 @@ async def test_method_get_id_token_with_all_params(self, async_client: AsyncGitp ) assert_matches_type(IdentityGetIDTokenResponse, identity, 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_token(self, async_client: AsyncGitpod) -> None: response = await async_client.identity.with_raw_response.get_id_token() @@ -233,7 +233,7 @@ async def test_raw_response_get_id_token(self, async_client: AsyncGitpod) -> Non identity = await response.parse() assert_matches_type(IdentityGetIDTokenResponse, identity, 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_token(self, async_client: AsyncGitpod) -> None: async with async_client.identity.with_streaming_response.get_id_token() as response: diff --git a/tests/api_resources/test_organizations.py b/tests/api_resources/test_organizations.py index a8653c7c..18299d24 100644 --- a/tests/api_resources/test_organizations.py +++ b/tests/api_resources/test_organizations.py @@ -24,7 +24,7 @@ class TestOrganizations: 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_create(self, client: Gitpod) -> None: organization = client.organizations.create( @@ -32,7 +32,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(OrganizationCreateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: organization = client.organizations.create( @@ -42,7 +42,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(OrganizationCreateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.create( @@ -54,7 +54,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(OrganizationCreateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.create( @@ -68,7 +68,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: organization = client.organizations.retrieve( @@ -76,7 +76,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(OrganizationRetrieveResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.retrieve( @@ -88,7 +88,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(OrganizationRetrieveResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.retrieve( @@ -102,7 +102,7 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: organization = client.organizations.update( @@ -110,7 +110,7 @@ def test_method_update(self, client: Gitpod) -> None: ) assert_matches_type(OrganizationUpdateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: organization = client.organizations.update( @@ -120,7 +120,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(OrganizationUpdateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.update( @@ -132,7 +132,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(OrganizationUpdateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.update( @@ -146,7 +146,7 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: organization = client.organizations.delete( @@ -154,7 +154,7 @@ def test_method_delete(self, client: Gitpod) -> None: ) assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.delete( @@ -166,7 +166,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.delete( @@ -180,13 +180,13 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_join(self, client: Gitpod) -> None: organization = client.organizations.join() assert_matches_type(OrganizationJoinResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_join_with_all_params(self, client: Gitpod) -> None: organization = client.organizations.join( @@ -195,7 +195,7 @@ def test_method_join_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(OrganizationJoinResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_join(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.join() @@ -205,7 +205,7 @@ def test_raw_response_join(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(OrganizationJoinResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_join(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.join() as response: @@ -217,7 +217,7 @@ def test_streaming_response_join(self, client: Gitpod) -> 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_leave(self, client: Gitpod) -> None: organization = client.organizations.leave( @@ -225,7 +225,7 @@ def test_method_leave(self, client: Gitpod) -> None: ) assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_leave(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.leave( @@ -237,7 +237,7 @@ def test_raw_response_leave(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_leave(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.leave( @@ -251,7 +251,7 @@ def test_streaming_response_leave(self, client: Gitpod) -> 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_list_members(self, client: Gitpod) -> None: organization = client.organizations.list_members( @@ -259,7 +259,7 @@ def test_method_list_members(self, client: Gitpod) -> None: ) assert_matches_type(SyncMembersPage[OrganizationMember], organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_members_with_all_params(self, client: Gitpod) -> None: organization = client.organizations.list_members( @@ -284,7 +284,7 @@ def test_method_list_members_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncMembersPage[OrganizationMember], organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_members(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.list_members( @@ -296,7 +296,7 @@ def test_raw_response_list_members(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(SyncMembersPage[OrganizationMember], organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_members(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.list_members( @@ -310,7 +310,7 @@ def test_streaming_response_list_members(self, client: Gitpod) -> 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_set_role(self, client: Gitpod) -> None: organization = client.organizations.set_role( @@ -319,7 +319,7 @@ def test_method_set_role(self, client: Gitpod) -> None: ) assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_set_role_with_all_params(self, client: Gitpod) -> None: organization = client.organizations.set_role( @@ -329,7 +329,7 @@ def test_method_set_role_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_set_role(self, client: Gitpod) -> None: response = client.organizations.with_raw_response.set_role( @@ -342,7 +342,7 @@ def test_raw_response_set_role(self, client: Gitpod) -> None: organization = response.parse() assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_set_role(self, client: Gitpod) -> None: with client.organizations.with_streaming_response.set_role( @@ -363,7 +363,7 @@ class TestAsyncOrganizations: "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_create(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.create( @@ -371,7 +371,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(OrganizationCreateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.create( @@ -381,7 +381,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(OrganizationCreateResponse, organization, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.create( @@ -393,7 +393,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: organization = await response.parse() assert_matches_type(OrganizationCreateResponse, organization, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.create( @@ -407,7 +407,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.retrieve( @@ -415,7 +415,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(OrganizationRetrieveResponse, organization, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.retrieve( @@ -427,7 +427,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: organization = await response.parse() assert_matches_type(OrganizationRetrieveResponse, organization, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.retrieve( @@ -441,7 +441,7 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.update( @@ -449,7 +449,7 @@ async def test_method_update(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(OrganizationUpdateResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.update( @@ -459,7 +459,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(OrganizationUpdateResponse, organization, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.update( @@ -471,7 +471,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: organization = await response.parse() assert_matches_type(OrganizationUpdateResponse, organization, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.update( @@ -485,7 +485,7 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_delete(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.delete( @@ -493,7 +493,7 @@ async def test_method_delete(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, organization, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.delete( @@ -505,7 +505,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: organization = await response.parse() assert_matches_type(object, organization, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.delete( @@ -519,13 +519,13 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_join(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.join() assert_matches_type(OrganizationJoinResponse, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_join_with_all_params(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.join( @@ -534,7 +534,7 @@ async def test_method_join_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(OrganizationJoinResponse, organization, 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_join(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.join() @@ -544,7 +544,7 @@ async def test_raw_response_join(self, async_client: AsyncGitpod) -> None: organization = await response.parse() assert_matches_type(OrganizationJoinResponse, organization, 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_join(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.join() as response: @@ -556,7 +556,7 @@ async def test_streaming_response_join(self, async_client: AsyncGitpod) -> 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 async def test_method_leave(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.leave( @@ -564,7 +564,7 @@ async def test_method_leave(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, organization, 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_leave(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.leave( @@ -576,7 +576,7 @@ async def test_raw_response_leave(self, async_client: AsyncGitpod) -> None: organization = await response.parse() assert_matches_type(object, organization, 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_leave(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.leave( @@ -590,7 +590,7 @@ async def test_streaming_response_leave(self, async_client: AsyncGitpod) -> 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 async def test_method_list_members(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.list_members( @@ -598,7 +598,7 @@ async def test_method_list_members(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(AsyncMembersPage[OrganizationMember], organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_members_with_all_params(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.list_members( @@ -623,7 +623,7 @@ async def test_method_list_members_with_all_params(self, async_client: AsyncGitp ) assert_matches_type(AsyncMembersPage[OrganizationMember], organization, 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_list_members(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.list_members( @@ -635,7 +635,7 @@ async def test_raw_response_list_members(self, async_client: AsyncGitpod) -> Non organization = await response.parse() assert_matches_type(AsyncMembersPage[OrganizationMember], organization, 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_list_members(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.list_members( @@ -649,7 +649,7 @@ async def test_streaming_response_list_members(self, async_client: AsyncGitpod) 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_set_role(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.set_role( @@ -658,7 +658,7 @@ async def test_method_set_role(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, organization, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_set_role_with_all_params(self, async_client: AsyncGitpod) -> None: organization = await async_client.organizations.set_role( @@ -668,7 +668,7 @@ async def test_method_set_role_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(object, organization, 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_set_role(self, async_client: AsyncGitpod) -> None: response = await async_client.organizations.with_raw_response.set_role( @@ -681,7 +681,7 @@ async def test_raw_response_set_role(self, async_client: AsyncGitpod) -> None: organization = await response.parse() assert_matches_type(object, organization, 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_set_role(self, async_client: AsyncGitpod) -> None: async with async_client.organizations.with_streaming_response.set_role( diff --git a/tests/api_resources/test_prebuilds.py b/tests/api_resources/test_prebuilds.py index 8d1518e7..25fa12e7 100644 --- a/tests/api_resources/test_prebuilds.py +++ b/tests/api_resources/test_prebuilds.py @@ -11,12 +11,16 @@ from tests.utils import assert_matches_type from gitpod.types import ( Prebuild, + WarmPool, PrebuildCancelResponse, PrebuildCreateResponse, PrebuildRetrieveResponse, + PrebuildCreateWarmPoolResponse, + PrebuildUpdateWarmPoolResponse, PrebuildCreateLogsTokenResponse, + PrebuildRetrieveWarmPoolResponse, ) -from gitpod.pagination import SyncPrebuildsPage, AsyncPrebuildsPage +from gitpod.pagination import SyncPrebuildsPage, SyncWarmPoolsPage, AsyncPrebuildsPage, AsyncWarmPoolsPage base_url = os.environ.get("TEST_API_BASE_URL", "http://127.0.0.1:4010") @@ -24,7 +28,7 @@ class TestPrebuilds: 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_create(self, client: Gitpod) -> None: prebuild = client.prebuilds.create( @@ -33,7 +37,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(PrebuildCreateResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: prebuild = client.prebuilds.create( @@ -47,7 +51,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(PrebuildCreateResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.prebuilds.with_raw_response.create( @@ -60,7 +64,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: prebuild = response.parse() assert_matches_type(PrebuildCreateResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.prebuilds.with_streaming_response.create( @@ -75,7 +79,7 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: prebuild = client.prebuilds.retrieve( @@ -83,7 +87,7 @@ def test_method_retrieve(self, client: Gitpod) -> None: ) assert_matches_type(PrebuildRetrieveResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.prebuilds.with_raw_response.retrieve( @@ -95,7 +99,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: prebuild = response.parse() assert_matches_type(PrebuildRetrieveResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.prebuilds.with_streaming_response.retrieve( @@ -109,13 +113,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: prebuild = client.prebuilds.list() assert_matches_type(SyncPrebuildsPage[Prebuild], prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: prebuild = client.prebuilds.list( @@ -135,7 +139,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncPrebuildsPage[Prebuild], prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.prebuilds.with_raw_response.list() @@ -145,7 +149,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: prebuild = response.parse() assert_matches_type(SyncPrebuildsPage[Prebuild], prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.prebuilds.with_streaming_response.list() as response: @@ -157,7 +161,7 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: prebuild = client.prebuilds.delete( @@ -165,7 +169,7 @@ def test_method_delete(self, client: Gitpod) -> None: ) assert_matches_type(object, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.prebuilds.with_raw_response.delete( @@ -177,7 +181,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: prebuild = response.parse() assert_matches_type(object, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.prebuilds.with_streaming_response.delete( @@ -191,7 +195,7 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_cancel(self, client: Gitpod) -> None: prebuild = client.prebuilds.cancel( @@ -199,7 +203,7 @@ def test_method_cancel(self, client: Gitpod) -> None: ) assert_matches_type(PrebuildCancelResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_cancel(self, client: Gitpod) -> None: response = client.prebuilds.with_raw_response.cancel( @@ -211,7 +215,7 @@ def test_raw_response_cancel(self, client: Gitpod) -> None: prebuild = response.parse() assert_matches_type(PrebuildCancelResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_cancel(self, client: Gitpod) -> None: with client.prebuilds.with_streaming_response.cancel( @@ -225,7 +229,7 @@ def test_streaming_response_cancel(self, client: Gitpod) -> 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_create_logs_token(self, client: Gitpod) -> None: prebuild = client.prebuilds.create_logs_token( @@ -233,7 +237,7 @@ def test_method_create_logs_token(self, client: Gitpod) -> None: ) assert_matches_type(PrebuildCreateLogsTokenResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_logs_token(self, client: Gitpod) -> None: response = client.prebuilds.with_raw_response.create_logs_token( @@ -245,7 +249,7 @@ def test_raw_response_create_logs_token(self, client: Gitpod) -> None: prebuild = response.parse() assert_matches_type(PrebuildCreateLogsTokenResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_logs_token(self, client: Gitpod) -> None: with client.prebuilds.with_streaming_response.create_logs_token( @@ -259,13 +263,216 @@ def test_streaming_response_create_logs_token(self, client: Gitpod) -> None: assert cast(Any, response.is_closed) is True + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_create_warm_pool(self, client: Gitpod) -> None: + prebuild = client.prebuilds.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_create_warm_pool_with_all_params(self, client: Gitpod) -> None: + prebuild = client.prebuilds.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + desired_size=2, + ) + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_create_warm_pool(self, client: Gitpod) -> None: + response = client.prebuilds.with_raw_response.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = response.parse() + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_create_warm_pool(self, client: Gitpod) -> None: + with client.prebuilds.with_streaming_response.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = response.parse() + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_delete_warm_pool(self, client: Gitpod) -> None: + prebuild = client.prebuilds.delete_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + assert_matches_type(object, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_delete_warm_pool(self, client: Gitpod) -> None: + response = client.prebuilds.with_raw_response.delete_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = response.parse() + assert_matches_type(object, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_delete_warm_pool(self, client: Gitpod) -> None: + with client.prebuilds.with_streaming_response.delete_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = response.parse() + assert_matches_type(object, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_warm_pools(self, client: Gitpod) -> None: + prebuild = client.prebuilds.list_warm_pools() + assert_matches_type(SyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_list_warm_pools_with_all_params(self, client: Gitpod) -> None: + prebuild = client.prebuilds.list_warm_pools( + token="token", + page_size=0, + filter={ + "environment_class_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "project_ids": ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"], + }, + pagination={ + "token": "token", + "page_size": 100, + }, + ) + assert_matches_type(SyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_list_warm_pools(self, client: Gitpod) -> None: + response = client.prebuilds.with_raw_response.list_warm_pools() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = response.parse() + assert_matches_type(SyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_list_warm_pools(self, client: Gitpod) -> None: + with client.prebuilds.with_streaming_response.list_warm_pools() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = response.parse() + assert_matches_type(SyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_retrieve_warm_pool(self, client: Gitpod) -> None: + prebuild = client.prebuilds.retrieve_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + assert_matches_type(PrebuildRetrieveWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_retrieve_warm_pool(self, client: Gitpod) -> None: + response = client.prebuilds.with_raw_response.retrieve_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = response.parse() + assert_matches_type(PrebuildRetrieveWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_retrieve_warm_pool(self, client: Gitpod) -> None: + with client.prebuilds.with_streaming_response.retrieve_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = response.parse() + assert_matches_type(PrebuildRetrieveWarmPoolResponse, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_update_warm_pool(self, client: Gitpod) -> None: + prebuild = client.prebuilds.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_method_update_warm_pool_with_all_params(self, client: Gitpod) -> None: + prebuild = client.prebuilds.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + desired_size=5, + ) + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_raw_response_update_warm_pool(self, client: Gitpod) -> None: + response = client.prebuilds.with_raw_response.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = response.parse() + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + def test_streaming_response_update_warm_pool(self, client: Gitpod) -> None: + with client.prebuilds.with_streaming_response.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = response.parse() + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + class TestAsyncPrebuilds: parametrize = pytest.mark.parametrize( "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_create(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.create( @@ -274,7 +481,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(PrebuildCreateResponse, prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.create( @@ -288,7 +495,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(PrebuildCreateResponse, prebuild, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.prebuilds.with_raw_response.create( @@ -301,7 +508,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: prebuild = await response.parse() assert_matches_type(PrebuildCreateResponse, prebuild, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.prebuilds.with_streaming_response.create( @@ -316,7 +523,7 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.retrieve( @@ -324,7 +531,7 @@ async def test_method_retrieve(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(PrebuildRetrieveResponse, prebuild, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.prebuilds.with_raw_response.retrieve( @@ -336,7 +543,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: prebuild = await response.parse() assert_matches_type(PrebuildRetrieveResponse, prebuild, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.prebuilds.with_streaming_response.retrieve( @@ -350,13 +557,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_list(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.list() assert_matches_type(AsyncPrebuildsPage[Prebuild], prebuild, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.list( @@ -376,7 +583,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncPrebuildsPage[Prebuild], prebuild, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.prebuilds.with_raw_response.list() @@ -386,7 +593,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: prebuild = await response.parse() assert_matches_type(AsyncPrebuildsPage[Prebuild], prebuild, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.prebuilds.with_streaming_response.list() as response: @@ -398,7 +605,7 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.delete( @@ -406,7 +613,7 @@ async def test_method_delete(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(object, prebuild, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.prebuilds.with_raw_response.delete( @@ -418,7 +625,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: prebuild = await response.parse() assert_matches_type(object, prebuild, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.prebuilds.with_streaming_response.delete( @@ -432,7 +639,7 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_cancel(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.cancel( @@ -440,7 +647,7 @@ async def test_method_cancel(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(PrebuildCancelResponse, prebuild, 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_cancel(self, async_client: AsyncGitpod) -> None: response = await async_client.prebuilds.with_raw_response.cancel( @@ -452,7 +659,7 @@ async def test_raw_response_cancel(self, async_client: AsyncGitpod) -> None: prebuild = await response.parse() assert_matches_type(PrebuildCancelResponse, prebuild, 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_cancel(self, async_client: AsyncGitpod) -> None: async with async_client.prebuilds.with_streaming_response.cancel( @@ -466,7 +673,7 @@ async def test_streaming_response_cancel(self, async_client: AsyncGitpod) -> 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_create_logs_token(self, async_client: AsyncGitpod) -> None: prebuild = await async_client.prebuilds.create_logs_token( @@ -474,7 +681,7 @@ async def test_method_create_logs_token(self, async_client: AsyncGitpod) -> None ) assert_matches_type(PrebuildCreateLogsTokenResponse, prebuild, 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_create_logs_token(self, async_client: AsyncGitpod) -> None: response = await async_client.prebuilds.with_raw_response.create_logs_token( @@ -486,7 +693,7 @@ async def test_raw_response_create_logs_token(self, async_client: AsyncGitpod) - prebuild = await response.parse() assert_matches_type(PrebuildCreateLogsTokenResponse, prebuild, 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_create_logs_token(self, async_client: AsyncGitpod) -> None: async with async_client.prebuilds.with_streaming_response.create_logs_token( @@ -499,3 +706,206 @@ async def test_streaming_response_create_logs_token(self, async_client: AsyncGit assert_matches_type(PrebuildCreateLogsTokenResponse, prebuild, path=["response"]) assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_create_warm_pool(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_create_warm_pool_with_all_params(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + desired_size=2, + ) + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_create_warm_pool(self, async_client: AsyncGitpod) -> None: + response = await async_client.prebuilds.with_raw_response.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = await response.parse() + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_create_warm_pool(self, async_client: AsyncGitpod) -> None: + async with async_client.prebuilds.with_streaming_response.create_warm_pool( + environment_class_id="d2c94c27-3b76-4a42-b88c-95a85e392c68", + project_id="b0e12f6c-4c67-429d-a4a6-d9838b5da047", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = await response.parse() + assert_matches_type(PrebuildCreateWarmPoolResponse, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_delete_warm_pool(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.delete_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + assert_matches_type(object, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_delete_warm_pool(self, async_client: AsyncGitpod) -> None: + response = await async_client.prebuilds.with_raw_response.delete_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = await response.parse() + assert_matches_type(object, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_delete_warm_pool(self, async_client: AsyncGitpod) -> None: + async with async_client.prebuilds.with_streaming_response.delete_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = await response.parse() + assert_matches_type(object, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_warm_pools(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.list_warm_pools() + assert_matches_type(AsyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_list_warm_pools_with_all_params(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.list_warm_pools( + token="token", + page_size=0, + filter={ + "environment_class_ids": ["182bd5e5-6e1a-4fe4-a799-aa6d9a6ab26e"], + "project_ids": ["b0e12f6c-4c67-429d-a4a6-d9838b5da047"], + }, + pagination={ + "token": "token", + "page_size": 100, + }, + ) + assert_matches_type(AsyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_list_warm_pools(self, async_client: AsyncGitpod) -> None: + response = await async_client.prebuilds.with_raw_response.list_warm_pools() + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = await response.parse() + assert_matches_type(AsyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_list_warm_pools(self, async_client: AsyncGitpod) -> None: + async with async_client.prebuilds.with_streaming_response.list_warm_pools() as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = await response.parse() + assert_matches_type(AsyncWarmPoolsPage[WarmPool], prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_retrieve_warm_pool(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.retrieve_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + assert_matches_type(PrebuildRetrieveWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_retrieve_warm_pool(self, async_client: AsyncGitpod) -> None: + response = await async_client.prebuilds.with_raw_response.retrieve_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = await response.parse() + assert_matches_type(PrebuildRetrieveWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_retrieve_warm_pool(self, async_client: AsyncGitpod) -> None: + async with async_client.prebuilds.with_streaming_response.retrieve_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = await response.parse() + assert_matches_type(PrebuildRetrieveWarmPoolResponse, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_update_warm_pool(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_method_update_warm_pool_with_all_params(self, async_client: AsyncGitpod) -> None: + prebuild = await async_client.prebuilds.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + desired_size=5, + ) + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_raw_response_update_warm_pool(self, async_client: AsyncGitpod) -> None: + response = await async_client.prebuilds.with_raw_response.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) + + assert response.is_closed is True + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + prebuild = await response.parse() + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + @pytest.mark.skip(reason="Mock server tests are disabled") + @parametrize + async def test_streaming_response_update_warm_pool(self, async_client: AsyncGitpod) -> None: + async with async_client.prebuilds.with_streaming_response.update_warm_pool( + warm_pool_id="a1b2c3d4-5678-9abc-def0-1234567890ab", + ) as response: + assert not response.is_closed + assert response.http_request.headers.get("X-Stainless-Lang") == "python" + + prebuild = await response.parse() + assert_matches_type(PrebuildUpdateWarmPoolResponse, prebuild, path=["response"]) + + assert cast(Any, response.is_closed) is True diff --git a/tests/api_resources/test_projects.py b/tests/api_resources/test_projects.py index b51a14b7..03f0abd1 100644 --- a/tests/api_resources/test_projects.py +++ b/tests/api_resources/test_projects.py @@ -27,7 +27,7 @@ class TestProjects: 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_create(self, client: Gitpod) -> None: project = client.projects.create( @@ -35,7 +35,7 @@ def test_method_create(self, client: Gitpod) -> None: ) assert_matches_type(ProjectCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: project = client.projects.create( @@ -71,7 +71,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ProjectCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.projects.with_raw_response.create( @@ -83,7 +83,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(ProjectCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.projects.with_streaming_response.create( @@ -97,13 +97,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: project = client.projects.retrieve() assert_matches_type(ProjectRetrieveResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: project = client.projects.retrieve( @@ -111,7 +111,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ProjectRetrieveResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.projects.with_raw_response.retrieve() @@ -121,7 +121,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(ProjectRetrieveResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.projects.with_streaming_response.retrieve() as response: @@ -133,13 +133,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: project = client.projects.update() assert_matches_type(ProjectUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: project = client.projects.update( @@ -177,7 +177,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ProjectUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.projects.with_raw_response.update() @@ -187,7 +187,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(ProjectUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.projects.with_streaming_response.update() as response: @@ -199,13 +199,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: project = client.projects.list() assert_matches_type(SyncProjectsPage[Project], project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: project = client.projects.list( @@ -221,10 +221,14 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: "token": "token", "page_size": 20, }, + sort={ + "field": "field", + "order": "SORT_ORDER_UNSPECIFIED", + }, ) assert_matches_type(SyncProjectsPage[Project], project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.projects.with_raw_response.list() @@ -234,7 +238,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(SyncProjectsPage[Project], project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.projects.with_streaming_response.list() as response: @@ -246,13 +250,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: project = client.projects.delete() assert_matches_type(object, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: project = client.projects.delete( @@ -260,7 +264,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.projects.with_raw_response.delete() @@ -270,7 +274,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(object, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.projects.with_streaming_response.delete() as response: @@ -282,13 +286,13 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_bulk_create(self, client: Gitpod) -> None: project = client.projects.bulk_create() assert_matches_type(ProjectBulkCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_bulk_create_with_all_params(self, client: Gitpod) -> None: project = client.projects.bulk_create( @@ -359,7 +363,7 @@ def test_method_bulk_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ProjectBulkCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_bulk_create(self, client: Gitpod) -> None: response = client.projects.with_raw_response.bulk_create() @@ -369,7 +373,7 @@ def test_raw_response_bulk_create(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(ProjectBulkCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_bulk_create(self, client: Gitpod) -> None: with client.projects.with_streaming_response.bulk_create() as response: @@ -381,13 +385,13 @@ def test_streaming_response_bulk_create(self, client: Gitpod) -> 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_bulk_delete(self, client: Gitpod) -> None: project = client.projects.bulk_delete() assert_matches_type(ProjectBulkDeleteResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_bulk_delete_with_all_params(self, client: Gitpod) -> None: project = client.projects.bulk_delete( @@ -395,7 +399,7 @@ def test_method_bulk_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ProjectBulkDeleteResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_bulk_delete(self, client: Gitpod) -> None: response = client.projects.with_raw_response.bulk_delete() @@ -405,7 +409,7 @@ def test_raw_response_bulk_delete(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(ProjectBulkDeleteResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_bulk_delete(self, client: Gitpod) -> None: with client.projects.with_streaming_response.bulk_delete() as response: @@ -417,13 +421,13 @@ def test_streaming_response_bulk_delete(self, client: Gitpod) -> 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_bulk_update(self, client: Gitpod) -> None: project = client.projects.bulk_update() assert_matches_type(ProjectBulkUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_bulk_update_with_all_params(self, client: Gitpod) -> None: project = client.projects.bulk_update( @@ -498,7 +502,7 @@ def test_method_bulk_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(ProjectBulkUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_bulk_update(self, client: Gitpod) -> None: response = client.projects.with_raw_response.bulk_update() @@ -508,7 +512,7 @@ def test_raw_response_bulk_update(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(ProjectBulkUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_bulk_update(self, client: Gitpod) -> None: with client.projects.with_streaming_response.bulk_update() as response: @@ -520,13 +524,13 @@ def test_streaming_response_bulk_update(self, client: Gitpod) -> 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_create_from_environment(self, client: Gitpod) -> None: project = client.projects.create_from_environment() assert_matches_type(ProjectCreateFromEnvironmentResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_from_environment_with_all_params(self, client: Gitpod) -> None: project = client.projects.create_from_environment( @@ -535,7 +539,7 @@ def test_method_create_from_environment_with_all_params(self, client: Gitpod) -> ) assert_matches_type(ProjectCreateFromEnvironmentResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_from_environment(self, client: Gitpod) -> None: response = client.projects.with_raw_response.create_from_environment() @@ -545,7 +549,7 @@ def test_raw_response_create_from_environment(self, client: Gitpod) -> None: project = response.parse() assert_matches_type(ProjectCreateFromEnvironmentResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_from_environment(self, client: Gitpod) -> None: with client.projects.with_streaming_response.create_from_environment() as response: @@ -563,7 +567,7 @@ class TestAsyncProjects: "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_create(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.create( @@ -571,7 +575,7 @@ async def test_method_create(self, async_client: AsyncGitpod) -> None: ) assert_matches_type(ProjectCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.create( @@ -607,7 +611,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(ProjectCreateResponse, project, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.create( @@ -619,7 +623,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: project = await response.parse() assert_matches_type(ProjectCreateResponse, project, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.create( @@ -633,13 +637,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.retrieve() assert_matches_type(ProjectRetrieveResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.retrieve( @@ -647,7 +651,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(ProjectRetrieveResponse, project, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.retrieve() @@ -657,7 +661,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: project = await response.parse() assert_matches_type(ProjectRetrieveResponse, project, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.retrieve() as response: @@ -669,13 +673,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.update() assert_matches_type(ProjectUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.update( @@ -713,7 +717,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(ProjectUpdateResponse, project, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.update() @@ -723,7 +727,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: project = await response.parse() assert_matches_type(ProjectUpdateResponse, project, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.update() as response: @@ -735,13 +739,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.list() assert_matches_type(AsyncProjectsPage[Project], project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.list( @@ -757,10 +761,14 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N "token": "token", "page_size": 20, }, + sort={ + "field": "field", + "order": "SORT_ORDER_UNSPECIFIED", + }, ) assert_matches_type(AsyncProjectsPage[Project], project, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.list() @@ -770,7 +778,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: project = await response.parse() assert_matches_type(AsyncProjectsPage[Project], project, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.list() as response: @@ -782,13 +790,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.delete() assert_matches_type(object, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.delete( @@ -796,7 +804,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, project, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.delete() @@ -806,7 +814,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: project = await response.parse() assert_matches_type(object, project, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.delete() as response: @@ -818,13 +826,13 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_bulk_create(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.bulk_create() assert_matches_type(ProjectBulkCreateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_bulk_create_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.bulk_create( @@ -895,7 +903,7 @@ async def test_method_bulk_create_with_all_params(self, async_client: AsyncGitpo ) assert_matches_type(ProjectBulkCreateResponse, project, 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_bulk_create(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.bulk_create() @@ -905,7 +913,7 @@ async def test_raw_response_bulk_create(self, async_client: AsyncGitpod) -> None project = await response.parse() assert_matches_type(ProjectBulkCreateResponse, project, 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_bulk_create(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.bulk_create() as response: @@ -917,13 +925,13 @@ async def test_streaming_response_bulk_create(self, async_client: AsyncGitpod) - 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_bulk_delete(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.bulk_delete() assert_matches_type(ProjectBulkDeleteResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_bulk_delete_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.bulk_delete( @@ -931,7 +939,7 @@ async def test_method_bulk_delete_with_all_params(self, async_client: AsyncGitpo ) assert_matches_type(ProjectBulkDeleteResponse, project, 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_bulk_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.bulk_delete() @@ -941,7 +949,7 @@ async def test_raw_response_bulk_delete(self, async_client: AsyncGitpod) -> None project = await response.parse() assert_matches_type(ProjectBulkDeleteResponse, project, 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_bulk_delete(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.bulk_delete() as response: @@ -953,13 +961,13 @@ async def test_streaming_response_bulk_delete(self, async_client: AsyncGitpod) - 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_bulk_update(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.bulk_update() assert_matches_type(ProjectBulkUpdateResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_bulk_update_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.bulk_update( @@ -1034,7 +1042,7 @@ async def test_method_bulk_update_with_all_params(self, async_client: AsyncGitpo ) assert_matches_type(ProjectBulkUpdateResponse, project, 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_bulk_update(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.bulk_update() @@ -1044,7 +1052,7 @@ async def test_raw_response_bulk_update(self, async_client: AsyncGitpod) -> None project = await response.parse() assert_matches_type(ProjectBulkUpdateResponse, project, 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_bulk_update(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.bulk_update() as response: @@ -1056,13 +1064,13 @@ async def test_streaming_response_bulk_update(self, async_client: AsyncGitpod) - 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_create_from_environment(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.create_from_environment() assert_matches_type(ProjectCreateFromEnvironmentResponse, project, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_from_environment_with_all_params(self, async_client: AsyncGitpod) -> None: project = await async_client.projects.create_from_environment( @@ -1071,7 +1079,7 @@ async def test_method_create_from_environment_with_all_params(self, async_client ) assert_matches_type(ProjectCreateFromEnvironmentResponse, project, 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_create_from_environment(self, async_client: AsyncGitpod) -> None: response = await async_client.projects.with_raw_response.create_from_environment() @@ -1081,7 +1089,7 @@ async def test_raw_response_create_from_environment(self, async_client: AsyncGit project = await response.parse() assert_matches_type(ProjectCreateFromEnvironmentResponse, project, 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_create_from_environment(self, async_client: AsyncGitpod) -> None: async with async_client.projects.with_streaming_response.create_from_environment() as response: diff --git a/tests/api_resources/test_runners.py b/tests/api_resources/test_runners.py index eaf96b9e..9e7ef743 100644 --- a/tests/api_resources/test_runners.py +++ b/tests/api_resources/test_runners.py @@ -29,13 +29,13 @@ class TestRunners: 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_create(self, client: Gitpod) -> None: runner = client.runners.create() assert_matches_type(RunnerCreateResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: runner = client.runners.create( @@ -63,7 +63,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(RunnerCreateResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.runners.with_raw_response.create() @@ -73,7 +73,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerCreateResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.runners.with_streaming_response.create() as response: @@ -85,13 +85,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_retrieve(self, client: Gitpod) -> None: runner = client.runners.retrieve() assert_matches_type(RunnerRetrieveResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: runner = client.runners.retrieve( @@ -99,7 +99,7 @@ def test_method_retrieve_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(RunnerRetrieveResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_retrieve(self, client: Gitpod) -> None: response = client.runners.with_raw_response.retrieve() @@ -109,7 +109,7 @@ def test_raw_response_retrieve(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerRetrieveResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_retrieve(self, client: Gitpod) -> None: with client.runners.with_streaming_response.retrieve() as response: @@ -121,13 +121,13 @@ def test_streaming_response_retrieve(self, client: Gitpod) -> 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_update(self, client: Gitpod) -> None: runner = client.runners.update() assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_with_all_params(self, client: Gitpod) -> None: runner = client.runners.update( @@ -151,7 +151,7 @@ def test_method_update_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update(self, client: Gitpod) -> None: response = client.runners.with_raw_response.update() @@ -161,7 +161,7 @@ def test_raw_response_update(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update(self, client: Gitpod) -> None: with client.runners.with_streaming_response.update() as response: @@ -173,13 +173,13 @@ def test_streaming_response_update(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: runner = client.runners.list() assert_matches_type(SyncRunnersPage[Runner], runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: runner = client.runners.list( @@ -197,7 +197,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncRunnersPage[Runner], runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.runners.with_raw_response.list() @@ -207,7 +207,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(SyncRunnersPage[Runner], runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.runners.with_streaming_response.list() as response: @@ -219,13 +219,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: runner = client.runners.delete() assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: runner = client.runners.delete( @@ -234,7 +234,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.runners.with_raw_response.delete() @@ -244,7 +244,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.runners.with_streaming_response.delete() as response: @@ -256,13 +256,13 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_check_authentication_for_host(self, client: Gitpod) -> None: runner = client.runners.check_authentication_for_host() assert_matches_type(RunnerCheckAuthenticationForHostResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_check_authentication_for_host_with_all_params(self, client: Gitpod) -> None: runner = client.runners.check_authentication_for_host( @@ -271,7 +271,7 @@ def test_method_check_authentication_for_host_with_all_params(self, client: Gitp ) assert_matches_type(RunnerCheckAuthenticationForHostResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_check_authentication_for_host(self, client: Gitpod) -> None: response = client.runners.with_raw_response.check_authentication_for_host() @@ -281,7 +281,7 @@ def test_raw_response_check_authentication_for_host(self, client: Gitpod) -> Non runner = response.parse() assert_matches_type(RunnerCheckAuthenticationForHostResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_check_authentication_for_host(self, client: Gitpod) -> None: with client.runners.with_streaming_response.check_authentication_for_host() as response: @@ -293,13 +293,13 @@ def test_streaming_response_check_authentication_for_host(self, client: Gitpod) 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_check_repository_access(self, client: Gitpod) -> None: runner = client.runners.check_repository_access() assert_matches_type(RunnerCheckRepositoryAccessResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_check_repository_access_with_all_params(self, client: Gitpod) -> None: runner = client.runners.check_repository_access( @@ -308,7 +308,7 @@ def test_method_check_repository_access_with_all_params(self, client: Gitpod) -> ) assert_matches_type(RunnerCheckRepositoryAccessResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_check_repository_access(self, client: Gitpod) -> None: response = client.runners.with_raw_response.check_repository_access() @@ -318,7 +318,7 @@ def test_raw_response_check_repository_access(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerCheckRepositoryAccessResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_check_repository_access(self, client: Gitpod) -> None: with client.runners.with_streaming_response.check_repository_access() as response: @@ -330,13 +330,13 @@ def test_streaming_response_check_repository_access(self, client: Gitpod) -> 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_method_create_logs_token(self, client: Gitpod) -> None: runner = client.runners.create_logs_token() assert_matches_type(RunnerCreateLogsTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_logs_token_with_all_params(self, client: Gitpod) -> None: runner = client.runners.create_logs_token( @@ -344,7 +344,7 @@ def test_method_create_logs_token_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(RunnerCreateLogsTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_logs_token(self, client: Gitpod) -> None: response = client.runners.with_raw_response.create_logs_token() @@ -354,7 +354,7 @@ def test_raw_response_create_logs_token(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerCreateLogsTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_logs_token(self, client: Gitpod) -> None: with client.runners.with_streaming_response.create_logs_token() as response: @@ -366,13 +366,13 @@ def test_streaming_response_create_logs_token(self, client: Gitpod) -> 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_create_runner_token(self, client: Gitpod) -> None: runner = client.runners.create_runner_token() assert_matches_type(RunnerCreateRunnerTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_runner_token_with_all_params(self, client: Gitpod) -> None: runner = client.runners.create_runner_token( @@ -380,7 +380,7 @@ def test_method_create_runner_token_with_all_params(self, client: Gitpod) -> Non ) assert_matches_type(RunnerCreateRunnerTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create_runner_token(self, client: Gitpod) -> None: response = client.runners.with_raw_response.create_runner_token() @@ -390,7 +390,7 @@ def test_raw_response_create_runner_token(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerCreateRunnerTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create_runner_token(self, client: Gitpod) -> None: with client.runners.with_streaming_response.create_runner_token() as response: @@ -402,13 +402,13 @@ def test_streaming_response_create_runner_token(self, client: Gitpod) -> 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_list_scm_organizations(self, client: Gitpod) -> None: runner = client.runners.list_scm_organizations() assert_matches_type(RunnerListScmOrganizationsResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_scm_organizations_with_all_params(self, client: Gitpod) -> None: runner = client.runners.list_scm_organizations( @@ -419,7 +419,7 @@ def test_method_list_scm_organizations_with_all_params(self, client: Gitpod) -> ) assert_matches_type(RunnerListScmOrganizationsResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_scm_organizations(self, client: Gitpod) -> None: response = client.runners.with_raw_response.list_scm_organizations() @@ -429,7 +429,7 @@ def test_raw_response_list_scm_organizations(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerListScmOrganizationsResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_scm_organizations(self, client: Gitpod) -> None: with client.runners.with_streaming_response.list_scm_organizations() as response: @@ -441,13 +441,13 @@ def test_streaming_response_list_scm_organizations(self, client: Gitpod) -> 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_parse_context_url(self, client: Gitpod) -> None: runner = client.runners.parse_context_url() assert_matches_type(RunnerParseContextURLResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_parse_context_url_with_all_params(self, client: Gitpod) -> None: runner = client.runners.parse_context_url( @@ -456,7 +456,7 @@ def test_method_parse_context_url_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(RunnerParseContextURLResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_parse_context_url(self, client: Gitpod) -> None: response = client.runners.with_raw_response.parse_context_url() @@ -466,7 +466,7 @@ def test_raw_response_parse_context_url(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerParseContextURLResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_parse_context_url(self, client: Gitpod) -> None: with client.runners.with_streaming_response.parse_context_url() as response: @@ -478,13 +478,13 @@ def test_streaming_response_parse_context_url(self, client: Gitpod) -> 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_search_repositories(self, client: Gitpod) -> None: runner = client.runners.search_repositories() assert_matches_type(RunnerSearchRepositoriesResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_search_repositories_with_all_params(self, client: Gitpod) -> None: runner = client.runners.search_repositories( @@ -500,7 +500,7 @@ def test_method_search_repositories_with_all_params(self, client: Gitpod) -> Non ) assert_matches_type(RunnerSearchRepositoriesResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_search_repositories(self, client: Gitpod) -> None: response = client.runners.with_raw_response.search_repositories() @@ -510,7 +510,7 @@ def test_raw_response_search_repositories(self, client: Gitpod) -> None: runner = response.parse() assert_matches_type(RunnerSearchRepositoriesResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_search_repositories(self, client: Gitpod) -> None: with client.runners.with_streaming_response.search_repositories() as response: @@ -528,13 +528,13 @@ class TestAsyncRunners: "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_create(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.create() assert_matches_type(RunnerCreateResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.create( @@ -562,7 +562,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(RunnerCreateResponse, runner, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.create() @@ -572,7 +572,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: runner = await response.parse() assert_matches_type(RunnerCreateResponse, runner, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.create() as response: @@ -584,13 +584,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_retrieve(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.retrieve() assert_matches_type(RunnerRetrieveResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.retrieve( @@ -598,7 +598,7 @@ async def test_method_retrieve_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(RunnerRetrieveResponse, runner, 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_retrieve(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.retrieve() @@ -608,7 +608,7 @@ async def test_raw_response_retrieve(self, async_client: AsyncGitpod) -> None: runner = await response.parse() assert_matches_type(RunnerRetrieveResponse, runner, 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_retrieve(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.retrieve() as response: @@ -620,13 +620,13 @@ async def test_streaming_response_retrieve(self, async_client: AsyncGitpod) -> N 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_update(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.update() assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.update( @@ -650,7 +650,7 @@ async def test_method_update_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, runner, 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_update(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.update() @@ -660,7 +660,7 @@ async def test_raw_response_update(self, async_client: AsyncGitpod) -> None: runner = await response.parse() assert_matches_type(object, runner, 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_update(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.update() as response: @@ -672,13 +672,13 @@ async def test_streaming_response_update(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.list() assert_matches_type(AsyncRunnersPage[Runner], runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.list( @@ -696,7 +696,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncRunnersPage[Runner], runner, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.list() @@ -706,7 +706,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: runner = await response.parse() assert_matches_type(AsyncRunnersPage[Runner], runner, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.list() as response: @@ -718,13 +718,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.delete() assert_matches_type(object, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.delete( @@ -733,7 +733,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, runner, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.delete() @@ -743,7 +743,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: runner = await response.parse() assert_matches_type(object, runner, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.delete() as response: @@ -755,13 +755,13 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_check_authentication_for_host(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.check_authentication_for_host() assert_matches_type(RunnerCheckAuthenticationForHostResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_check_authentication_for_host_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.check_authentication_for_host( @@ -770,7 +770,7 @@ async def test_method_check_authentication_for_host_with_all_params(self, async_ ) assert_matches_type(RunnerCheckAuthenticationForHostResponse, runner, 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_check_authentication_for_host(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.check_authentication_for_host() @@ -780,7 +780,7 @@ async def test_raw_response_check_authentication_for_host(self, async_client: As runner = await response.parse() assert_matches_type(RunnerCheckAuthenticationForHostResponse, runner, 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_check_authentication_for_host(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.check_authentication_for_host() as response: @@ -792,13 +792,13 @@ async def test_streaming_response_check_authentication_for_host(self, async_clie 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_check_repository_access(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.check_repository_access() assert_matches_type(RunnerCheckRepositoryAccessResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_check_repository_access_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.check_repository_access( @@ -807,7 +807,7 @@ async def test_method_check_repository_access_with_all_params(self, async_client ) assert_matches_type(RunnerCheckRepositoryAccessResponse, runner, 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_check_repository_access(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.check_repository_access() @@ -817,7 +817,7 @@ async def test_raw_response_check_repository_access(self, async_client: AsyncGit runner = await response.parse() assert_matches_type(RunnerCheckRepositoryAccessResponse, runner, 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_check_repository_access(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.check_repository_access() as response: @@ -829,13 +829,13 @@ async def test_streaming_response_check_repository_access(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_method_create_logs_token(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.create_logs_token() assert_matches_type(RunnerCreateLogsTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_logs_token_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.create_logs_token( @@ -843,7 +843,7 @@ async def test_method_create_logs_token_with_all_params(self, async_client: Asyn ) assert_matches_type(RunnerCreateLogsTokenResponse, runner, 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_create_logs_token(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.create_logs_token() @@ -853,7 +853,7 @@ async def test_raw_response_create_logs_token(self, async_client: AsyncGitpod) - runner = await response.parse() assert_matches_type(RunnerCreateLogsTokenResponse, runner, 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_create_logs_token(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.create_logs_token() as response: @@ -865,13 +865,13 @@ async def test_streaming_response_create_logs_token(self, async_client: AsyncGit 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_create_runner_token(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.create_runner_token() assert_matches_type(RunnerCreateRunnerTokenResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_runner_token_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.create_runner_token( @@ -879,7 +879,7 @@ async def test_method_create_runner_token_with_all_params(self, async_client: As ) assert_matches_type(RunnerCreateRunnerTokenResponse, runner, 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_create_runner_token(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.create_runner_token() @@ -889,7 +889,7 @@ async def test_raw_response_create_runner_token(self, async_client: AsyncGitpod) runner = await response.parse() assert_matches_type(RunnerCreateRunnerTokenResponse, runner, 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_create_runner_token(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.create_runner_token() as response: @@ -901,13 +901,13 @@ async def test_streaming_response_create_runner_token(self, async_client: AsyncG 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_list_scm_organizations(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.list_scm_organizations() assert_matches_type(RunnerListScmOrganizationsResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_scm_organizations_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.list_scm_organizations( @@ -918,7 +918,7 @@ async def test_method_list_scm_organizations_with_all_params(self, async_client: ) assert_matches_type(RunnerListScmOrganizationsResponse, runner, 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_list_scm_organizations(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.list_scm_organizations() @@ -928,7 +928,7 @@ async def test_raw_response_list_scm_organizations(self, async_client: AsyncGitp runner = await response.parse() assert_matches_type(RunnerListScmOrganizationsResponse, runner, 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_list_scm_organizations(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.list_scm_organizations() as response: @@ -940,13 +940,13 @@ async def test_streaming_response_list_scm_organizations(self, async_client: Asy 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_parse_context_url(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.parse_context_url() assert_matches_type(RunnerParseContextURLResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_parse_context_url_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.parse_context_url( @@ -955,7 +955,7 @@ async def test_method_parse_context_url_with_all_params(self, async_client: Asyn ) assert_matches_type(RunnerParseContextURLResponse, runner, 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_parse_context_url(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.parse_context_url() @@ -965,7 +965,7 @@ async def test_raw_response_parse_context_url(self, async_client: AsyncGitpod) - runner = await response.parse() assert_matches_type(RunnerParseContextURLResponse, runner, 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_parse_context_url(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.parse_context_url() as response: @@ -977,13 +977,13 @@ async def test_streaming_response_parse_context_url(self, async_client: AsyncGit 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_search_repositories(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.search_repositories() assert_matches_type(RunnerSearchRepositoriesResponse, runner, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_search_repositories_with_all_params(self, async_client: AsyncGitpod) -> None: runner = await async_client.runners.search_repositories( @@ -999,7 +999,7 @@ async def test_method_search_repositories_with_all_params(self, async_client: As ) assert_matches_type(RunnerSearchRepositoriesResponse, runner, 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_search_repositories(self, async_client: AsyncGitpod) -> None: response = await async_client.runners.with_raw_response.search_repositories() @@ -1009,7 +1009,7 @@ async def test_raw_response_search_repositories(self, async_client: AsyncGitpod) runner = await response.parse() assert_matches_type(RunnerSearchRepositoriesResponse, runner, 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_search_repositories(self, async_client: AsyncGitpod) -> None: async with async_client.runners.with_streaming_response.search_repositories() as response: diff --git a/tests/api_resources/test_secrets.py b/tests/api_resources/test_secrets.py index 680a9d7c..cbed1cda 100644 --- a/tests/api_resources/test_secrets.py +++ b/tests/api_resources/test_secrets.py @@ -22,13 +22,13 @@ class TestSecrets: 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_create(self, client: Gitpod) -> None: secret = client.secrets.create() assert_matches_type(SecretCreateResponse, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_create_with_all_params(self, client: Gitpod) -> None: secret = client.secrets.create( @@ -48,7 +48,7 @@ def test_method_create_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SecretCreateResponse, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_create(self, client: Gitpod) -> None: response = client.secrets.with_raw_response.create() @@ -58,7 +58,7 @@ def test_raw_response_create(self, client: Gitpod) -> None: secret = response.parse() assert_matches_type(SecretCreateResponse, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_create(self, client: Gitpod) -> None: with client.secrets.with_streaming_response.create() as response: @@ -70,13 +70,13 @@ def test_streaming_response_create(self, client: Gitpod) -> 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_list(self, client: Gitpod) -> None: secret = client.secrets.list() assert_matches_type(SyncSecretsPage[Secret], secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: secret = client.secrets.list( @@ -98,7 +98,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncSecretsPage[Secret], secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.secrets.with_raw_response.list() @@ -108,7 +108,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: secret = response.parse() assert_matches_type(SyncSecretsPage[Secret], secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.secrets.with_streaming_response.list() as response: @@ -120,13 +120,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: secret = client.secrets.delete() assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: secret = client.secrets.delete( @@ -134,7 +134,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.secrets.with_raw_response.delete() @@ -144,7 +144,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: secret = response.parse() assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.secrets.with_streaming_response.delete() as response: @@ -156,13 +156,13 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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_value(self, client: Gitpod) -> None: secret = client.secrets.get_value() assert_matches_type(SecretGetValueResponse, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_value_with_all_params(self, client: Gitpod) -> None: secret = client.secrets.get_value( @@ -170,7 +170,7 @@ def test_method_get_value_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SecretGetValueResponse, secret, 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_value(self, client: Gitpod) -> None: response = client.secrets.with_raw_response.get_value() @@ -180,7 +180,7 @@ def test_raw_response_get_value(self, client: Gitpod) -> None: secret = response.parse() assert_matches_type(SecretGetValueResponse, secret, 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_value(self, client: Gitpod) -> None: with client.secrets.with_streaming_response.get_value() as response: @@ -192,13 +192,13 @@ def test_streaming_response_get_value(self, client: Gitpod) -> 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_update_value(self, client: Gitpod) -> None: secret = client.secrets.update_value() assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_update_value_with_all_params(self, client: Gitpod) -> None: secret = client.secrets.update_value( @@ -207,7 +207,7 @@ def test_method_update_value_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_update_value(self, client: Gitpod) -> None: response = client.secrets.with_raw_response.update_value() @@ -217,7 +217,7 @@ def test_raw_response_update_value(self, client: Gitpod) -> None: secret = response.parse() assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_update_value(self, client: Gitpod) -> None: with client.secrets.with_streaming_response.update_value() as response: @@ -235,13 +235,13 @@ class TestAsyncSecrets: "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_create(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.create() assert_matches_type(SecretCreateResponse, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.create( @@ -261,7 +261,7 @@ async def test_method_create_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(SecretCreateResponse, secret, 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_create(self, async_client: AsyncGitpod) -> None: response = await async_client.secrets.with_raw_response.create() @@ -271,7 +271,7 @@ async def test_raw_response_create(self, async_client: AsyncGitpod) -> None: secret = await response.parse() assert_matches_type(SecretCreateResponse, secret, 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_create(self, async_client: AsyncGitpod) -> None: async with async_client.secrets.with_streaming_response.create() as response: @@ -283,13 +283,13 @@ async def test_streaming_response_create(self, async_client: AsyncGitpod) -> 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_list(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.list() assert_matches_type(AsyncSecretsPage[Secret], secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.list( @@ -311,7 +311,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncSecretsPage[Secret], secret, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.secrets.with_raw_response.list() @@ -321,7 +321,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: secret = await response.parse() assert_matches_type(AsyncSecretsPage[Secret], secret, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.secrets.with_streaming_response.list() as response: @@ -333,13 +333,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.delete() assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.delete( @@ -347,7 +347,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, secret, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.secrets.with_raw_response.delete() @@ -357,7 +357,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: secret = await response.parse() assert_matches_type(object, secret, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.secrets.with_streaming_response.delete() as response: @@ -369,13 +369,13 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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_value(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.get_value() assert_matches_type(SecretGetValueResponse, secret, 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_value_with_all_params(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.get_value( @@ -383,7 +383,7 @@ async def test_method_get_value_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(SecretGetValueResponse, secret, 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_value(self, async_client: AsyncGitpod) -> None: response = await async_client.secrets.with_raw_response.get_value() @@ -393,7 +393,7 @@ async def test_raw_response_get_value(self, async_client: AsyncGitpod) -> None: secret = await response.parse() assert_matches_type(SecretGetValueResponse, secret, 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_value(self, async_client: AsyncGitpod) -> None: async with async_client.secrets.with_streaming_response.get_value() as response: @@ -405,13 +405,13 @@ async def test_streaming_response_get_value(self, async_client: AsyncGitpod) -> 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_update_value(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.update_value() assert_matches_type(object, secret, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_update_value_with_all_params(self, async_client: AsyncGitpod) -> None: secret = await async_client.secrets.update_value( @@ -420,7 +420,7 @@ async def test_method_update_value_with_all_params(self, async_client: AsyncGitp ) assert_matches_type(object, secret, 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_update_value(self, async_client: AsyncGitpod) -> None: response = await async_client.secrets.with_raw_response.update_value() @@ -430,7 +430,7 @@ async def test_raw_response_update_value(self, async_client: AsyncGitpod) -> Non secret = await response.parse() assert_matches_type(object, secret, 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_update_value(self, async_client: AsyncGitpod) -> None: async with async_client.secrets.with_streaming_response.update_value() as response: diff --git a/tests/api_resources/test_usage.py b/tests/api_resources/test_usage.py index a203b817..754a862e 100644 --- a/tests/api_resources/test_usage.py +++ b/tests/api_resources/test_usage.py @@ -19,13 +19,13 @@ class TestUsage: 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_list_environment_runtime_records(self, client: Gitpod) -> None: usage = client.usage.list_environment_runtime_records() assert_matches_type(SyncRecordsPage[EnvironmentUsageRecord], usage, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_environment_runtime_records_with_all_params(self, client: Gitpod) -> None: usage = client.usage.list_environment_runtime_records( @@ -45,7 +45,7 @@ def test_method_list_environment_runtime_records_with_all_params(self, client: G ) assert_matches_type(SyncRecordsPage[EnvironmentUsageRecord], usage, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list_environment_runtime_records(self, client: Gitpod) -> None: response = client.usage.with_raw_response.list_environment_runtime_records() @@ -55,7 +55,7 @@ def test_raw_response_list_environment_runtime_records(self, client: Gitpod) -> usage = response.parse() assert_matches_type(SyncRecordsPage[EnvironmentUsageRecord], usage, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list_environment_runtime_records(self, client: Gitpod) -> None: with client.usage.with_streaming_response.list_environment_runtime_records() as response: @@ -73,13 +73,13 @@ class TestAsyncUsage: "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_list_environment_runtime_records(self, async_client: AsyncGitpod) -> None: usage = await async_client.usage.list_environment_runtime_records() assert_matches_type(AsyncRecordsPage[EnvironmentUsageRecord], usage, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_environment_runtime_records_with_all_params(self, async_client: AsyncGitpod) -> None: usage = await async_client.usage.list_environment_runtime_records( @@ -99,7 +99,7 @@ async def test_method_list_environment_runtime_records_with_all_params(self, asy ) assert_matches_type(AsyncRecordsPage[EnvironmentUsageRecord], usage, 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_list_environment_runtime_records(self, async_client: AsyncGitpod) -> None: response = await async_client.usage.with_raw_response.list_environment_runtime_records() @@ -109,7 +109,7 @@ async def test_raw_response_list_environment_runtime_records(self, async_client: usage = await response.parse() assert_matches_type(AsyncRecordsPage[EnvironmentUsageRecord], usage, 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_list_environment_runtime_records(self, async_client: AsyncGitpod) -> None: async with async_client.usage.with_streaming_response.list_environment_runtime_records() as response: diff --git a/tests/api_resources/test_users.py b/tests/api_resources/test_users.py index 576deff0..3871c1bf 100644 --- a/tests/api_resources/test_users.py +++ b/tests/api_resources/test_users.py @@ -20,13 +20,13 @@ class TestUsers: 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_delete_user(self, client: Gitpod) -> None: user = client.users.delete_user() assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_user_with_all_params(self, client: Gitpod) -> None: user = client.users.delete_user( @@ -34,7 +34,7 @@ def test_method_delete_user_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete_user(self, client: Gitpod) -> None: response = client.users.with_raw_response.delete_user() @@ -44,7 +44,7 @@ def test_raw_response_delete_user(self, client: Gitpod) -> None: user = response.parse() assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete_user(self, client: Gitpod) -> None: with client.users.with_streaming_response.delete_user() as response: @@ -56,13 +56,13 @@ def test_streaming_response_delete_user(self, client: Gitpod) -> 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_authenticated_user(self, client: Gitpod) -> None: user = client.users.get_authenticated_user() assert_matches_type(UserGetAuthenticatedUserResponse, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_authenticated_user_with_all_params(self, client: Gitpod) -> None: user = client.users.get_authenticated_user( @@ -70,7 +70,7 @@ def test_method_get_authenticated_user_with_all_params(self, client: Gitpod) -> ) assert_matches_type(UserGetAuthenticatedUserResponse, user, 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_authenticated_user(self, client: Gitpod) -> None: response = client.users.with_raw_response.get_authenticated_user() @@ -80,7 +80,7 @@ def test_raw_response_get_authenticated_user(self, client: Gitpod) -> None: user = response.parse() assert_matches_type(UserGetAuthenticatedUserResponse, user, 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_authenticated_user(self, client: Gitpod) -> None: with client.users.with_streaming_response.get_authenticated_user() as response: @@ -92,13 +92,13 @@ def test_streaming_response_get_authenticated_user(self, client: Gitpod) -> 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_user(self, client: Gitpod) -> None: user = client.users.get_user() assert_matches_type(UserGetUserResponse, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_get_user_with_all_params(self, client: Gitpod) -> None: user = client.users.get_user( @@ -106,7 +106,7 @@ def test_method_get_user_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(UserGetUserResponse, user, 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_user(self, client: Gitpod) -> None: response = client.users.with_raw_response.get_user() @@ -116,7 +116,7 @@ def test_raw_response_get_user(self, client: Gitpod) -> None: user = response.parse() assert_matches_type(UserGetUserResponse, user, 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_user(self, client: Gitpod) -> None: with client.users.with_streaming_response.get_user() as response: @@ -128,13 +128,13 @@ def test_streaming_response_get_user(self, client: Gitpod) -> 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_set_suspended(self, client: Gitpod) -> None: user = client.users.set_suspended() assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_set_suspended_with_all_params(self, client: Gitpod) -> None: user = client.users.set_suspended( @@ -143,7 +143,7 @@ def test_method_set_suspended_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_set_suspended(self, client: Gitpod) -> None: response = client.users.with_raw_response.set_suspended() @@ -153,7 +153,7 @@ def test_raw_response_set_suspended(self, client: Gitpod) -> None: user = response.parse() assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_set_suspended(self, client: Gitpod) -> None: with client.users.with_streaming_response.set_suspended() as response: @@ -171,13 +171,13 @@ class TestAsyncUsers: "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_delete_user(self, async_client: AsyncGitpod) -> None: user = await async_client.users.delete_user() assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_user_with_all_params(self, async_client: AsyncGitpod) -> None: user = await async_client.users.delete_user( @@ -185,7 +185,7 @@ async def test_method_delete_user_with_all_params(self, async_client: AsyncGitpo ) assert_matches_type(object, user, 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_delete_user(self, async_client: AsyncGitpod) -> None: response = await async_client.users.with_raw_response.delete_user() @@ -195,7 +195,7 @@ async def test_raw_response_delete_user(self, async_client: AsyncGitpod) -> None user = await response.parse() assert_matches_type(object, user, 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_delete_user(self, async_client: AsyncGitpod) -> None: async with async_client.users.with_streaming_response.delete_user() as response: @@ -207,13 +207,13 @@ async def test_streaming_response_delete_user(self, async_client: AsyncGitpod) - 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_authenticated_user(self, async_client: AsyncGitpod) -> None: user = await async_client.users.get_authenticated_user() assert_matches_type(UserGetAuthenticatedUserResponse, user, 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_authenticated_user_with_all_params(self, async_client: AsyncGitpod) -> None: user = await async_client.users.get_authenticated_user( @@ -221,7 +221,7 @@ async def test_method_get_authenticated_user_with_all_params(self, async_client: ) assert_matches_type(UserGetAuthenticatedUserResponse, user, 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_authenticated_user(self, async_client: AsyncGitpod) -> None: response = await async_client.users.with_raw_response.get_authenticated_user() @@ -231,7 +231,7 @@ async def test_raw_response_get_authenticated_user(self, async_client: AsyncGitp user = await response.parse() assert_matches_type(UserGetAuthenticatedUserResponse, user, 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_authenticated_user(self, async_client: AsyncGitpod) -> None: async with async_client.users.with_streaming_response.get_authenticated_user() as response: @@ -243,13 +243,13 @@ async def test_streaming_response_get_authenticated_user(self, async_client: Asy 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_user(self, async_client: AsyncGitpod) -> None: user = await async_client.users.get_user() assert_matches_type(UserGetUserResponse, user, 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_user_with_all_params(self, async_client: AsyncGitpod) -> None: user = await async_client.users.get_user( @@ -257,7 +257,7 @@ async def test_method_get_user_with_all_params(self, async_client: AsyncGitpod) ) assert_matches_type(UserGetUserResponse, user, 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_user(self, async_client: AsyncGitpod) -> None: response = await async_client.users.with_raw_response.get_user() @@ -267,7 +267,7 @@ async def test_raw_response_get_user(self, async_client: AsyncGitpod) -> None: user = await response.parse() assert_matches_type(UserGetUserResponse, user, 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_user(self, async_client: AsyncGitpod) -> None: async with async_client.users.with_streaming_response.get_user() as response: @@ -279,13 +279,13 @@ async def test_streaming_response_get_user(self, async_client: AsyncGitpod) -> N 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_set_suspended(self, async_client: AsyncGitpod) -> None: user = await async_client.users.set_suspended() assert_matches_type(object, user, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_set_suspended_with_all_params(self, async_client: AsyncGitpod) -> None: user = await async_client.users.set_suspended( @@ -294,7 +294,7 @@ async def test_method_set_suspended_with_all_params(self, async_client: AsyncGit ) assert_matches_type(object, user, 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_set_suspended(self, async_client: AsyncGitpod) -> None: response = await async_client.users.with_raw_response.set_suspended() @@ -304,7 +304,7 @@ async def test_raw_response_set_suspended(self, async_client: AsyncGitpod) -> No user = await response.parse() assert_matches_type(object, user, 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_set_suspended(self, async_client: AsyncGitpod) -> None: async with async_client.users.with_streaming_response.set_suspended() as response: diff --git a/tests/api_resources/users/test_dotfiles.py b/tests/api_resources/users/test_dotfiles.py index 6d2ebe96..70e4deb8 100644 --- a/tests/api_resources/users/test_dotfiles.py +++ b/tests/api_resources/users/test_dotfiles.py @@ -17,13 +17,13 @@ class TestDotfiles: 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: Gitpod) -> None: dotfile = client.users.dotfiles.get() assert_matches_type(DotfileGetResponse, dotfile, 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: Gitpod) -> None: dotfile = client.users.dotfiles.get( @@ -31,7 +31,7 @@ def test_method_get_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(DotfileGetResponse, dotfile, 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: Gitpod) -> None: response = client.users.dotfiles.with_raw_response.get() @@ -41,7 +41,7 @@ def test_raw_response_get(self, client: Gitpod) -> None: dotfile = response.parse() assert_matches_type(DotfileGetResponse, dotfile, 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: Gitpod) -> None: with client.users.dotfiles.with_streaming_response.get() as response: @@ -53,13 +53,13 @@ def test_streaming_response_get(self, client: Gitpod) -> 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_set(self, client: Gitpod) -> None: dotfile = client.users.dotfiles.set() assert_matches_type(object, dotfile, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_set_with_all_params(self, client: Gitpod) -> None: dotfile = client.users.dotfiles.set( @@ -67,7 +67,7 @@ def test_method_set_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, dotfile, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_set(self, client: Gitpod) -> None: response = client.users.dotfiles.with_raw_response.set() @@ -77,7 +77,7 @@ def test_raw_response_set(self, client: Gitpod) -> None: dotfile = response.parse() assert_matches_type(object, dotfile, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_set(self, client: Gitpod) -> None: with client.users.dotfiles.with_streaming_response.set() as response: @@ -95,13 +95,13 @@ class TestAsyncDotfiles: "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: AsyncGitpod) -> None: dotfile = await async_client.users.dotfiles.get() assert_matches_type(DotfileGetResponse, dotfile, 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: AsyncGitpod) -> None: dotfile = await async_client.users.dotfiles.get( @@ -109,7 +109,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncGitpod) -> No ) assert_matches_type(DotfileGetResponse, dotfile, 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: AsyncGitpod) -> None: response = await async_client.users.dotfiles.with_raw_response.get() @@ -119,7 +119,7 @@ async def test_raw_response_get(self, async_client: AsyncGitpod) -> None: dotfile = await response.parse() assert_matches_type(DotfileGetResponse, dotfile, 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: AsyncGitpod) -> None: async with async_client.users.dotfiles.with_streaming_response.get() as response: @@ -131,13 +131,13 @@ async def test_streaming_response_get(self, async_client: AsyncGitpod) -> 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 async def test_method_set(self, async_client: AsyncGitpod) -> None: dotfile = await async_client.users.dotfiles.set() assert_matches_type(object, dotfile, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_set_with_all_params(self, async_client: AsyncGitpod) -> None: dotfile = await async_client.users.dotfiles.set( @@ -145,7 +145,7 @@ async def test_method_set_with_all_params(self, async_client: AsyncGitpod) -> No ) assert_matches_type(object, dotfile, 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_set(self, async_client: AsyncGitpod) -> None: response = await async_client.users.dotfiles.with_raw_response.set() @@ -155,7 +155,7 @@ async def test_raw_response_set(self, async_client: AsyncGitpod) -> None: dotfile = await response.parse() assert_matches_type(object, dotfile, 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_set(self, async_client: AsyncGitpod) -> None: async with async_client.users.dotfiles.with_streaming_response.set() as response: diff --git a/tests/api_resources/users/test_pats.py b/tests/api_resources/users/test_pats.py index d00d8d20..d865cc0d 100644 --- a/tests/api_resources/users/test_pats.py +++ b/tests/api_resources/users/test_pats.py @@ -18,13 +18,13 @@ class TestPats: 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_list(self, client: Gitpod) -> None: pat = client.users.pats.list() assert_matches_type(SyncPersonalAccessTokensPage[PersonalAccessToken], pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_list_with_all_params(self, client: Gitpod) -> None: pat = client.users.pats.list( @@ -38,7 +38,7 @@ def test_method_list_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(SyncPersonalAccessTokensPage[PersonalAccessToken], pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_list(self, client: Gitpod) -> None: response = client.users.pats.with_raw_response.list() @@ -48,7 +48,7 @@ def test_raw_response_list(self, client: Gitpod) -> None: pat = response.parse() assert_matches_type(SyncPersonalAccessTokensPage[PersonalAccessToken], pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_list(self, client: Gitpod) -> None: with client.users.pats.with_streaming_response.list() as response: @@ -60,13 +60,13 @@ def test_streaming_response_list(self, client: Gitpod) -> 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_delete(self, client: Gitpod) -> None: pat = client.users.pats.delete() assert_matches_type(object, pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_method_delete_with_all_params(self, client: Gitpod) -> None: pat = client.users.pats.delete( @@ -74,7 +74,7 @@ def test_method_delete_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(object, pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_raw_response_delete(self, client: Gitpod) -> None: response = client.users.pats.with_raw_response.delete() @@ -84,7 +84,7 @@ def test_raw_response_delete(self, client: Gitpod) -> None: pat = response.parse() assert_matches_type(object, pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize def test_streaming_response_delete(self, client: Gitpod) -> None: with client.users.pats.with_streaming_response.delete() as response: @@ -96,13 +96,13 @@ def test_streaming_response_delete(self, client: Gitpod) -> 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(self, client: Gitpod) -> None: pat = client.users.pats.get() assert_matches_type(PatGetResponse, pat, 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: Gitpod) -> None: pat = client.users.pats.get( @@ -110,7 +110,7 @@ def test_method_get_with_all_params(self, client: Gitpod) -> None: ) assert_matches_type(PatGetResponse, pat, 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: Gitpod) -> None: response = client.users.pats.with_raw_response.get() @@ -120,7 +120,7 @@ def test_raw_response_get(self, client: Gitpod) -> None: pat = response.parse() assert_matches_type(PatGetResponse, pat, 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: Gitpod) -> None: with client.users.pats.with_streaming_response.get() as response: @@ -138,13 +138,13 @@ class TestAsyncPats: "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_list(self, async_client: AsyncGitpod) -> None: pat = await async_client.users.pats.list() assert_matches_type(AsyncPersonalAccessTokensPage[PersonalAccessToken], pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> None: pat = await async_client.users.pats.list( @@ -158,7 +158,7 @@ async def test_method_list_with_all_params(self, async_client: AsyncGitpod) -> N ) assert_matches_type(AsyncPersonalAccessTokensPage[PersonalAccessToken], pat, 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_list(self, async_client: AsyncGitpod) -> None: response = await async_client.users.pats.with_raw_response.list() @@ -168,7 +168,7 @@ async def test_raw_response_list(self, async_client: AsyncGitpod) -> None: pat = await response.parse() assert_matches_type(AsyncPersonalAccessTokensPage[PersonalAccessToken], pat, 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_list(self, async_client: AsyncGitpod) -> None: async with async_client.users.pats.with_streaming_response.list() as response: @@ -180,13 +180,13 @@ async def test_streaming_response_list(self, async_client: AsyncGitpod) -> 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 async def test_method_delete(self, async_client: AsyncGitpod) -> None: pat = await async_client.users.pats.delete() assert_matches_type(object, pat, path=["response"]) - @pytest.mark.skip(reason="Prism tests are disabled") + @pytest.mark.skip(reason="Mock server tests are disabled") @parametrize async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> None: pat = await async_client.users.pats.delete( @@ -194,7 +194,7 @@ async def test_method_delete_with_all_params(self, async_client: AsyncGitpod) -> ) assert_matches_type(object, pat, 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_delete(self, async_client: AsyncGitpod) -> None: response = await async_client.users.pats.with_raw_response.delete() @@ -204,7 +204,7 @@ async def test_raw_response_delete(self, async_client: AsyncGitpod) -> None: pat = await response.parse() assert_matches_type(object, pat, 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_delete(self, async_client: AsyncGitpod) -> None: async with async_client.users.pats.with_streaming_response.delete() as response: @@ -216,13 +216,13 @@ async def test_streaming_response_delete(self, async_client: AsyncGitpod) -> 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(self, async_client: AsyncGitpod) -> None: pat = await async_client.users.pats.get() assert_matches_type(PatGetResponse, pat, 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: AsyncGitpod) -> None: pat = await async_client.users.pats.get( @@ -230,7 +230,7 @@ async def test_method_get_with_all_params(self, async_client: AsyncGitpod) -> No ) assert_matches_type(PatGetResponse, pat, 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: AsyncGitpod) -> None: response = await async_client.users.pats.with_raw_response.get() @@ -240,7 +240,7 @@ async def test_raw_response_get(self, async_client: AsyncGitpod) -> None: pat = await response.parse() assert_matches_type(PatGetResponse, pat, 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: AsyncGitpod) -> None: async with async_client.users.pats.with_streaming_response.get() as response: diff --git a/tests/test_client.py b/tests/test_client.py index 81db6c83..92b0eea3 100644 --- a/tests/test_client.py +++ b/tests/test_client.py @@ -981,6 +981,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() @@ -1907,6 +1915,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()