-
Notifications
You must be signed in to change notification settings - Fork 1
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
1 parent
ba5c816
commit 18a8552
Showing
20 changed files
with
67 additions
and
63 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
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
namespace TcHaxx.Snappy.CLI; | ||
namespace TcHaxx.Snappy.CLI.CLI; | ||
|
||
internal static class Constants | ||
{ | ||
|
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
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
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 |
---|---|---|
@@ -1,4 +1,5 @@ | ||
using Serilog; | ||
using TcHaxx.Snappy.CLI.CLI; | ||
|
||
namespace TcHaxx.Snappy.CLI.Commands; | ||
|
||
|
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 |
---|---|---|
@@ -1,4 +1,5 @@ | ||
using Serilog; | ||
using TcHaxx.Snappy.CLI.CLI; | ||
using TcHaxx.Snappy.TcADS; | ||
using TcHaxx.Snappy.Verifier; | ||
|
||
|
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
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
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 |
---|---|---|
@@ -1,8 +1,5 @@ | ||
namespace TcHaxx.Snappy.Common.RPC; | ||
|
||
public class RpcMethodTransformException : Exception | ||
public class RpcMethodTransformException(string message) : Exception(message) | ||
{ | ||
public RpcMethodTransformException(string message) : base(message) | ||
{ | ||
} | ||
} |
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
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 |
---|---|---|
@@ -1,10 +1,9 @@ | ||
using TcHaxx.Snappy.Common.Verify; | ||
using TcHaxx.Snappy.Verifier.Options; | ||
|
||
namespace TcHaxx.Snappy.Verifier | ||
namespace TcHaxx.Snappy.Verifier; | ||
|
||
public interface IVerifyService : IVerifyMethod | ||
{ | ||
public interface IVerifyService : IVerifyMethod | ||
{ | ||
public IVerifierOptions Options { get; set; } | ||
} | ||
public IVerifierOptions Options { get; set; } | ||
} |
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
31 changes: 15 additions & 16 deletions
31
src/TcHaxx.Snappy.Verifier/VerificationResultExtension.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 |
---|---|---|
@@ -1,26 +1,25 @@ | ||
using System.Text.RegularExpressions; | ||
using TcHaxx.Snappy.Common.Verify; | ||
|
||
namespace TcHaxx.Snappy.Verifier | ||
namespace TcHaxx.Snappy.Verifier; | ||
|
||
internal static class VerificationResultExtension | ||
{ | ||
internal static class VerificationResultExtension | ||
internal static VerificationResult ToCompactDiff(this VerificationResult result) | ||
{ | ||
internal static VerificationResult ToCompactDiff(this VerificationResult result) | ||
var matchNew = Regex.Match(result.Diff, "^New:\n\nReceived:(?<diff>.*)(?<!\n)$", RegexOptions.Singleline | RegexOptions.Multiline | RegexOptions.CultureInvariant | RegexOptions.Compiled); | ||
if (matchNew.Success) | ||
{ | ||
var matchNew = Regex.Match(result.Diff, "^New:\n\nReceived:(?<diff>.*)(?<!\n)$", RegexOptions.Singleline | RegexOptions.Multiline | RegexOptions.CultureInvariant | RegexOptions.Compiled); | ||
if (matchNew.Success) | ||
{ | ||
result.Diff = $"New: {matchNew.Groups["diff"].Value}"; | ||
return result; | ||
} | ||
var matchCompareResult = Regex.Match(result.Diff, "^Compare Result:\n(?<diff>.*)(?<!\n)$", RegexOptions.Singleline | RegexOptions.Multiline | RegexOptions.CultureInvariant | RegexOptions.Compiled); | ||
if (matchCompareResult.Success) | ||
{ | ||
result.Diff = $"Compare Result:\n{matchCompareResult.Groups["diff"].Value}"; | ||
return result; | ||
} | ||
|
||
result.Diff = $"New: {matchNew.Groups["diff"].Value}"; | ||
return result; | ||
} | ||
var matchCompareResult = Regex.Match(result.Diff, "^Compare Result:\n(?<diff>.*)(?<!\n)$", RegexOptions.Singleline | RegexOptions.Multiline | RegexOptions.CultureInvariant | RegexOptions.Compiled); | ||
if (matchCompareResult.Success) | ||
{ | ||
result.Diff = $"Compare Result:\n{matchCompareResult.Groups["diff"].Value}"; | ||
return result; | ||
} | ||
|
||
return result; | ||
} | ||
} |
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 |
---|---|---|
@@ -1,4 +1,4 @@ | ||
namespace TcHaxx.Snappy.Tests; | ||
namespace TcHaxx.Snappy.CLI.Tests; | ||
|
||
public class UnitTest1 | ||
{ | ||
|