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

Yoast / wpseo-woocommerce / ce43578a0678211f4d1db5a873adafc713855847

10 Aug 2026 09:44AM UTC coverage: 49.652% (-0.01%) from 49.666%
ce43578a0678211f4d1db5a873adafc713855847

Pull #1182

github

web-flow
Merge 2a1fdc396 into 013d74267
Pull Request #1182: Add a src folder served by a compiled dependency injection container

110 of 188 branches covered (58.51%)

Branch coverage included in aggregate %.

0 of 43 new or added lines in 5 files covered. (0.0%)

1031 of 2110 relevant lines covered (48.86%)

4.12 hits per line

Source File
Press 'n' to go to next uncovered line, 'b' for previous

0.0
/src/wordpress/wrapper.php
1
<?php
2

3
namespace Yoast\WP\SEO\WooCommerce\WordPress;
4

5
use WP_Query;
6
use wpdb;
7

8
/**
9
 * Wrapper class for WordPress globals.
10
 * This consists of factory functions to inject WP globals into the dependency container.
11
 */
12
class Wrapper {
13

14
        /**
15
         * Wrapper method for returning the wpdb object for use in dependency injection.
16
         *
17
         * @return wpdb The wpdb global.
18
         */
NEW
19
        public static function get_wpdb() {
×
NEW
20
                global $wpdb;
×
21

NEW
22
                return $wpdb;
×
23
        }
24

25
        /**
26
         * Wrapper method for returning the wp_query object for use in dependency injection.
27
         *
28
         * @return WP_Query The wp_query global.
29
         */
NEW
30
        public static function get_wp_query() {
×
NEW
31
                global $wp_query;
×
32

NEW
33
                return $wp_query;
×
34
        }
35
}
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