Skip to content

ci: run proxy-cache plugin subdirectory tests#13613

Open
nic-6443 wants to merge 2 commits into
apache:masterfrom
nic-6443:ci/run-plugin-subdir-tests
Open

ci: run proxy-cache plugin subdirectory tests#13613
nic-6443 wants to merge 2 commits into
apache:masterfrom
nic-6443:ci/run-plugin-subdir-tests

Conversation

@nic-6443

@nic-6443 nic-6443 commented Jun 26, 2026

Copy link
Copy Markdown
Member

Description

The plugin test shards use globs that only match top-level .t files:

- t/plugin/[a-k]*.t
- t/stream-plugin t/plugin/[l-z]*.t

A glob like t/plugin/[l-z]*.t doesn't match a directory (t/plugin/proxy-cache), and * doesn't cross /, so plugin tests living in subdirectories are never handed to prove and never run in CI. This adds t/plugin/proxy-cache to the [l-z] shard so prove -r recurses it, restoring coverage for:

t/plugin/proxy-cache/disk.t
t/plugin/proxy-cache/memory.t

Both pass locally.

The other subdirectories are left out on purpose:

  • t/plugin/dubbo-proxy/: upstream.t passes, but route.t TEST 1 is a stale test — current apisix logs config_yaml.lua:339: unknown plugin [dubbo-proxy] when dubbo is disabled globally, which its no_error_log check rejects (the route itself still works). Needs a separate test fix.
  • t/plugin/ext-plugin/: several tests need a real external plugin runner that CI doesn't set up.

Checklist

  • I have explained the need for this PR and the problem it solves
  • I have explained the changes or the new features added to this PR
  • I have verified that this change is backward compatible

The `t/plugin/[a-k]*.t` / `t/plugin/[l-z]*.t` matrix globs only match
top-level `.t` files, so plugin tests that live in subdirectories were never
executed by CI. This silently dropped coverage for:

    t/plugin/proxy-cache/{disk,memory}.t
    t/plugin/dubbo-proxy/{route,upstream}.t

The dubbo backend is already started in build.yml, so the dubbo-proxy tests
were prepared to run but the glob never reached them. Add the two directories
to the matrix so `prove -r` recurses them.

The ext-plugin subdirectory tests are intentionally left out for now: several
of them require a real external plugin runner that CI does not currently set
up, so enabling them needs separate work.
Copilot AI review requested due to automatic review settings June 26, 2026 07:02
@dosubot dosubot Bot added size:XS This PR changes 0-9 lines, ignoring generated files. CI labels Jun 26, 2026

Copilot AI left a comment

Copy link
Copy Markdown

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull request overview

This PR fixes CI test sharding for plugin tests by ensuring Perl .t tests located under plugin subdirectories are included in the GitHub Actions prove invocation, so they actually run in CI.

Changes:

  • Extend the plugin test matrix entries to include t/plugin/dubbo-proxy and t/plugin/proxy-cache so prove -r will recurse into those directories.
  • Keep the existing top-level plugin .t glob sharding intact while augmenting it with the missing subdirectory-based suites.

💡 Add Copilot custom instructions for smarter, more guided reviews. Learn how to get started.

Enabling dubbo-proxy surfaced a stale test: dubbo-proxy/route.t TEST 1 fails
because current apisix logs `config_yaml.lua:339: unknown plugin [dubbo-proxy]`
when dubbo is disabled globally, and the test's implicit no_error_log check
rejects it. The route still works (returns "hello world"); only the test's
error_log expectation is out of date from never being run. That's a separate
test fix, so scope this PR to the proxy-cache directory, which passes as-is.
@nic-6443 nic-6443 changed the title ci: run proxy-cache and dubbo-proxy plugin subdirectory tests ci: run proxy-cache plugin subdirectory tests Jun 26, 2026
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

CI size:XS This PR changes 0-9 lines, ignoring generated files.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants