Contributing

qianmoQqianmoQ· 更新于 2026-10-19· 阅读 6 分钟· 0 次阅读

登录后可跨设备保存划线和私人笔记登录

Contributing

Slack: testcontainers-native on slack.testcontainers.com Stability: Experimental

Contributions are welcome! For any feedback and suggestions, use GitHub Issues.

Developer Environment

You can use one of the following developer environments:

  • Dev Containers - for local development, testing, and also for the documentation site development.
  • GitHub Codespaces (with a Dev Containers)
  • Experimental: Nix

Open in GitHub Codespaces

Community Slack

We use the #testcontainers-native channel on Testcontainers Slack. Please join this channel if you want to discuss contributions/strategy/whatever. GitHub Issues are recommended for most of the proposals and bug reports though.

Code patches

To propose a code patch, just submit a pull request to the repository. No need to create a GitHub issue if you want to suggest a simple patch, pull requests are more than enough for it.

Building the project

You need CMake 3.16.3 and Golang 1.19+. At the moment there are not so many configuration flags, so the build is straightforward:

cmake .
cmake --build .
ctest --output-on-failure

To skip the demo builds and tests, use the SKIP_DEMOS variable:

cmake -DSKIP_DEMOS=true .

Contributing to the Documentation

The documentation is structured in the MkDocs format and uses Material for MkDocs. To develop the site in this repository, start it in a Dev Container and use the following commands:

mkdocs serve
mkdocs build

Codestyle

Public APIs

  • snake_case is used to name methods
  • tc_ is used as a prefix for all exported Testcontainers functions
  • When possible, we try to avoid special Golang types in public API and try to expose wrapper types
  • const is important for users, and please add it to your arguments when possible. There is no const in Golang, so some typedef injection is needed when importing CGo

评论

登录后参与评论

正在加载评论…