/// <summary> /// Initializes a new instance of the <see cref="ConcordionTest"/> class. /// </summary> /// <param name="name">The name.</param> /// <param name="codeElement">The code element.</param> /// <param name="typeInfo">The type info.</param> /// <param name="resource">The resource.</param> /// <param name="fixtureType">The fixture type.</param> public ConcordionTest(string name, ICodeElementInfo codeElement, ConcordionTypeInfoAdapter typeInfo, Resource resource, Type fixtureType) : base(name, codeElement) { if (typeInfo == null) throw new ArgumentNullException(@"typeInfo"); this.TypeInfo = typeInfo; this.Resource = resource; this.FixtureType = fixtureType; }
/// <summary> /// Initializes a new instance of the <see cref="ConcordionTest"/> class. /// </summary> /// <param name="name">The name.</param> /// <param name="codeElement">The code element.</param> /// <param name="typeInfo">The type info.</param> /// <param name="resource">The resource.</param> /// <param name="fixtureType">The fixture type.</param> public ConcordionTest(string name, ICodeElementInfo codeElement, ConcordionTypeInfoAdapter typeInfo, Resource resource, Type fixtureType) : base(name, codeElement) { if (typeInfo == null) { throw new ArgumentNullException(@"typeInfo"); } this.TypeInfo = typeInfo; this.Resource = resource; this.FixtureType = fixtureType; }
private ConcordionTest CreateTypeTest(ConcordionTypeInfoAdapter typeInfo) { var fixtureType = CreateFixtureType(typeInfo.Target); var resource = CreateResource(ExtrapolateResourcePath(fixtureType)); var typeTest = new ConcordionTest(typeInfo.Target.FullName, typeInfo.Target, typeInfo, resource, fixtureType); typeTest.Source = new EmbeddedResourceSource(fixtureType.Assembly); typeTest.Target = new FileTarget(_baseOutputDirectory.FullName); typeTest.Kind = TestKinds.Fixture; typeTest.IsTestCase = true; // Add XML documentation. var xmlDocumentation = typeInfo.Target.GetXmlDocumentation(); if (xmlDocumentation != null) { typeTest.Metadata.SetValue(MetadataKeys.XmlDocumentation, xmlDocumentation); } return(typeTest); }
private ConcordionTest CreateTypeTest(ConcordionTypeInfoAdapter typeInfo) { var fixtureType = CreateFixtureType(typeInfo.Target); var resource = CreateResource(ExtrapolateResourcePath(fixtureType)); var typeTest = new ConcordionTest(typeInfo.Target.FullName, typeInfo.Target, typeInfo, resource, fixtureType); typeTest.Source = new EmbeddedResourceSource(fixtureType.Assembly); typeTest.Target = new FileTarget(_baseOutputDirectory.FullName); typeTest.Kind = TestKinds.Fixture; typeTest.IsTestCase = true; // Add XML documentation. var xmlDocumentation = typeInfo.Target.GetXmlDocumentation(); if (xmlDocumentation != null) typeTest.Metadata.SetValue(MetadataKeys.XmlDocumentation, xmlDocumentation); return typeTest; }
public ConcordionTest(string name, ICodeElementInfo codeElement, ConcordionTypeInfoAdapter typeInfo, Resource resource, Type fixtureType, ConcordionTestGroupTracker testGroupTracker) : this(name, codeElement, typeInfo, resource, fixtureType) { this.TestGroupTracker = testGroupTracker; }