[wp-trac] [WordPress Trac] #43067: Code coverage cannot be run
WordPress Trac
noreply at wordpress.org
Wed Feb 7 12:30:04 UTC 2018
#43067: Code coverage cannot be run
------------------------------+------------------
Reporter: jipmoors | Owner:
Type: defect (bug) | Status: new
Priority: normal | Milestone: 5.0
Component: Build/Test Tools | Version:
Severity: normal | Resolution:
Keywords: needs-patch | Focuses:
------------------------------+------------------
Changes (by netweb):
* keywords: => needs-patch
Comment:
This ticket needs a refreshed patch, it needs to exclude the 3rd party
code as referenced by @johnbillion in comment:1
That said, running `phpunit --coverage-html some/folder` works for me:
{{{
#!sh
❯ phpunit --coverage-html tests/phpunit/build/logs/
Installing...
Running as single site... To run multisite, use -c
tests/phpunit/multisite.xml
Not running ajax tests. To execute these, use --group ajax.
Not running ms-files tests. To execute these, use --group ms-files.
Not running external-http tests. To execute these, use --group external-
http.
PHPUnit 5.7.26 by Sebastian Bergmann and contributors.
............................................................. 61 / 8529
( 0%)
............................................................. 122 / 8529
( 1%)
...
............................................................. 8479 / 8529
( 99%)
...................................SSSSSSSSSSSSSS. 8529 / 8529
(100%)
You should really fix these slow tests (>150ms)...
1. 10962ms to run
WP_Test_REST_Users_Controller:test_get_items_pagination_headers
2. 8505ms to run
WP_Test_REST_Posts_Controller:test_get_items_pagination_headers
3. 6038ms to run
Tests_XMLRPC_mt_getRecentPostTitles:test_no_editable_posts
4. 5615ms to run WP_Test_REST_Users_Controller:test_get_items_per_page
5. 4998ms to run WP_Test_REST_Users_Controller:test_get_items_page
6. 4707ms to run
Tests_WP_Customize_Manager:test_import_theme_starter_content
7. 4433ms to run Tests_Import_Import:test_double_import
8. 4062ms to run
WP_Test_REST_Schema_Initialization:test_build_wp_api_client_fixtures
9. 3858ms to run Tests_Import_Import:test_small_import
10. 3366ms to run
WP_Test_REST_Categories_Controller:test_get_terms_pagination_headers
...and there are 6931 more above your threshold hidden from view
Time: 58.12 minutes, Memory: 1104.14MB
OK, but incomplete, skipped, or risky tests!
Tests: 8529, Assertions: 35560, Skipped: 34, Risky: 8.
Generating code coverage report in HTML format ... done
}}}
* [[Image(https://cldup.com/RwLVWNDrXo.png)]]
--
Ticket URL: <https://core.trac.wordpress.org/ticket/43067#comment:7>
WordPress Trac <https://core.trac.wordpress.org/>
WordPress publishing platform
More information about the wp-trac
mailing list