public static CreateImportFromStub Create(MongoConnection mongoConnection, string urlLoginName, string name, Schedule schedule, Schedule importFromStubSchedule) { CreateImportFromStub createImportFromStub = new CreateImportFromStub() { urlLoginName = urlLoginName, ImportFromStubSchedule = importFromStubSchedule, }; Create(mongoConnection, createImportFromStub, name, schedule); return(createImportFromStub); }
public void ImportFromStubIsCreatedForCampaign() { DatabaseCreateImportFromStub databaseCreateImportFromStub = CreateDatabaseCreateImportFromStub(); CreateImportFromStub createImportFromStub = new CreateImportFromStub(Connection, databaseCreateImportFromStub); createImportFromStub.ExecuteOption(new Administration.Option.Options.OptionReport(typeof(CreateImportFromStubTest))); DatabaseWebCampaign webCampaign = DatabaseWebCampaign.ReadSingleOrDefault(Connection, _campaign.Id); List <DatabaseImportFromStub> importFromStubs = DatabaseImportFromStub.ReadByWebCampaign(Connection, webCampaign); Assert.AreEqual(1, importFromStubs.Count); }