Base solution for your next web application
Starts in:
01 DAYS
01 HRS
01 MIN
01 SEC
Open Closed

Test method error on V 1.7.1.1 - LanguageAppService_Tests.cs #667


User avatar
0
sampath created

Hi, There is an error on existing test method 'LanguageAppService_Tests.cs'.Please see that.Thanks.

Note : App version : 1.7.1.1

Test Name:	Joshi.IP.Tests.Localization.LanguageAppService_Tests.Create_Language
Test FullName:	Joshi.IP.Tests.Localization.LanguageAppService_Tests.Create_Language
Test Source:	\SPA\island\Tests\Joshi.IP.Tests\Localization\LanguageAppService_Tests.cs 

Result Message:	System.Data.Entity.Validation.DbEntityValidationException : Validation failed for one or more entities. See 'EntityValidationErrors' property for more details.
Result StackTrace:	
at System.Data.Entity.Internal.InternalContext.SaveChangesAsync(CancellationToken cancellationToken)
   at System.Data.Entity.Internal.LazyInternalContext.SaveChangesAsync(CancellationToken cancellationToken)
   at System.Data.Entity.DbContext.SaveChangesAsync(CancellationToken cancellationToken)
   at Abp.EntityFramework.AbpDbContext.<>n__FabricatedMethod2(CancellationToken )
   at Abp.EntityFramework.AbpDbContext.<SaveChangesAsync>d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter`1.GetResult()
   at Abp.EntityFramework.Uow.EfUnitOfWork.&lt;SaveChangesInDbContextAsync&gt;d__9.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Abp.EntityFramework.Uow.EfUnitOfWork.&lt;SaveChangesAsync&gt;d__1.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Abp.Localization.ApplicationLanguageManager.&lt;AddAsync&gt;d__6.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Joshi.IP.Localization.LanguageAppService.&lt;CreateLanguageAsync&gt;d__31.MoveNext() in d:\Freelance Work\Nipun-SPA\SPA\island\Joshi.IP.Application\Localization\LanguageAppService.cs:line 197
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Joshi.IP.Localization.LanguageAppService.&lt;CreateOrUpdateLanguage&gt;d__16.MoveNext() in d:\Freelance Work\Nipun-SPA\SPA\island\Joshi.IP.Application\Localization\LanguageAppService.cs:line 89
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Abp.Threading.InternalAsyncHelper.&lt;AwaitTaskWithPostActionAndFinally&gt;d__4.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Abp.Threading.InternalAsyncHelper.&lt;AwaitTaskWithFinally&gt;d__0.MoveNext()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
   at Joshi.IP.Tests.Localization.LanguageAppService_Tests.&lt;Create_Language&gt;d__d.MoveNext() in d:\Freelance Work\Nipun-SPA\SPA\island\Tests\Joshi.IP.Tests\Localization\LanguageAppService_Tests.cs:line 55
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()
--- End of stack trace from previous location where exception was thrown ---
   at System.Runtime.CompilerServices.TaskAwaiter.ThrowForNonSuccess(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.HandleNonSuccessAndDebuggerNotification(Task task)
   at System.Runtime.CompilerServices.TaskAwaiter.GetResult()

2 Answer(s)
  • User Avatar
    0
    hikalkan created
    Support Team

    Hi,

    Can you add a breakpoint (or try/catch) to see what is validation errors?

  • User Avatar
    0
    sampath created

    Aha.. Now it is working : :o OK I'll let you know if it'll not work again.Thanks.