public void AsContractType_SetsContractType() { var builder = new ExportBuilder(); builder.AsContractType(typeof(IFoo)); ExportAttribute exportAtt = GetExportAttribute(builder); Assert.Equal(typeof(IFoo), exportAtt.ContractType); Assert.Null(exportAtt.ContractName); }
public void AsContractName_AndContractType_SetsContractNameAndType() { var builder = new ExportBuilder(); builder.AsContractName("hey"); builder.AsContractType(typeof(IFoo)); ExportAttribute exportAtt = GetExportAttribute(builder); Assert.AreEqual("hey", exportAtt.ContractName); Assert.AreEqual(typeof(IFoo), exportAtt.ContractType); }