Azure / Azure/azure-functions-host
IntegrationTests in Azure functions projects
- Dominant language
- C#
- Stars
- 2k
- Forks
- 482
- Avg merge
- 2d 12h
- Merged PRs (30d)
- 38
Description
Hi folks,
I've created an integration test project in order to test my azure functions. I'm using Microsoft.Azure.WebJobs.Script.WebHost package with version 2.0.12303. When I try to run my tests I've received this annoying error:

As you can see in the error it's related with the workers folder that doesn't exists when you install this NuGet package:
C:\Users\lruiz\.nuget\packages\microsoft.azure.webjobs.script\2.0.12303\lib\netstandard2.0

If I create this folder my tests passed:


I think is related with this line of code:
https://github.com/Azure/azure-functions-host/blob/acca4b6f6a800218876c4c7692189268ca161987/src/WebJobs.Script/Rpc/Configuration/WorkerConfigFactory.cs#L91
One thing is to check if this folder exists and not enumerate workers directory but I don't know if there are some side effects if this folder doesn't exist. It's very annoying because if another developer pulls the solution and try to run the tests will fails and I have to think if I have to create this folder manually or add some bootstrap to my tests that will make them tightly couple to this path, that's definitively is not a good solution in my opinion.
Regards!
Contributor guide
Research direction
Start with WorkerConfigFactory.cs at the linked line and reproduce the failure from an integration test project using Microsoft.Azure.WebJobs.Script.WebHost 2.0.12303. Check how the missing workers folder is enumerated and whether the host handles its absence; done means the tests run for a freshly pulled solution without manually creating that folder.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- azure, csharp
- Domain
- backend, cloud
- Issue type
- Bug
- Difficulty
- 3/5
- Estimated time
- 1-2 days
- Activity status
- Stale
- Clarity
- Mostly clear
- Newbie friendliness
- 35/100