-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #4 from umbraco/hotfix/13_you-must-initialize-tran…
…saction-exception Redirect buyer to error url instead of continue url when Mollie payment status is failed
- Loading branch information
Showing
9 changed files
with
141 additions
and
52 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
26 changes: 26 additions & 0 deletions
26
...merce.PaymentProviders.Mollie.Tests/Umbraco.Commerce.PaymentProviders.Mollie.Tests.csproj
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,26 @@ | ||
<Project Sdk="Microsoft.NET.Sdk"> | ||
|
||
<PropertyGroup> | ||
<TargetFramework>net8.0</TargetFramework> | ||
<ImplicitUsings>enable</ImplicitUsings> | ||
<Nullable>enable</Nullable> | ||
|
||
<IsPackable>false</IsPackable> | ||
<IsTestProject>true</IsTestProject> | ||
<ManagePackageVersionsCentrally>false</ManagePackageVersionsCentrally> | ||
<NoWarn>CA1707</NoWarn> | ||
</PropertyGroup> | ||
|
||
<ItemGroup> | ||
<PackageReference Include="coverlet.collector" Version="6.0.0" /> | ||
<PackageReference Include="Microsoft.NET.Test.Sdk" Version="17.8.0" /> | ||
<PackageReference Include="Moq" Version="4.20.72" /> | ||
<PackageReference Include="NUnit" Version="4.2.2" /> | ||
<PackageReference Include="NUnit3TestAdapter" Version="4.6.0" /> | ||
</ItemGroup> | ||
|
||
<ItemGroup> | ||
<ProjectReference Include="..\src\Umbraco.Commerce.PaymentProviders.Mollie\Umbraco.Commerce.PaymentProviders.Mollie.csproj" /> | ||
</ItemGroup> | ||
|
||
</Project> |
19 changes: 19 additions & 0 deletions
19
Umbraco.Commerce.PaymentProviders.Mollie.Tests/UriQueryHelperTests.cs
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,19 @@ | ||
using Microsoft.AspNetCore.WebUtilities; | ||
using NUnit.Framework; | ||
|
||
namespace Umbraco.Commerce.PaymentProviders.Mollie.Tests | ||
{ | ||
public class UriQueryHelperTests | ||
{ | ||
[TestCase("https://umbraco.com", "https://umbraco.com?addedparam=true", "adding a query parameter to an absolute url with no query parameters case failed")] | ||
[TestCase("https://umbraco.com?param1=a¶m2=b", "https://umbraco.com?param1=a¶m2=b&addedparam=true", "adding a query parameter to an absolute url with query parameters case failed")] | ||
[TestCase("/relative-url", "/relative-url?addedparam=true", "adding a query parameter to a relative url with no query parameters case failed")] | ||
[TestCase("/relative-url?param1=a¶m2=b", "/relative-url?param1=a¶m2=b&addedparam=true", "adding a query parameter to a relative url case failed")] | ||
public void AddQueryParameter_Should_Run_Successfully(string input, string expect, string errorMessage) | ||
{ | ||
string actualOutput = QueryHelpers.AddQueryString(input, "addedparam", "true"); | ||
|
||
Assert.That(actualOutput, Is.EqualTo(expect), errorMessage); | ||
} | ||
} | ||
} |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.