コード例 #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 Test001_EditAdminExtension()
		{
			Trace.WriteLine(BasePage.RunningTestKeyWord + "'Edit the Admin Extension'");

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

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

			adminExtensionsPage.EditExtensionPermissions(_adminExtensionToEdit);

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

			Trace.WriteLine(BasePage.TraceLevelPage + "ASSERT the Permission is granted");
			Assert.That(adminExtensionsPage.WaitForElement(By.XPath(AdminExtensionsPage.PermissionTable + "'All Users'" + "]]/td/img")).GetAttribute("src"),
						Is.StringContaining("Grant"),
						"The Permission is not granted");
		}
コード例 #3
0
ファイル: P1HostExtensions.cs プロジェクト: rrsc/Dnn.Platform
		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");
		}