# cookiebot/4.7.2/tests/integration/addons/Test_Facebook_For_Woocommerce.php

Cookiebot by Usercentrics – Automatic Cookie Banner for GDPR/CCPA &amp; Google Consent Mode, version 4.7.2. 36 lines.

- Page: https://pluginprobe.com/plugins/cookiebot/4.7.2/code/tests/integration/addons/Test_Facebook_For_Woocommerce.php
- Raw: https://pluginprobe.com/plugins/cookiebot/4.7.2/raw/tests/integration/addons/Test_Facebook_For_Woocommerce.php
- Modified: 2025-03-27T15:58:12+00:00

Line numbers below start at 1. Link to a line or a range by appending a fragment to the
page URL, for example `https://pluginprobe.com/plugins/cookiebot/4.7.2/code/tests/integration/addons/Test_Facebook_For_Woocommerce.php#L10-L20`.

```php
<?php

namespace cybot\cookiebot\tests\integration\addons;

use cybot\cookiebot\addons\controller\addons\facebook_for_woocommerce\Facebook_For_Woocommerce;
use PHPUnit\Framework\ExpectationFailedException;
use SebastianBergmann\RecursionContext\InvalidArgumentException;
use WP_UnitTestCase;

class Test_Facebook_For_Woocommerce extends WP_UnitTestCase {

	/**
	 * @covers \cybot\cookiebot\addons\controller\addons\facebook_for_woocommerce\Facebook_For_Woocommerce
	 * @throws ExpectationFailedException
	 * @throws InvalidArgumentException
	 * @throws \Exception
	 */
	public function test_facebook_for_woocommerce_main_file() {
		$content = Facebook_For_Woocommerce::get_svn_file_content();

		$this->assertNotFalse( strpos( $content, 'WC_Facebookcommerce' ) );
	}

	/**
	 * @covers \cybot\cookiebot\addons\controller\addons\facebook_for_woocommerce\Facebook_For_Woocommerce
	 * @throws ExpectationFailedException
	 * @throws InvalidArgumentException
	 * @throws \Exception
	 */
	public function test_facebook_for_woocommerce_hooks() {
		$content = Facebook_For_Woocommerce::get_svn_file_content( 'facebook-commerce-pixel-event.php' );

		$this->assertNotFalse( strpos( $content, 'apply_filters( \'wc_facebook_pixel_script_attributes\',' ) );
	}
}

```
