예제 #1
0
		public void Test002_VerifyAdminLimitedAccess()
		{
			Trace.WriteLine(BasePage.RunningTestKeyWord + "'Verify Admin limited access to Extensions'");

			AdminExtensionsPage adminExtensionsPage = new AdminExtensionsPage(_driver);
			adminExtensionsPage.OpenUsingButtons(_baseUrl);

			Assert.That(adminExtensionsPage.FindElements(By.XPath(AdminExtensionsPage.ButtonsList)).Count, Is.EqualTo(0),
				 "The number of available Action buttons is not correct");
		}
예제 #2
0
		public void Test006_InstallAdminExtension()
		{
			Trace.WriteLine(BasePage.RunningTestKeyWord + "'Install an Admin Extension'");

			AdminExtensionsPage adminExtensionsPage = new AdminExtensionsPage(_driver);
			adminExtensionsPage.OpenUsingButtons(_baseUrl);

			int itemNumber = adminExtensionsPage.FindElements(By.XPath(HostExtensionsPage.ModulesExtensionsList)).Count;

			adminExtensionsPage.InstallExtension(_adminFileToUpload);

			adminExtensionsPage.OpenUsingButtons(_baseUrl);
			adminExtensionsPage.AccordionOpen(By.XPath(AdminExtensionsPage.ModulesAccordion));

			Trace.WriteLine(BasePage.TraceLevelPage + "ASSERT the number of elements in the list increased by 1");
			Assert.That(adminExtensionsPage.FindElements(By.XPath(HostExtensionsPage.ModulesExtensionsList)).Count, Is.EqualTo(itemNumber + 1),
						"The Extension is not added correctly");

			Trace.WriteLine(BasePage.TraceLevelPage + "ASSERT the Extension name is present in the list");
			Assert.IsTrue(adminExtensionsPage.ElementPresent(By.XPath("//tr[td/span[text() = '" + _adminExtensionNameToInstall + "']]")),
						"The Extension name is not present in the list");
		}