using Centron.BusinessLogic; using Centron.BusinessLogic.Sales.Support; using Centron.BusinessLogic.WebServices.Sales.Support; using Centron.Tests.EndToEnd.Infrastructure; using System; using Xunit; using Xunit.Abstractions; using Centron.Data.Entities.CustomerArea.Support; namespace Centron.Tests.EndToEnd.Tests.DbEntity { public class DbEntityTests : EndToEndTest { private readonly int _referenceCustomerI3D = 10000; public DbEntityTests(ITestOutputHelper testOutputHelper) : base(testOutputHelper) { } public override void Execute() { int helpdeskI3D; using (var session = new BLSession()) { var newHelpdesk = session.GetBL().GetNewTicketFromCustomer(this.GetLoggedInUser().User, this._referenceCustomerI3D); helpdeskI3D = session.GetBL().SaveHelpdesk(newHelpdesk, this.GetLoggedInUser()).Data; } using (var session = new BLSession()) { var result = session.GetBL().GetEntityById(helpdeskI3D); Assert.NotNull(result.CreatedBy); Assert.NotNull(result.CreatedDate); Assert.NotNull(result.CreatedVersion); Assert.NotNull(result.ChangedBy); Assert.NotNull(result.ChangedDate); Assert.NotNull(result.ChangedVersion); } } } }