• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

bleedingdeacons / trumpet / 30695858101
94%

Build:
DEFAULT BRANCH: main
Ran 01 Aug 2026 10:31AM UTC
Jobs 1
Files 11
Run time 1min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

01 Aug 2026 10:30AM UTC coverage: 92.857% (-0.7%) from 93.527%
30695858101

push

github

web-flow
Take WordPress stand-ins from wp-mocks, and move to PHPUnit 10.5 (#37)

* test: take WordPress stand-ins from wp-mocks, and move to PHPUnit 10.5

Trumpet was the last plugin in the suite on PHPUnit 9.6. It stayed there
because it had nothing to move with: its own bootstrap comment explained that
pulling in WP_Mock for a handful of functions was heavier than the thing it
replaced, which was true, and was also what left it 462 lines of hand-rolled
WordPress and a schema version behind. bleedingdeacons/wp-mocks answers both.

phpunit ^9.6 → ^10.5, and phpunit.xml with it: the 10.5 schema, coverage
include/exclude moved from <coverage> to <source>, cacheResultFile →
cacheDirectory, and the convertErrorsToExceptions family dropped (10.x always
converts). beStrictAboutTestsThatDoNotTestAnything goes too — it is the
default now.

The bootstrap keeps only what is not shared WordPress: the plugin constants,
the Unity sibling autoloader CI depends on, and $wp_embed — a global *object*,
not a function, so outside what the stubs cover.

Notable in the tests:

  - The hook stubs are gone. add_action(), do_action() and apply_filters()
    were no-ops here; Brain Monkey owns them now, which is what makes hook
    expectations possible at all — and a bootstrap-defined stub would have
    shadowed its definitions silently.

  - Five test classes applied MockeryPHPUnitIntegration on top of the base
    class that now also applies it. Two levels of the same trait makes
    assertPostConditions() recurse until the process dies; the duplicates go.

  - Tests\TestCase pins WpState::$now to 2026-01-01, because the renderer
    reads the post date through get_the_time()/get_post_timestamp() and both
    derive from it. The old local stubs returned that instant outright, so
    pinning it keeps the rendered output, and the assertions on it, unchanged.

  - setFields() replaces rather than merges, matching what assigning
    $GLOBALS['trumpet_test_fields'][$id] used to do. A t... (continued)

832 of 896 relevant lines covered (92.86%)

5.78 hits per line

Coverage Regressions

Lines Coverage ∆ File
6
95.48
-3.39% trumpet/trumpet/src/Trumpet/Announcement/Announcement.php
Jobs
ID Job ID Ran Files Coverage
1 30695858101.1 01 Aug 2026 10:31AM UTC 11
92.86
GitHub Action Run
Source Files on build 30695858101
  • Tree
  • List 11
  • Changed 1
  • Source Changed 0
  • Coverage Changed 1
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #30695858101
  • f4c8d2af on github
  • Prev Build on main (#30670099437)
  • Next Build on main (#30696044057)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc