Awesome Open Source
Awesome Open Source

Protractor for .NET Build Status

The .NET port of Protractor, an end to end test framework for Angular applications.

Protractor for .NET is built on top of Selenium WebDriver C# binding.

Changelog

Get it from NuGet!

PM> Install-Package Protractor

Supports Microsoft .NET Framework 4.5 and .NET Standard 2.0.

Write tests!

[Test]
public void ShouldGreetUsingBinding()
{
    // Instantiate a classic Selenium WebDriver
    var driver = new ChromeDriver();
    // Configure timeouts (important since Protractor uses asynchronous client side scripts)
    driver.Manage().Timeouts().AsynchronousJavaScript = TimeSpan.FromSeconds(5);

    using (var ngDriver = new NgWebDriver(driver))
    {
        ngDriver.Url = "http://www.angularjs.org";
        ngDriver.FindElement(NgBy.Model("yourName")).SendKeys("Julie");
        Assert.AreEqual("Hello Julie!", ngDriver.FindElement(NgBy.Binding("yourName")).Text);
    }
}

Getting Help

Please ask usage and debugging questions on StackOverflow (use the "protractor-net" tag)

When to NOT use?

When you can use the original Protractor framework :)


Get A Weekly Email With Trending Projects For These Topics
No Spam. Unsubscribe easily at any time.
c-sharp (11,550
angular (1,237
dotnet (829
e2e-tests (34
protractor (23

Find Open Source By Browsing 7,000 Topics Across 59 Categories