mirror of
https://github.com/wiremock/WireMock.Net.git
synced 2026-01-11 21:10:32 +01:00
TypeLoadException when using WithHeader method. #508
Reference in New Issue
Block a user
Delete Branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Originally created by @eshref on GitHub (May 4, 2023).
Originally assigned to: @StefH on GitHub.
Hi, friends.
I am getting
error when I use below assertion code in my test which is net472 project.
I am using below versions of packages in test project.
Any help is appreciated.
@StefH commented on GitHub (May 12, 2023):
Can you please provide the full project ?
@StefH commented on GitHub (May 31, 2023):
@eshref
Can you please provide a full project with this error?
@eshref commented on GitHub (Jun 1, 2023):
Hi, @StefH. Sorry for late response.
Here is my csproj:
And this is test class:
@StefH commented on GitHub (Jun 1, 2023):
Using your slightly modified csproj and the same test file it works fine in VS2022.
@eshref commented on GitHub (Jun 1, 2023):
Why you removed FluentAssertions 6.6.0? We use this version of FA package.
@StefH commented on GitHub (Jun 1, 2023):
Ah I see. That causes probably the issue.
Version 5 and 6 from FluentAssertions are not compatible.
The only thing what can be done is that I create 2 packages for WireMock.Net.FluentAssertions, one with 5 and one with 6.
@eshref commented on GitHub (Jun 1, 2023):
Wouldn't it be better to to upgrade FA dependency and release new breaking change instead of supporting two packages?
@StefH commented on GitHub (Jun 1, 2023):
The issue is that version 6 is not supported by lower frameworks. But I can make a workaround for that I think.
@StefH commented on GitHub (Jun 1, 2023):
Can you try preview version 1.5.26-ci-17452 ?
@eshref commented on GitHub (Jun 2, 2023):
Did you push this version to nuget? I am getting below warnings after manually updating versions:
@StefH commented on GitHub (Jun 2, 2023):
It is on myget.
https://github.com/WireMock-Net/WireMock.Net/wiki/MyGet-preview-versions
@eshref commented on GitHub (Jun 2, 2023):
Added this package and run test, same problem occured.
@StefH commented on GitHub (Jun 2, 2023):
Can you try
1.5.26-ci-17457
@eshref commented on GitHub (Jun 2, 2023):
This one worked, thanks. 🙏🏼
@eshref commented on GitHub (Jun 2, 2023):
I would be glad, if you share solution :)
@StefH commented on GitHub (Jun 2, 2023):
You mean a new official NuGet ?
@eshref commented on GitHub (Jun 2, 2023):
Yes, but also I meant what changes did you do in this myget package? Only above changes (https://github.com/WireMock-Net/WireMock.Net/pull/949)
@StefH commented on GitHub (Jun 2, 2023):
That commit was actually not correct.
I did a commit op master which solved it.
@eshref commented on GitHub (Jun 2, 2023):
Thanks for your quick help.