nextcloud / nextcloud/server

Improve PHPUnit code coverage speed

Open
#14,622 3 comments 1 reaction 0 assignees View on GitHub

Nobody has claimed this yet.

1. to develop developer experience enhancement performance 🚀 technical debt tests
Dominant language
PHP
Stars
36.9k
Forks
5.2k
Avg merge
2d 3h
Merged PRs (30d)
713

Description

There seem to be some more tricks to enhance the performance of PHPUnit code coverage. It's described in this blog post: https://thephp.cc/news/2019/01/faster-code-coverage

Basics is to dump the Xdebug filter file and then use it in the phpunit command with the --prepend option. This seems to reduce the time it takes to do the run of up to 60%.

cc @nickvergessen @rullzer @kesselb @blizzz

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 reading the linked blog post, then find the repository's PHPUnit code-coverage command or configuration. Compare the current invocation with the Xdebug filter-file and --prepend approach described there. Done means the coverage run is measurably faster without changing its results.

Written by the indexing model from the issue text.

Assessment

Tech stack
php
Domain
performance, testing-qa
Issue type
Refactor
Difficulty
4/5
Estimated time
3-5 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
32/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.