New to Claude Skills? Learn how to install them →

openai on GitHub

Integration Tests

OfficialFree

Run integration tests for OpenAI Agents SDK seamlessly.

Get this skill

Free · Opens the source repo

What Integration Tests does

The Integration Tests skill is designed for developers using the OpenAI Agents Python SDK to ensure the reliability and compatibility of their packages. This skill runs a comprehensive suite of integration tests against both the wheel and source distribution of the SDK, validating that everything works as intended in isolated environments. By utilizing this skill, developers can confirm that their integrations with OpenAI models and tools are functioning correctly before deployment.

To execute the integration tests, users must run a specific command from the repository root, which sets up the necessary environment variables and installs the required dependencies. The skill ensures that both the wheel and source distributions are rebuilt and tested, checking for supported imports, optional dependencies, and various workflows such as Realtime and voice. This thorough validation process helps catch potential issues early, ensuring that the SDK is ready for release or further development.

This skill is particularly useful for developers who need to perform regression checks or validate package compatibility after making changes to their codebase. It can also be beneficial for teams looking to automate their testing processes as part of a continuous integration workflow. By running the integration tests, developers can gain confidence in the stability of their applications that rely on the OpenAI SDK.

However, it is important to note that this skill is not intended for general-purpose testing or debugging of non-OpenAI related code. It specifically targets the OpenAI Agents SDK and its integrations, making it less suitable for broader testing scenarios outside of this context.

When to use it

Use this skill when preparing for a release or when you need to validate the integration of the OpenAI SDK in your application.

When not to use it

This skill is not suitable for testing unrelated code or for use cases outside the OpenAI Agents SDK context.

What you can build with it

Release Validation

Before releasing a new version of your application, run the integration tests to ensure all OpenAI SDK functionalities work as expected.

Regression Checks

After making changes to your code, use this skill to perform regression checks and confirm that existing features are not broken.

Automated Testing in CI/CD

Integrate this skill into your CI/CD pipeline to automate the testing of your OpenAI SDK integrations with every build.

How to install Integration Tests

View source

1. Install with the skills CLI

npx skills add openai/openai-agents-python/integration-tests --agent claude-code

2. Or install it manually

Download the skill folder and drop it into ~/.claude/skills/ for all projects, or .claude/skills/ to scope it to one repo. Restart Claude Code so it picks up the new skill.

Anthropic's agentic coding CLI, and the reference implementation of Agent Skills. Drop a skill folder into ~/.claude/skills and Claude Code loads it automatically whenever a task matches the skill's description. Claude Code docs

Inside SKILL.md

Written by openai

Integration Tests

Overview

Run the release-oriented integration suite against the exact wheel and source distribution produced by uv build. The runner installs both artifacts into isolated environments and validates supported imports, optional extras, OpenAI model adapters, hosted tools, Realtime, and voice workflows.

Execution requirements

  • Fresh isolated environments download optional dependencies from PyPI and connect to the configured API providers.
  • When the execution environment requires approval for package downloads or configured provider connections, request elevated command execution (sandbox_permissions=require_escalated). Retry with the required network permissions before classifying a connectivity failure as an SDK regression.

Release workflow

Run this command from the repository root:

env UV_DEFAULT_INDEX=https://pypi.org/simple \
  OPENAI_AGENTS_INTEGRATION_STRICT=1 \
  OPENAI_AGENTS_INTEGRATION_EXTERNAL_PROVIDERS=1 \
  OPENAI_AGENTS_INTEGRATION_DIRECT_PROVIDERS=0 \
  make integration-tests-release
  • Use the release profile as the default whenever $integration-tests is invoked without a narrower request.
  • Use OpenRouter as the standard multi-provider gateway. Add provider-specific direct connections only when the user explicitly requests that additional credential matrix.
  • Use existing OPENAI_API_KEY and OPENROUTER_API_KEY values without printing them. The release target enforces strict mode, so missing required service configuration fails instead of skipping.
  • The command rebuilds the wheel and source distribution, creates isolated virtual environments, checks public imports and optional dependencies, runs the release-oriented live suites, and executes the local Docker security contract against both artifacts.
  • Do not run watch mode, modify source files, create a branch, commit, push, or open a pull request as part of this skill.

Paired release validation

When the user requests both pre-release checks, run $examples-auto-run first and follow that skill's required per-example behavioral validation. Then run the command above and report the examples and integration outcomes separately. Invoking $integration-tests alone does not implicitly start the examples suite.

Focused commands

Use a focused target only when the user specifically asks to narrow the run:

env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-packaging
env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-security
env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-core
env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-providers
env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-hosted
env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-realtime
env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-voice
env UV_DEFAULT_INDEX=https://pypi.org/simple make integration-tests-extras

For the minimum supported Python package boundary, use:

env UV_DEFAULT_INDEX=https://pypi.org/simple \
  OPENAI_AGENTS_INTEGRATION_PYTHON=3.10 \
  make integration-tests-packaging

Nightly and manual profiles include additional capability-specific or higher-cost checks. Run them only when explicitly requested; use the configured OpenRouter matrix by default and include direct providers only when explicitly selected.

Reporting

Report the final pass, fail, skip, and deselection counts for each isolated environment. If a command fails, identify the exact profile, package environment, failing test, and actionable error. Separate product regressions from missing credentials, unsupported hosted features, dependency installation failures, and execution-environment restrictions.

Frequently asked questions about Integration Tests

Similar skills