-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Tests #78 - add tests for some of problems noted
- Loading branch information
1 parent
a62ee31
commit fabba06
Showing
1 changed file
with
36 additions
and
0 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,36 @@ | ||
<?php | ||
|
||
/** | ||
* @copyright Bobbing Wide 2018, 2019 | ||
* @package oik-bwtrace | ||
* | ||
* Tests for logic in oik-bwtrace.php | ||
*/ | ||
class Tests_issue_78 extends BW_UnitTestCase { | ||
|
||
public $bw_trace_on = null; | ||
|
||
function setUp() : void { | ||
parent::setUp(); | ||
oik_require( "includes/oik-actions.php", "oik-bwtrace" ); | ||
} | ||
|
||
function test_bw_trace_ok_to_echo_woocommerce_product_export() { | ||
$_REQUEST['action'] = 'download_product_csv'; | ||
$ok = bw_trace_ok_to_echo(); | ||
$this->assertFalse( $ok ); | ||
} | ||
|
||
function test_bw_trace_ok_to_echo_block_data_export() { | ||
$_REQUEST['block_data_export'] = 'Advanced Gutenberg Contact Form sets this'; | ||
$ok = bw_trace_ok_to_echo(); | ||
$this->assertFalse( $ok ); | ||
} | ||
|
||
function test_bw_trace_ok_to_echo_edd_api() { | ||
$_REQUEST['edd-api'] = 'Easy Digital Downloads API sets this'; | ||
$ok = bw_trace_ok_to_echo(); | ||
$this->assertFalse( $ok ); | ||
} | ||
|
||
} |