Base solution for your next web application

Activities of "BobIngham"

Where is the log file in the .Net Core/Angular project? log4net.config points to App_Data/Logs/Logs.txt but I can find no such folder or file. When I intentionally throw an error on the server the following is returned to the client.

{
    code: 0,
    message: "An internal error occurred during your request!",
    details: null,
    validationErrors: null
}

My only option seems to be to write try-catch blocks but how do I find exceptions after deployment? I have tried setting the level to ALL in log4net.config but I am still only able to capture errors through try-catch and have no log file to refer to. Help would be most appreciated.

Version 5.0.4, Asp.Net Core & Angular. I have followed the instructions for step-by-step development at <a class="postlink" href="https://aspnetzero.com/Documents/Developing-Step-By-Step-Angular">https://aspnetzero.com/Documents/Develo ... ep-Angular</a>. I have refactored over the past week and documented the procedure to work with database-first procedures and separate components for create/edit/list in accordance with company standards. Having refactored the system works perfectly. However, when I come to run tests with multi-tenancy set to true I am getting the error message "Message: Abp.AbpException : Can not set TenantId to 0 for IMustHaveTenant entities!". My test code:

[Fact]
        public async Task Should_Create_ActionType_With_Valid_Arguments()
        {
            //Act
            await _actionTypeService.CreateActionType(
                new CreateActionTypeInput
                {
                    Name = "Metrics",
                    Description = "A category for measured inputs such as weight, blood pressure, fluid intake etc."
                });

            //Assert
            UsingDbContext(
                context =>
                {
                    var metrics = context.ActionTypes.FirstOrDefault(p => p.Description == "A category for measured inputs such as weight, blood pressure, fluid intake etc.");
                    metrics.ShouldNotBe(null);
                    metrics.Name.ShouldBe("Metrics");
                });
        }

I have read carefully the post on testing ABP at <a class="postlink" href="https://www.codeproject.com/Articles/871786/Unit-testing-in-Csharp-using-xUnit-Entity-Framewor">https://www.codeproject.com/Articles/87 ... y-Framewor</a> and have also debugged the test and stepped through AppTestBase but can still not find why the test is not implementing the default TenantId (1). Help anyone?

Showing 141 to 142 of 142 entries