{
    "mode": "perldoc",
    "parameter": "Test2::Event::Plan",
    "section": "",
    "url": "https://www.chedong.com/phpMan.php/perldoc/Test2%3A%3AEvent%3A%3APlan/json",
    "generated": "2026-06-15T14:11:32Z",
    "synopsis": "use Test2::API qw/context/;\nuse Test2::Event::Plan;\nmy $ctx = context();\n# Plan for 10 tests to run\nmy $event = $ctx->plan(10);\n# Plan to skip all tests (will exit 0)\n$ctx->plan(0, skipall => \"These tests need to be skipped\");",
    "sections": {
        "NAME": {
            "content": "Test2::Event::Plan - The event of a plan\n",
            "subsections": []
        },
        "DESCRIPTION": {
            "content": "Plan events are fired off whenever a plan is declared, done testing is called, or a subtext\ncompletes.\n",
            "subsections": []
        },
        "SYNOPSIS": {
            "content": "use Test2::API qw/context/;\nuse Test2::Event::Plan;\n\nmy $ctx = context();\n\n# Plan for 10 tests to run\nmy $event = $ctx->plan(10);\n\n# Plan to skip all tests (will exit 0)\n$ctx->plan(0, skipall => \"These tests need to be skipped\");\n",
            "subsections": []
        },
        "ACCESSORS": {
            "content": "$num = $plan->max\nGet the number of expected tests\n\n$dir = $plan->directive\nGet the directive (such as TODO, skipall, or noplan).\n\n$reason = $plan->reason\nGet the reason for the directive.\n",
            "subsections": []
        },
        "SOURCE": {
            "content": "The source code repository for Test2 can be found at http://github.com/Test-More/test-more/.\n",
            "subsections": []
        },
        "MAINTAINERS": {
            "content": "Chad Granum <exodist@cpan.org>\n",
            "subsections": []
        },
        "AUTHORS": {
            "content": "Chad Granum <exodist@cpan.org>\n",
            "subsections": []
        },
        "COPYRIGHT": {
            "content": "Copyright 2020 Chad Granum <exodist@cpan.org>.\n\nThis program is free software; you can redistribute it and/or modify it under the same terms as\nPerl itself.\n\nSee http://dev.perl.org/licenses/\n",
            "subsections": []
        }
    },
    "summary": "Test2::Event::Plan - The event of a plan",
    "flags": [],
    "examples": [],
    "see_also": []
}