SpecFlowOSS / SpecFlow.Actions

BSD 3-Clause "New" or "Revised" License
57 stars 53 forks source link

SpecFlow.Actions.Playwright v0.1.281: [GenerateFeatureFileCodeBehindTask] SpecFlow.Actions.Configuration.SpecFlowPlugin #76

Closed LiamCottrell closed 2 years ago

LiamCottrell commented 2 years ago

Hello! Attempting to make use of SpecFlow.Actions.Playwright and having issues with version 0.1.281. Building the project using Rider / Dotnet Build to attempt to build my project and getting the following error

The "GenerateFeatureFileCodeBehindTask" task failed unexpectedly.
System.IO.FileNotFoundException: Could not load file or assembly 'SpecFlow.Actions.Configuration.SpecFlowPlugin, Version=0.1.0.0, Culture=neutral, PublicKeyToken=null'. The system cannot find the file specified.
File name: 'SpecFlow.Actions.Configuration.SpecFlowPlugin, Version=0.1.0.0, Culture=neutral, PublicKeyToken=null'
   at SpecFlow.Actions.Configuration.Generation.TargetsGeneratorPlugin.GeneratorPluginEvents_CustomizeDependencies(Object sender, CustomizeDependenciesEventArgs e)
   at TechTalk.SpecFlow.Generator.Plugins.GeneratorPluginEvents.RaiseCustomizeDependencies(ObjectContainer container, SpecFlowProjectConfiguration specFlowProjectConfiguration)
   at TechTalk.SpecFlow.Generator.GeneratorContainerBuilder.CreateContainer(SpecFlowConfigurationHolder configurationHolder, ProjectSettings projectSettings, IEnumerable`1 generatorPluginInfos, IObjectContainer parentObjectContainer)
   at SpecFlow.Tools.MsBuild.Generation.WrappedGeneratorContainerBuilder.BuildGeneratorContainer(SpecFlowConfigurationHolder specFlowConfigurationHolder, ProjectSettings projectSettings, IReadOnlyCollection`1 generatorPluginInfos, IObjectContainer rootObjectContainer)
   at SpecFlow.Tools.MsBuild.Generation.GenerateFeatureFileCodeBehindTaskExecutor.Execute()
   at SpecFlow.Tools.MsBuild.Generation.GenerateFeatureFileCodeBehindTask.Execute()
   at Microsoft.Build.BackEnd.TaskExecutionHost.Microsoft.Build.BackEnd.ITaskExecutionHost.Execute()
   at Microsoft.Build.BackEnd.TaskBuilder.ExecuteInstantiatedTask(ITaskExecutionHost taskExecutionHost, TaskLoggingContext taskLoggingContext, TaskHost taskHost, ItemBucket bucket, TaskExecutionMode howToExecuteTask)

Feel this is related to the issues raised #72 , but do not feel the issues are resolved as assumed. Building project using Visual Studio 2022 doesn't seem to present any build errors.

LiamCottrell commented 2 years ago

I have now seen the following thread discussing issues others are having, Took the liberty to clone and attempt to make use of the following example project stated here: https://github.com/SpecFlowOSS/SpecFlow.Actions/issues/71#issuecomment-1062706967

This project still has the same issues and output as above with the GenerateFeatureFileCodeBehindTask being failed on v0.1.281

Once again, the issue is only present when attempting dotnet build or use of any IDE other than VisualStudio.

SabotageAndi commented 2 years ago

Ah, this happens in dotnet build. Before fixing it for #71, it also happened in Visual Studio. I will have a look at it.

SabotageAndi commented 2 years ago

This is fixed now