Example #1
0
        /// <summary>
        /// First creates an organization and then imports an organization template that contains 2 organizations of which 1 has the same organization name with the previously created organization.
        /// Check for duplicate organziation names is made during import
        /// </summary>
        public static void ImportTemplateWithAnExistingOrganization()
        {
            var organizationName = "SiEBEN";

            NewOrganizationPage.CreateOrganization().WithOrganizationName(organizationName).Create();

            if (!NewOrganizationPage.IsOrganizationSavedSuccessfully)
            {
                return;
            }
            FirstOrganization.SetFieldValue(OrganizationFields.OrganizationName, organizationName);


            ImportPage.ImportFile()
            .Containing(ImportFileType.Organizations)
            .FromPath(ImportFilePath)
            .WithFileName("Organizations16.xls")
            .CheckingForDuplicate(ImportField.OrganizationName).Submit();

            if (!ImportPage.IsImportWithDuplicatesMessageShown)
            {
                return;
            }
            SecondOrganization.SetFieldValue(OrganizationFields.OrganizationName, "SiEBEN");
            ThirdOrganization.SetFieldValue(OrganizationFields.OrganizationName, "InEdu");
        }
Example #2
0
 public static void CleanUp()
 {
     FirstOrganization.CleanUp();
     SecondOrganization.CleanUp();
     ThirdOrganization.CleanUp();
     LeftSideMenu.GoToContacts();
     VerifyThat.AreEqual(InitialOrganizationCount, OrganizationsPage.TotalOrganizationsCountByLabel,
                         $"Total organizations count is not the same as in the test initiation (Expected={InitialOrganizationCount}, Actual={OrganizationsPage.TotalOrganizationsCountByLabel}). Some organizations may have not been cleaned up at the end of test.");
 }
Example #3
0
        /// <summary>
        /// Import an organization template that contains 3 organization that have void lines in between them
        /// </summary>
        public static void ImportTemplateWithVoidLinesBetweenOrganizations()
        {
            ImportPage.ImportFile()
            .Containing(ImportFileType.Organizations)
            .FromPath(ImportFilePath)
            .WithFileName("Organizations18.xls")
            .Submit();

            if (!ImportPage.IsImportSuccessMessageShown)
            {
                return;
            }
            FirstOrganization.SetFieldValue(OrganizationFields.OrganizationName, "SiEBEN");
            SecondOrganization.SetFieldValue(OrganizationFields.OrganizationName, "InEdu");
            ThirdOrganization.SetFieldValue(OrganizationFields.OrganizationName, "Microsoft");
        }
Example #4
0
        /// <summary>
        /// Import an organization template that contains 2 organizations with the same organization name. During import, duplicate organization name checkbox is checked
        /// </summary>
        public static void ImportTemplateWithTwinOrganizations()
        {
            ImportPage.ImportFile()
            .Containing(ImportFileType.Organizations)
            .FromPath(ImportFilePath)
            .WithFileName("Organizations17.xls")
            .CheckingForDuplicate(ImportField.OrganizationName).Submit();

            if (!ImportPage.IsImportWithDuplicatesMessageShown)
            {
                return;
            }
            FirstOrganization.SetFieldValue(OrganizationFields.OrganizationName, "SiEBEN");
            SecondOrganization.SetFieldValue(OrganizationFields.OrganizationName, "InEdu");
            ThirdOrganization.SetFieldValue(OrganizationFields.OrganizationName, "SiEBEN");
        }
Example #5
0
        /// <summary>
        /// Import an organization template that contains 2 organization of whom, one has invlaid value for a combo field
        /// </summary>
        public static void ImportTemplateOrganizationWithInvalidComboValues()
        {
            ImportPage.ImportFile()
            .Containing(ImportFileType.Organizations)
            .FromPath(ImportFilePath)
            .WithFileName("Organizations19.xls")
            .Submit();

            if (!ImportPage.IsImportSuccessMessageShown)
            {
                return;
            }
            FirstOrganization.SetFieldValue(OrganizationFields.OrganizationName, "SiEBEN");
            FirstOrganization.SetFieldValue(OrganizationFields.BillingCountry, "Ελλάδα");

            SecondOrganization.SetFieldValue(OrganizationFields.OrganizationName, "InEdu");
            SecondOrganization.SetFieldValue(OrganizationFields.BillingCountry, "Greece");
        }