// Tests the AddRole method and displays the list of components that are installed
 static void TestAddRole()
 {
     AddRoleSample addSample = new AddRoleSample();
     List<string> componentsToAdd = new List<string>();
     componentsToAdd.Add("Print-Services");
     componentsToAdd.Add("Print-Server");
     List<CimInstance> addRoleResult = addSample.AddRole(componentsToAdd);
     if (addRoleResult.Count > 0)
     {
         Console.WriteLine("The following components are installed:");
         ServerComponentsPrinter.DisplayResult(addRoleResult);
     }
 }
        // Tests the AddRole method and displays the list of components that are installed
        static void TestAddRole()
        {
            AddRoleSample addSample       = new AddRoleSample();
            List <string> componentsToAdd = new List <string>();

            componentsToAdd.Add("Print-Services");
            componentsToAdd.Add("Print-Server");
            List <CimInstance> addRoleResult = addSample.AddRole(componentsToAdd);

            if (addRoleResult.Count > 0)
            {
                Console.WriteLine("The following components are installed:");
                ServerComponentsPrinter.DisplayResult(addRoleResult);
            }
        }