-
Notifications
You must be signed in to change notification settings - Fork 33
testing a dotnet core class library with Specflow #46
Comments
Hi Jim! I had exactly the same problems: “.feature.cs” gets generated with TechTalk references or I get “incompatible .NET versions” error. I ended up moving all of the logic out into a separate .NETStandard 1.4 class library, referenced it by original .NETCoreApp 1.1 project and had .NET 4.6.1 SpecFlow Test project testing just the business logic in 1.4 class library the “old” way. |
As @erik-lundgren mentioned, it is a case of SpecFlow still being stuck on full framework (see #39). @igor-1024's suggestion is the best workaround for now. |
trying to understang @igor-1024 's approach. How exactly do you refrence .NET core projects from NET4.6? I tried but it's not doable. |
@tomitrescak by default, your class libraries target There is a downside to doing this however - the platforms implement Unfortunately, if you want SpecFlow to be involved, there's no real way around this right now. Ideally, your test project would multi-target both TL;DR: Try targeting your class library at |
I've been trying to understand what this means for a couple of days now. My understanding (probably totally wrong) was that i could use VS2017 to develop a DOTNET CORE class library and then test it using another DOTNET CORE Test Project, using the SpecFlow.NetCore NuGet package (and modifications to the app.config).
The behaviour appears conflicting.
The .feature.cs gets generated but the Techtalk.Specflow library is missing.
If I include SpecFlow 2.1.0 the build fails with incompatible .net versions.
Am I simply trying to use this in an impossible way or is there a workaround.
We use Specflow universally and a attempting to start a DOTNET CORE project right now and failing miserable.
Thnaks
The text was updated successfully, but these errors were encountered: