-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathCheckBoxs
More file actions
30 lines (24 loc) · 748 Bytes
/
CheckBoxs
File metadata and controls
30 lines (24 loc) · 748 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
using OpenQA.Selenium;
using OpenQA.Selenium.Chrome;
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Threading.Tasks;
namespace Ecommerce_Project.SeleniumBasics
{
public class CheckBox
{
[Test]
public void SelectCheckBox()
{
IWebDriver driver = new ChromeDriver();
driver.Url = "https://rahulshettyacademy.com/AutomationPractice/";
IList<IWebElement> list = driver.FindElements(By.XPath("//input[@id='checkBoxOption1'] | //input[@id = 'checkBoxOption3']"));
foreach(IWebElement element in list)
{
element.Click();
}
}
}
}