php / php/php-src

Zend: add missing ZPP tests

Open
#23,280 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

Category: Engine Category: Tests Good first issue
Dominant language
C
Stars
40.4k
Forks
8.1k
Avg merge
2d 13h
Merged PRs (30d)
96

Description

Effectively continuing the work started in #23192.

This is a good first issues for newcomers.

The missing specifiers are:

  • Z_PARAM_ENUM(dest, _ce)
  • old "a"
    • Z_PARAM_ARRAY_EX2(dest, check_null, deref, separate)
    • Z_PARAM_ARRAY_EX(dest, check_null, separate)
    • Z_PARAM_ARRAY(dest)
    • Z_PARAM_ARRAY_OR_NULL(dest)
  • old "A"
    • Z_PARAM_ARRAY_OR_OBJECT_EX2(dest, check_null, deref, separate)
    • Z_PARAM_ARRAY_OR_OBJECT_EX(dest, check_null, separate)
    • Z_PARAM_ARRAY_OR_OBJECT(dest)
  • old "h"
    • Z_PARAM_ARRAY_HT_EX2(dest, check_null, deref, separate)
    • Z_PARAM_ARRAY_HT_EX(dest, check_null, separate)
    • Z_PARAM_ARRAY_HT(dest)
    • Z_PARAM_ARRAY_HT_OR_NULL(dest)
  • array|int:
    • Z_PARAM_ARRAY_HT_OR_LONG_EX(dest_ht, dest_long, is_null, allow_null)
    • Z_PARAM_ARRAY_HT_OR_LONG(dest_ht, dest_long)
    • Z_PARAM_ARRAY_HT_OR_LONG_OR_NULL(dest_ht, dest_long, is_null)
  • array|string:
    • Z_PARAM_ARRAY_HT_OR_STR_EX(dest_ht, dest_str, allow_null)
    • Z_PARAM_ARRAY_HT_OR_STR(dest_ht, dest_str)
    • Z_PARAM_ARRAY_HT_OR_STR_OR_NULL(dest_ht, dest_str)
  • old "H"
    • Z_PARAM_ARRAY_OR_OBJECT_HT_EX2(dest, check_null, deref, separate)
    • Z_PARAM_ARRAY_OR_OBJECT_HT_EX(dest, check_null, separate)
    • Z_PARAM_ARRAY_OR_OBJECT_HT(dest)
  • old "f"
    • Z_PARAM_FUNC_EX2(dest_fci, dest_fcc, check_null, deref, free_trampoline)
    • Z_PARAM_FUNC_EX(dest_fci, dest_fcc, check_null, deref)
    • Z_PARAM_FUNC(dest_fci, dest_fcc)
    • Z_PARAM_FUNC_NO_TRAMPOLINE_FREE(dest_fci, dest_fcc)
    • Z_PARAM_FUNC_OR_NULL(dest_fci, dest_fcc)
    • Z_PARAM_FUNC_NO_TRAMPOLINE_FREE_OR_NULL(dest_fci, dest_fcc)
  • old "p"
    • Z_PARAM_PATH_EX(dest, dest_len, check_null, deref)
    • Z_PARAM_PATH(dest, dest_len)
    • Z_PARAM_PATH_OR_NULL(dest, dest_len)
  • old "P"
    • Z_PARAM_PATH_STR_EX(dest, check_null, deref)
    • Z_PARAM_PATH_STR(dest)
    • Z_PARAM_PATH_STR_OR_NULL(dest)
  • old "s"
    • Z_PARAM_STRING_EX(dest, dest_len, check_null, deref)
    • Z_PARAM_STRING(dest, dest_len)
    • Z_PARAM_STRING_OR_NULL(dest, dest_len)
  • old "S"
    • Z_PARAM_STR_EX(dest, check_null, deref)
    • Z_PARAM_STR(dest)
    • Z_PARAM_STR_OR_NULL(dest)
  • string|int
    • Z_PARAM_STR_OR_LONG_EX(dest_str, dest_long, is_null, allow_null)
    • Z_PARAM_STR_OR_LONG(dest_str, dest_long)
    • Z_PARAM_STR_OR_LONG_OR_NULL(dest_str, dest_long, is_null)
  • old "z"
    • Z_PARAM_ZVAL_EX2(dest, check_null, deref, separate)
    • Z_PARAM_ZVAL_EX(dest, check_null, separate)
    • Z_PARAM_ZVAL(dest)
    • Z_PARAM_ZVAL_OR_NULL(dest)
  • old "+" and "*"
    • Z_PARAM_VARIADIC_EX(spec, dest, dest_num, post_varargs)
    • Z_PARAM_VARIADIC(spec, dest, dest_num)
    • Z_PARAM_VARIADIC_WITH_NAMED(dest, dest_num, dest_named)

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the work from issue #23192 and the listed Zend parameter-parsing specifiers. Add coverage for the unchecked macros and variants, then verify that the corresponding ZPP tests cover each listed case.

Written by the indexing model from the issue text.

Assessment

Tech stack
c
Domain
testing-qa
Issue type
Feature
Difficulty
4/5
Estimated time
3-5 days
Activity status
Quiet
Clarity
Mostly clear
Newbie friendliness
52/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.