awesome-repositories.com
博客
awesome-repositories.com

通过 AI 驱动的搜索,发现最优秀的开源仓库。

探索精选搜索开源替代品自托管软件博客网站地图
项目关于排名机制媒体报道MCP 服务器
法律隐私政策服务条款
© 2026 Bringes Technology SRL·VAT RO45896025·hello@awesome-repositories.com
·
philsquared avatar

philsquared/Catch

0
View on GitHub↗
20,456 星标·3,240 分支·C++·BSL-1.0·7 次浏览discord.gg/4CWS9zD↗

Catch

Catch is a C++ testing toolset providing frameworks for unit testing, behavior-driven development, and micro-benchmarking. It serves as a utility for software quality assurance and test-driven development, allowing developers to validate code correctness and measure the execution time of small code fragments.

The project features a header-only distribution, enabling integration by including a single file. It utilizes expression-decomposition assertions to provide detailed failure messages and employs a self-registering test discovery system that uses macros to register test cases without manual configuration.

The framework supports hierarchical test grouping through nested sections and tags. It further provides high-resolution clock-based timing for performance analysis and structures tests around human-readable requirements for behavior-driven development.

Features

  • C++ Unit Testing - Provides a comprehensive unit testing framework for validating C++ code correctness through assertions.
  • Micro-Benchmarking - Implements a micro-benchmarking tool to identify performance bottlenecks in C++ code segments.
  • C++ Microbenchmarking - Enables high-precision measurement of execution time for small, isolated C++ code fragments.
  • Preprocessor-Defined Test Registrations - Uses preprocessor macros to automatically register test cases at startup for seamless discovery.
  • Behavior Driven Development Frameworks - Provides a framework for structuring C++ tests around human-readable requirements and system behaviors.
  • Automatic Test Discovery - Employs static initialization for automatic test discovery, removing the need for manual test registration lists.
  • Unit Testing Frameworks - Provides a full-featured unit testing framework for defining and executing automated C++ tests.
  • Header-Only Libraries - Distributed as a header-only library to simplify integration by including a single file.
  • Performance Benchmarks - Includes tools for measuring and tracking the execution performance of small code fragments.
  • Test-Driven Development Workflow - Supports an iterative design process by providing the tooling necessary to write failing tests before implementation.
  • Expression Decomposition - Implements expression decomposition to log the actual values of operands when a boolean assertion fails.
  • Execution Time Benchmarks - Provides high-resolution timing benchmarks to measure the execution duration of small C++ code fragments.
  • Hierarchical Suite Grouping - Supports organizing tests into nested sections and tags to manage shared setup and selective execution.
  • Debugging and Testing - Modern, header-only C++ unit testing framework.
  • 测试框架 - Unit testing framework.

Star 历史

philsquared/catch 的 Star 历史图表philsquared/catch 的 Star 历史图表

AI 搜索

探索更多 awesome 仓库

用简单的语言描述您的需求 —— AI 将根据相关性为您从数千个精选开源项目中进行排序。

Start searching with AI

常见问题解答

philsquared/catch 是做什么的?

Catch is a C++ testing toolset providing frameworks for unit testing, behavior-driven development, and micro-benchmarking. It serves as a utility for software quality assurance and test-driven development, allowing developers to validate code correctness and measure the execution time of small code fragments.

philsquared/catch 的主要功能有哪些?

philsquared/catch 的主要功能包括:C++ Unit Testing, Micro-Benchmarking, C++ Microbenchmarking, Preprocessor-Defined Test Registrations, Behavior Driven Development Frameworks, Automatic Test Discovery, Unit Testing Frameworks, Header-Only Libraries。

philsquared/catch 有哪些开源替代品?

philsquared/catch 的开源替代品包括: doctest/doctest — doctest is a lightweight C++ unit testing framework and assertion library. It provides a single-header implementation… catchorg/catch2 — Catch2 is a comprehensive framework for C++ software validation, providing an environment for unit testing,… junit-team/junit4 — JUnit 4 is a unit testing framework for Java that provides a structured approach to writing and running automated… onqtam/doctest — doctest is a unit testing framework and assertion library for C++ delivered as a single-header library. It provides a… jasmine/jasmine — Jasmine is a JavaScript testing framework and test runner designed for behavior-driven development. It provides a… throwtheswitch/unity — Unity is a lightweight unit testing framework for C, providing the assertion library, test runner, and reporting…

Catch 的开源替代方案

相似的开源项目,按与 Catch 的功能重合度排序。
  • doctest/doctestdoctest 的头像

    doctest/doctest

    6,765在 GitHub 上查看↗

    doctest is a lightweight C++ unit testing framework and assertion library. It provides a single-header implementation that eliminates complex build dependencies, allowing developers to write and execute test cases directly within their source code. The framework is distinguished by its focus on compile-time performance and binary overhead. It uses conditional compilation guards to strip all testing logic and metadata from production binaries. Additionally, it features hierarchical subcases that re-execute parent setup code to isolate different execution paths within a single test case. Its c

    C++c-plus-pluscppcpp11
    在 GitHub 上查看↗6,765
  • catchorg/catch2catchorg 的头像

    catchorg/Catch2

    20,198在 GitHub 上查看↗

    Catch2 is a comprehensive framework for C++ software validation, providing an environment for unit testing, integration verification, and performance analysis. It enables developers to define and execute automated test suites and micro-benchmarks directly within their applications. The framework is distinguished by its header-only distribution, which allows for integration into existing build systems without requiring complex external dependencies. It utilizes a hierarchical section-based execution model that supports behavior-driven testing, allowing for shared setup and teardown logic acros

    C++bddcppcpp14
    在 GitHub 上查看↗20,198
  • junit-team/junit4junit-team 的头像

    junit-team/junit4

    8,525在 GitHub 上查看↗

    JUnit 4 is a unit testing framework for Java that provides a structured approach to writing and running automated tests. At its core, it uses annotation-based test discovery to automatically identify test methods, and a pluggable runner architecture that controls how test classes are discovered, instantiated, and executed. The framework builds test execution around a chain of Statement objects, each wrapping the next to layer behaviors such as timeouts and retries, and uses Java reflection to dynamically invoke test methods and access private fields for setup and teardown operations. The fram

    Java
    在 GitHub 上查看↗8,525
  • onqtam/doctestonqtam 的头像

    onqtam/doctest

    6,768在 GitHub 上查看↗

    doctest is a unit testing framework and assertion library for C++ delivered as a single-header library. It provides a test runner with a command line interface to execute tests, filter test suites, and generate execution reports. The framework supports in-source unit testing and allows for the complete removal of testing logic from compiled binaries via preprocessor stripping to eliminate performance overhead in production environments. It also enables cross-binary test registry sharing, allowing one executable to utilize the test runner of another. Capabilities include parameterized testing

    C++
    在 GitHub 上查看↗6,768
  • 查看 Catch 的所有 30 个替代方案→