Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Support Microsoft.AspNetCore for net 4.6.1 and up #185

Merged
merged 9 commits into from
Aug 17, 2018

Conversation

StefH
Copy link
Collaborator

@StefH StefH commented Aug 16, 2018

No description provided.

@codecov
Copy link

codecov bot commented Aug 16, 2018

Codecov Report

Merging #185 into master will increase coverage by 0.52%.
The diff coverage is 77.77%.

Impacted file tree graph

@@            Coverage Diff             @@
##           master     #185      +/-   ##
==========================================
+ Coverage   71.19%   71.72%   +0.52%     
==========================================
  Files          89       89              
  Lines        3236     3240       +4     
  Branches      425      423       -2     
==========================================
+ Hits         2304     2324      +20     
+ Misses        763      750      -13     
+ Partials      169      166       -3
Impacted Files Coverage Δ
src/WireMock.Net/Owin/WireMockMiddlewareOptions.cs 100% <ø> (ø) ⬆️
src/WireMock.Net/Owin/GlobalExceptionMiddleware.cs 64.28% <ø> (ø) ⬆️
src/WireMock.Net/Util/UrlUtils.cs 100% <ø> (ø) ⬆️
src/WireMock.Net/Owin/WireMockMiddleware.cs 69.35% <ø> (ø) ⬆️
src/WireMock.Net/Owin/OwinRequestMapper.cs 96.87% <ø> (ø) ⬆️
src/WireMock.Net/Owin/OwinResponseMapper.cs 84.61% <ø> (ø) ⬆️
src/WireMock.Net/Server/FluentMockServer.cs 44.8% <0%> (-7.59%) ⬇️
src/WireMock.Net/Owin/OwinSelfHost.cs 98.21% <100%> (+8.92%) ⬆️
src/WireMock.Net/Http/PortUtil.cs 85.71% <100%> (ø) ⬆️
...rc/WireMock.Net/Handlers/LocalFileSystemHandler.cs 80% <83.33%> (+27.36%) ⬆️
... and 10 more

Continue to review full report at Codecov.

Legend - Click here to learn more
Δ = absolute <relative> (impact), ø = not affected, ? = missing data
Powered by Codecov. Last update 01d6dce...6461f76. Read the comment docs.

@@ -39,7 +39,7 @@ public AspNetCoreSelfHost([NotNull] WireMockMiddlewareOptions options, [NotNull]

_logger = options.Logger ?? new WireMockConsoleLogger();

foreach (string uriPrefix in uriPrefixes)
foreach (string uriPrefix in uriPrefixes) // .Select(u => u.EndsWith("/") ? u : $"{u}/")) // Always append an / at the end.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the code supposed to be commented out?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes should be removed.

@@ -26,7 +27,7 @@ public OwinSelfHost([NotNull] WireMockMiddlewareOptions options, [NotNull] param

_logger = options.Logger ?? new WireMockConsoleLogger();

foreach (string uriPrefix in uriPrefixes)
foreach (string uriPrefix in uriPrefixes) // .Select(u => u.EndsWith("/") ? u : $"{u}/")) // Always append an / at the end.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Is the code supposed to be commented out?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Yes should be removed.

@@ -14,6 +14,36 @@ public class RequestWithPathTests
{
private const string ClientIp = "::1";

// [Fact] : TODO : this test fails???

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Probably remove comment and TODO?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I keep this for now as reminder,

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

But the test doesn't fail anymore right?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Somehow this test still fails. Also for netcore.
So for now i've removed the test.

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Well then the underlying problem (that WireMock.Net does not handle encoded URLs correctly) still persists :(.

@StefH StefH self-assigned this Aug 17, 2018
@StefH StefH added the feature label Aug 17, 2018
@StefH
Copy link
Collaborator Author

StefH commented Aug 17, 2018

@chrischu Thanks for your review. I've updated some code and commented on your comments. Can you please approve?

@StefH StefH merged commit b57d118 into master Aug 17, 2018
@StefH StefH deleted the stef_Microsoft.AspNetCore branch August 17, 2018 17:25
@chrischu
Copy link

Since it is already merged: Is there a plan for creating a new release with these changes?

@StefH
Copy link
Collaborator Author

StefH commented Aug 20, 2018

I'll create a new version today.

@StefH
Copy link
Collaborator Author

StefH commented Aug 20, 2018

1.0.4.11 NuGet created. Please test.
And if it still fails, please create an issue with some steps to reproduce it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

3 participants