I've a Azure Function project (created using VS 2017 15.3.4). I have added a unit test project in the same solution (4.6.1). As soon as i add reference to my Azure function project, and i try to run my simple test case i get this error "Could not load file or assembly System.Net.Http, Version=4.1.1.0" as i execute MyFunction's Run method.
Exception Image I have tried alot of approached recommended but nothing seems to work.
I have tried to add the the binding in app.config file
<dependentAssembly>
<assemblyIdentity name="System.Net.Http" publicKeyToken="b03f5f7f11d50a3a" culture="neutral"/>
<bindingRedirect oldVersion="0.0.0.0-4.1.1.0" newVersion="4.1.1.0" />
</dependentAssembly>
I have tried to add the nuget package for System.Net.http explicitly (from latest version to few version behind) but that's not helping either.
has anyone managed to find the solution for this?
Thanks Sanjay