Sto cercando di far funzionare i test dell'unità nella mia soluzione .NET Core 1.0. Quando eseguo un test vuoto funziona perfettamente. Tuttavia, non appena cerco di creare nuova istanza ApplicationDbContext il test fallisce con la seguente eccezione:xunit e System.Interactive.Async
System.IO.FileLoadException : Could not load file or assembly 'System.Interactive.Async, Version=3.0.0.0, Culture=neutral, PublicKeyToken=94bc3704cddfc263'. The located assembly's manifest definition does not match the assembly reference. (Exception from HRESULT: 0x80131040)
Stack Trace:
at Microsoft.EntityFrameworkCore.Infrastructure.EntityFrameworkServiceCollectionExtensions.AddQuery(IServiceCollection serviceCollection)
at Microsoft.EntityFrameworkCore.Infrastructure.EntityFrameworkServiceCollectionExtensions.AddEntityFramework(IServiceCollection serviceCollection)
at Microsoft.EntityFrameworkCore.Internal.ServiceProviderCache.<>c__DisplayClass4_0.<GetOrAdd>b__1(Int64 k)
at System.Collections.Concurrent.ConcurrentDictionary`2.GetOrAdd(TKey key, Func`2 valueFactory)
at Microsoft.EntityFrameworkCore.DbContext..ctor(DbContextOptions options)
(2 more stack trace lines from my code)
Non certo perché la System.Interactive.Async è necessaria a tutti, ma ho aggiunto come la dipendenza alla mia Progetto di test Tuttavia, la DLL non sembra essere copiata nella cartella bin \ Debug \ netcoreapp1.0 su build. Se lo copio lì manualmente l'effetto è esattamente lo stesso. Qualche idea, cos'altro posso fare per farlo funzionare?
hai aggiunto questo al file json di prova "portable-net45 + win8"? –
Si prega di inviare un po 'di codice. –
Avendo lo stesso problema, ma dalla mia classe logica aziendale. Ho portable-net45 + win8 nel mio project.json frameworks imports. – James