Add tests for `wc_site_is_https`
This commit is contained in:
parent
582133cb43
commit
1497075b9e
|
@ -97,6 +97,19 @@ class WC_Tests_Conditional_Functions extends WC_Unit_Test_Case {
|
|||
);
|
||||
}
|
||||
|
||||
/**
|
||||
* Test wc_site_is_https().
|
||||
*/
|
||||
public function test_wc_site_is_https() {
|
||||
$this->assertFalse( wc_site_is_https() );
|
||||
|
||||
add_filter( 'pre_option_home', function () {
|
||||
return 'https://example.org';
|
||||
} );
|
||||
|
||||
$this->assertTrue( wc_site_is_https() );
|
||||
}
|
||||
|
||||
/**
|
||||
* Test wc_is_valid_url().
|
||||
*
|
||||
|
|
Loading…
Reference in New Issue