public static function test_deleting_only_removes_one_server() { ServerAdminScripts_MySQLDumpsDownloadingHelper::delete_all_remote_servers(); $server_to_stay = 'to-stay.com'; ServerAdminScripts_MySQLDumpsDownloadingHelper::add_new_remote_server($server_to_stay); $server_to_be_deleted = 'to-be-deleted.com'; ServerAdminScripts_MySQLDumpsDownloadingHelper::add_new_remote_server($server_to_be_deleted); ServerAdminScripts_MySQLDumpsDownloadingHelper::delete_remote_server($server_to_be_deleted); $remote_servers = ServerAdminScripts_MySQLDumpsDownloadingHelper::get_remote_servers(); if (count($remote_servers) != 1) { return FALSE; } if ($remote_servers[0] != $server_to_stay) { return FALSE; } return TRUE; }
public function do_actions() { ServerAdminScripts_MySQLDumpsDownloadingHelper::add_new_remote_server($this->get_remote_server()); }