662
社区成员




using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace SeleniumTools
{
public interface IConfig
{
/// <summary>
/// 待测Web应用起始网址
/// </summary>
/// <returns>URL</returns>
string getStartURL();
/// <summary>
/// 执行测试目标浏览器
/// </summary>
/// <returns>BrowserType枚举类型</returns>
BrowserType getTargetWebBrowser();
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace SeleniumTools
{
public class XMLConfig : IConfig
{
public string getStartURL()
{
throw new NotImplementedException();
}
public BrowserType getTargetWebBrowser()
{
throw new NotImplementedException();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
namespace SeleniumTools
{
public class FileConfig : IConfig
{
public string getStartURL()
{
throw new NotImplementedException();
}
public BrowserType getTargetWebBrowser()
{
throw new NotImplementedException();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections;
namespace SeleniumTools
{
public class TestData
{
/// <summary>
/// 根据参数名获取该参数名下有多少可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>该参数名下可用参数值个数</returns>
public int getCount(string parameterName)
{
throw new System.NotImplementedException();
}
/// <summary>
/// 根据参数名获取该参数名下第一个可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>第一个可用值,若该参数名下无可用值,则返回空字符串</returns>
public string getFirst(string parameterName)
{
throw new System.NotImplementedException();
}
/// <summary>
/// 根据参数名获取下一个可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>返回下一个可用值</returns>
public string Next(string parameterName)
{
throw new System.NotImplementedException();
}
/// <summary>
/// 根据参数名获取该参数名下所有可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>返回参数可用值List</returns>
public List getAll(string parameterName)
{
throw new System.NotImplementedException();
}
}
public interface ITestData
{
/// <summary>
/// 根据参数名获取该参数名下所有可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>返回参数可用List</returns>
List getAll(string parameterName);
/// <summary>
/// 根据参数名获取该参数名下有多少可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>该参数名下可用参数个数</returns>
int getCount(string parameterName);
/// <summary>
/// 根据参数名获取该参数名下第一个可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>第一个可用值,若该参数名下无可用值,则返回空字符串</returns>
string getFirst(string parameterName);
/// <summary>
/// 根据参数名获取下一个可用值
/// </summary>
/// <remarks>若参数名未找到则抛出ParameterNameNotFound异常</remarks>
/// <returns>返回下一个可用值</returns>
string Next(string parameterName);
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections;
namespace SeleniumTools
{
public class XMLTestData : ITestData
{
public List getAll(string parameterName)
{
throw new NotImplementedException();
}
public int getCount(string parameterName)
{
throw new NotImplementedException();
}
public string getFirst(string parameterName)
{
throw new NotImplementedException();
}
public string Next(string parameterName)
{
throw new NotImplementedException();
}
}
}
using System;
using System.Collections.Generic;
using System.Linq;
using System.Text;
using System.Collections;
namespace SeleniumTools
{
public class XMLTestData : ITestData
{
public List getAll(string parameterName)
{
throw new NotImplementedException();
}
public int getCount(string parameterName)
{
throw new NotImplementedException();
}
public string getFirst(string parameterName)
{
throw new NotImplementedException();
}
public string Next(string parameterName)
{
throw new NotImplementedException();
}
}
}