api-importes test improvements #313

This commit is contained in:
vnmedeiros 2019-10-11 17:33:43 -03:00
parent cfde8abf06
commit ff8528893b
1 changed files with 2 additions and 6 deletions

View File

@ -33,12 +33,8 @@ class TAINACAN_REST_Importers_Controller extends TAINACAN_UnitApiTestCase {
public function test_update() { public function test_update() {
global $Tainacan_Importer_Handler; global $Tainacan_Importer_Handler;
$slug='csv'; $slug='csv';
if ($importer = $Tainacan_Importer_Handler->initialize_importer($slug)) { $importer = $Tainacan_Importer_Handler->initialize_importer($slug);
$response = $importer->_to_Array(); $Tainacan_Importer_Handler->save_importer_instance($importer);
$Tainacan_Importer_Handler->save_importer_instance($importer);
} else {
$this->assertFalse(true);
}
$session_id = $importer->get_id(); $session_id = $importer->get_id();
$params = json_encode([ $params = json_encode([