Fix server file upload test

This commit is contained in:
Gerhard Potgieter 2018-05-25 13:00:59 +02:00
parent 5b1180d81a
commit 2f9c9e4954
1 changed files with 2 additions and 2 deletions

View File

@ -109,9 +109,9 @@ class WC_Tests_Product_CSV_Importer extends WC_Unit_Test_Case {
*/ */
public function test_server_file() { public function test_server_file() {
copy( $this->csv_file, ABSPATH . '/sample.csv' ); copy( $this->csv_file, ABSPATH . '/sample.csv' );
$_POST['file_url'] = ABSPATH . '/sample.csv'; $_POST['file_url'] = 'sample.csv';
$import_controller = new WC_Product_CSV_Importer_Controller(); $import_controller = new WC_Product_CSV_Importer_Controller();
$this->assertEquals( ABSPATH . '/sample.csv', $import_controller->handle_upload() ); $this->assertEquals( ABSPATH . 'sample.csv', $import_controller->handle_upload() );
} }
/** /**