I am trying to run some integration test on visual studio that test sending data to IoT Hub. When trying to send data using the DeviceClient.SendEventAsync()
method, the application crashes with the following exception:
{"Could not load file or assembly 'Validation, Version=2.2.0.0, Culture=neutral, PublicKeyToken=2fc06f0d701809a7' or one of its dependencies.
The system cannot find the file specified.":"Validation, Version=2.2.0.0, Culture=neutral, PublicKeyToken=2fc06f0d701809a7"}
I have also noticed the following in the app.config
file:
<?xml version="1.0" encoding="utf-8"?>
<configuration>
<runtime>
<assemblyBinding xmlns="urn:schemas-microsoft-com:asm.v1">
<dependentAssembly>
<assemblyIdentity name="Validation" publicKeyToken="2fc06f0d701809a7" culture="neutral" />
<bindingRedirect oldVersion="0.0.0.0-2.2.0.0" newVersion="2.2.0.0" />
</dependentAssembly>
</assemblyBinding>
</runtime>
</configuration>
I am using version 10.0.20 of the C# SDK My project is targeting .NET 4.5.1 The Validation package installed is version 2.2.8
Can anyone provide some pointers about what is going wrong in the use of the SDK?