Skip to content

Instantly share code, notes, and snippets.

@testingbot
Created April 22, 2012 10:07
Show Gist options
  • Save testingbot/2463226 to your computer and use it in GitHub Desktop.
Save testingbot/2463226 to your computer and use it in GitHub Desktop.
android c# testingbot
using NUnit.Framework;
using System;
using Selenium;
using System.Web;
using System.Text;
using System.Net;
using OpenQA.Selenium;
using OpenQA.Selenium.Remote;
namespace Test
{
[TestFixture()]
public class Test
{
private IWebDriver driver;
[SetUp]
public void Init()
{
DesiredCapabilities capabillities = DesiredCapabilities.Android();
capabillities.SetCapability("api_key", "xx");
capabillities.SetCapability("api_secret", "xx");
driver = new RemoteWebDriver(
new Uri("http://hub.testingbot.com:4444/wd/hub/"), capabillities);
}
[Test]
public void TestCase()
{
driver.Navigate().GoToUrl("http://www.google.com/");
StringAssert.Contains("Google", driver.Title);
}
[TearDown]
public void Cleanup()
{
driver.Quit();
}
}
}
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment