From d31f68bbf97f142e2bdb46e53ea3d920a99e83e5 Mon Sep 17 00:00:00 2001 From: balexey88 Date: Fri, 18 Oct 2024 16:51:21 +0300 Subject: [PATCH] Prepare release --- tests/ClassPolylangProTest.php | 12 ++++++++++++ vendor/bin/.phpunit.result.cache | 2 +- vendor/composer/installed.php | 4 ++-- 3 files changed, 15 insertions(+), 3 deletions(-) diff --git a/tests/ClassPolylangProTest.php b/tests/ClassPolylangProTest.php index f74d9e0..973d85a 100644 --- a/tests/ClassPolylangProTest.php +++ b/tests/ClassPolylangProTest.php @@ -5,6 +5,9 @@ use PHPUnit\Framework\TestCase; use Mockery\Adapter\Phpunit\MockeryPHPUnitIntegration; use Brain\Monkey; +use Brain\Monkey\Actions; +use Brain\Monkey\Filters; +use Brain\Monkey\Functions; use wpCloud\StatelessMedia\WPStatelessStub; /** @@ -33,6 +36,15 @@ public function testShouldInitHooks() { self::assertNotFalse( has_action('pll_translate_media', [ $polylangPro, 'pll_translate_media' ]) ); } + public function testShouldCountHooks() { + $polylangPro = new PolylangPro(); + + Functions\expect('add_action')->times(1); + Functions\expect('add_filter')->times(0); + + $polylangPro->module_init([]); + } + public function testShouldHookToTranslatedMedia() { $polylangPro = new PolylangPro(); diff --git a/vendor/bin/.phpunit.result.cache b/vendor/bin/.phpunit.result.cache index 4736eb3..8673b30 100644 --- a/vendor/bin/.phpunit.result.cache +++ b/vendor/bin/.phpunit.result.cache @@ -1 +1 @@ -{"version":1,"defects":{"WPSL\\PolylangPro\\ClassPolylangProTest::testShouldHookToTranslatedMedia":3},"times":{"WPSL\\PolylangPro\\ClassPolylangProTest::testShouldInitHooks":0.071,"WPSL\\PolylangPro\\ClassPolylangProTest::testShouldHookToTranslatedMedia":0.003,"SLCA\\PolylangPro\\ClassPolylangProTest::testShouldInitHooks":0.074,"SLCA\\PolylangPro\\ClassPolylangProTest::testShouldHookToTranslatedMedia":0.003}} \ No newline at end of file +{"version":1,"defects":{"WPSL\\PolylangPro\\ClassPolylangProTest::testShouldHookToTranslatedMedia":3,"SLCA\\PolylangPro\\ClassPolylangProTest::testShouldCountHooks":4},"times":{"WPSL\\PolylangPro\\ClassPolylangProTest::testShouldInitHooks":0.071,"WPSL\\PolylangPro\\ClassPolylangProTest::testShouldHookToTranslatedMedia":0.003,"SLCA\\PolylangPro\\ClassPolylangProTest::testShouldInitHooks":0.073,"SLCA\\PolylangPro\\ClassPolylangProTest::testShouldHookToTranslatedMedia":0.004,"SLCA\\PolylangPro\\ClassPolylangProTest::testShouldCountHooks":0.048}} \ No newline at end of file diff --git a/vendor/composer/installed.php b/vendor/composer/installed.php index 8a56d4f..1f69e25 100644 --- a/vendor/composer/installed.php +++ b/vendor/composer/installed.php @@ -3,7 +3,7 @@ 'name' => 'udx/wp-stateless-polylang-pro-addon', 'pretty_version' => 'dev-main', 'version' => 'dev-main', - 'reference' => '3797ee5f24f994f8c5f8703fdf3060523d703aa9', + 'reference' => '27176abed5954b7f0e8c0eae629fcd88632fede0', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(), @@ -13,7 +13,7 @@ 'udx/wp-stateless-polylang-pro-addon' => array( 'pretty_version' => 'dev-main', 'version' => 'dev-main', - 'reference' => '3797ee5f24f994f8c5f8703fdf3060523d703aa9', + 'reference' => '27176abed5954b7f0e8c0eae629fcd88632fede0', 'type' => 'wordpress-plugin', 'install_path' => __DIR__ . '/../../', 'aliases' => array(),