/*
 * Cloudera Manager API
 * <h1>Cloudera Manager API v57</h1>       <p>Introduced in Cloudera Manager 7.13.1</p>       <p><a href=\"http://www.cloudera.com/documentation.html\">Cloudera Product Documentation</a></p>
 *
 * OpenAPI spec version: 7.13.1
 * 
 *
 * NOTE: This class is auto generated by the swagger code generator program.
 * https://github.com/swagger-api/swagger-codegen.git
 * Do not edit the class manually.
 */

package com.cloudera.api.swagger;

import com.cloudera.api.swagger.model.ApiCommand;
import com.cloudera.api.swagger.model.ApiCommandList;
import com.cloudera.api.swagger.model.ApiRoleTypeList;
import com.cloudera.api.swagger.model.ApiService;
import com.cloudera.api.swagger.model.ApiServiceConfig;
import org.junit.Test;
import org.junit.Ignore;


import java.util.ArrayList;
import java.util.HashMap;
import java.util.List;
import java.util.Map;


/**
 * API tests for MgmtServiceResourceApi
 */
@Ignore
public class MgmtServiceResourceApiTest {

    private final MgmtServiceResourceApi api = new MgmtServiceResourceApi();

    /**
     * Automatically assign roles to hosts and create the roles for the Cloudera Management Service.
     *
     * Automatically assign roles to hosts and create the roles for the Cloudera Management Service. &lt;p&gt; Assignments are done based on number of hosts in the deployment and hardware specifications. If no hosts are part of the deployment, an exception will be thrown preventing any role assignments. Existing roles will be taken into account and their assignments will be not be modified. The deployment should not have any clusters when calling this endpoint. If it does, an exception will be thrown preventing any role assignments. &lt;p&gt; Available since API v6.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void autoAssignRolesTest() throws Exception {
        api.autoAssignRoles();

        // TODO: test validations
    }
    /**
     * Automatically configures roles of the Cloudera Management Service.
     *
     * Automatically configures roles of the Cloudera Management Service. &lt;p&gt; Overwrites some existing configurations. Only default role config groups must exist before calling this endpoint. Other role config groups must not exist. If they do, an exception will be thrown preventing any configuration. Ignores any clusters (and their services and roles) colocated with the Cloudera Management Service. To avoid over-committing the heap on hosts, place the Cloudera Management Service roles on machines not used by any of the clusters. &lt;p&gt; Available since API v6.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void autoConfigureTest() throws Exception {
        api.autoConfigure();

        // TODO: test validations
    }
    /**
     * Delete the Cloudera Management Services.
     *
     * Delete the Cloudera Management Services. &lt;p&gt; This method will fail if a CMS instance doesn&#x27;t already exist.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void deleteCMSTest() throws Exception {
        ApiService response = api.deleteCMS();

        // TODO: test validations
    }
    /**
     * Put Cloudera Management Service into maintenance mode.
     *
     * Put Cloudera Management Service into maintenance mode. This is a synchronous command. The result is known immediately upon return.  &lt;p&gt;Available since API v18.&lt;/p&gt;
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void enterMaintenanceModeTest() throws Exception {
        ApiCommand response = api.enterMaintenanceMode();

        // TODO: test validations
    }
    /**
     * Take Cloudera Management Service out of maintenance mode.
     *
     * Take Cloudera Management Service out of maintenance mode. This is a synchronous command. The result is known immediately upon return.  &lt;p&gt;Available since API v18.&lt;/p&gt;
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void exitMaintenanceModeTest() throws Exception {
        ApiCommand response = api.exitMaintenanceMode();

        // TODO: test validations
    }
    /**
     * List active Cloudera Management Services commands.
     *
     * List active Cloudera Management Services commands.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void listActiveCommandsTest() throws Exception {
        String view = null;
        ApiCommandList response = api.listActiveCommands(view);

        // TODO: test validations
    }
    /**
     * List the supported role types for the Cloudera Management Services.
     *
     * List the supported role types for the Cloudera Management Services.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void listRoleTypesTest() throws Exception {
        ApiRoleTypeList response = api.listRoleTypes();

        // TODO: test validations
    }
    /**
     * Retrieve information about the Cloudera Management Services.
     *
     * Retrieve information about the Cloudera Management Services.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void readServiceTest() throws Exception {
        String view = null;
        ApiService response = api.readService(view);

        // TODO: test validations
    }
    /**
     * Retrieve the configuration of the Cloudera Management Services.
     *
     * Retrieve the configuration of the Cloudera Management Services.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void readServiceConfigTest() throws Exception {
        String view = null;
        ApiServiceConfig response = api.readServiceConfig(view);

        // TODO: test validations
    }
    /**
     * Restart the Cloudera Management Services.
     *
     * Restart the Cloudera Management Services.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void restartCommandTest() throws Exception {
        ApiCommand response = api.restartCommand();

        // TODO: test validations
    }
    /**
     * Setup the Cloudera Management Services.
     *
     * Setup the Cloudera Management Services. &lt;p&gt; Configure the CMS instance and create all the management roles. The provided configuration data can be used to set up host mappings for each role, and required configuration such as database connection information for specific roles. &lt;p&gt; Regardless of the list of roles provided in the input data, all management roles are created by this call. The input is used to override any default settings for the specific roles. &lt;p&gt; This method needs a valid CM license to be installed beforehand. &lt;p&gt; This method does not start any services or roles. &lt;p&gt; This method will fail if a CMS instance already exists. &lt;p&gt; Available role types: &lt;ul&gt; &lt;li&gt;SERVICEMONITOR&lt;/li&gt; &lt;li&gt;ACTIVITYMONITOR&lt;/li&gt; &lt;li&gt;HOSTMONITOR&lt;/li&gt; &lt;li&gt;REPORTSMANAGER&lt;/li&gt; &lt;li&gt;EVENTSERVER&lt;/li&gt; &lt;li&gt;ALERTPUBLISHER&lt;/li&gt; &lt;li&gt;NAVIGATOR&lt;/li&gt; &lt;li&gt;NAVIGATORMETASERVER&lt;/li&gt; &lt;/ul&gt;  &lt;p/&gt; REPORTSMANAGER, NAVIGATOR and NAVIGATORMETASERVER are only available with Cloudera Manager Enterprise Edition.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void setupCMSTest() throws Exception {
        ApiService body = null;
        ApiService response = api.setupCMS(body);

        // TODO: test validations
    }
    /**
     * Start the Cloudera Management Services.
     *
     * Start the Cloudera Management Services.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void startCommandTest() throws Exception {
        ApiCommand response = api.startCommand();

        // TODO: test validations
    }
    /**
     * Stop the Cloudera Management Services.
     *
     * Stop the Cloudera Management Services.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void stopCommandTest() throws Exception {
        ApiCommand response = api.stopCommand();

        // TODO: test validations
    }
    /**
     * Update the Cloudera Management Services configuration.
     *
     * Update the Cloudera Management Services configuration. &lt;p&gt; If a value is set in the given configuration, it will be added to the service&#x27;s configuration, replacing any existing entries. If a value is unset (its value is null), the existing configuration for the attribute will be erased, if any. &lt;p&gt; Attributes that are not listed in the input will maintain their current values in the configuration.
     *
     * @throws Exception
     *          if the Api call fails
     */
    @Test
    public void updateServiceConfigTest() throws Exception {
        ApiServiceConfig body = null;
        String message = null;
        ApiServiceConfig response = api.updateServiceConfig(body, message);

        // TODO: test validations
    }
}
