/// <summary> /// Build a suite of tests from a provided assembly /// </summary> /// <param name="assembly">The assembly from which tests are to be built</param> /// <param name="options">A dictionary of options to use in building the suite</param> /// <returns> /// A TestSuite containing the tests found in the assembly /// </returns> public ITest Build(Assembly assembly, IDictionary options) { this.assembly = assembly; IList fixtureNames = options["LOAD"] as IList; IList fixtures = GetFixtures(assembly, fixtureNames); #if NETCF || SILVERLIGHT AssemblyName assemblyName = AssemblyHelper.GetAssemblyName(assembly); return(BuildTestAssembly(assemblyName.Name, fixtures)); #else string assemblyPath = AssemblyHelper.GetAssemblyPath(assembly); return(BuildTestAssembly(assemblyPath, fixtures)); #endif }
/// <summary> /// Build a suite of tests from a provided assembly /// </summary> /// <param name="assembly">The assembly from which tests are to be built</param> /// <param name="options">A dictionary of options to use in building the suite</param> /// <returns> /// A TestSuite containing the tests found in the assembly /// </returns> public TestSuite Build(Assembly assembly, IDictionary options) { this.assembly = assembly; IList fixtureNames = options["LOAD"] as IList; IList fixtures = GetFixtures(assembly, fixtureNames); if (fixtures.Count > 0) { AssemblyName assemblyName = AssemblyHelper.GetAssemblyName(assembly); return(BuildTestAssembly(assemblyName.Name, fixtures)); } return(null); }
/// <summary> /// Build a suite of tests from a provided assembly /// </summary> /// <param name="assembly">The assembly from which tests are to be built</param> /// <param name="options">A dictionary of options to use in building the suite</param> /// <returns> /// A TestSuite containing the tests found in the assembly /// </returns> public TestSuite Build(Assembly assembly, IDictionary options) { this.assembly = assembly; IList fixtureNames = options["LOAD"] as IList; IList fixtures = GetFixtures(assembly, fixtureNames); if (fixtures.Count > 0) { #if NETCF || SILVERLIGHT || PORTABLE AssemblyName assemblyName = AssemblyHelper.GetAssemblyName(assembly); return(BuildTestAssembly(assemblyName.Name, fixtures)); #else string assemblyPath = AssemblyHelper.GetAssemblyPath(assembly); return(BuildTestAssembly(assemblyPath, fixtures)); #endif } return(null); }
public void GetNameForAssembly() { var assemblyName = AssemblyHelper.GetAssemblyName(this.GetType().GetTypeInfo().Assembly); Assert.That(assemblyName.Name, Is.EqualTo(THIS_ASSEMBLY_NAME).IgnoreCase); }