| | | 1 | | namespace AsiBackbone.Testing.Contracts; |
| | | 2 | | |
| | | 3 | | /// <summary> |
| | | 4 | | /// Represents a reusable AsiBackbone contract-test invariant failure. |
| | | 5 | | /// </summary> |
| | | 6 | | /// <remarks> |
| | | 7 | | /// Contract helpers throw this exception instead of binding the testing package to a specific unit-test framework. |
| | | 8 | | /// xUnit, NUnit, MSTest, and custom harnesses can assert on this exception type while sharing the same invariant checks |
| | | 9 | | /// </remarks> |
| | | 10 | | public sealed class AsiBackboneContractViolationException : InvalidOperationException |
| | | 11 | | { |
| | | 12 | | /// <summary> |
| | | 13 | | /// Initializes a new instance of the <see cref="AsiBackboneContractViolationException" /> class. |
| | | 14 | | /// </summary> |
| | | 15 | | /// <param name="message">The contract failure message.</param> |
| | | 16 | | public AsiBackboneContractViolationException(string message) |
| | 102 | 17 | | : base(message) |
| | | 18 | | { |
| | 102 | 19 | | } |
| | | 20 | | |
| | | 21 | | /// <summary> |
| | | 22 | | /// Initializes a new instance of the <see cref="AsiBackboneContractViolationException" /> class. |
| | | 23 | | /// </summary> |
| | | 24 | | /// <param name="message">The contract failure message.</param> |
| | | 25 | | /// <param name="innerException">The implementation exception that triggered the contract failure.</param> |
| | | 26 | | public AsiBackboneContractViolationException(string message, Exception innerException) |
| | 12 | 27 | | : base(message, innerException) |
| | | 28 | | { |
| | 12 | 29 | | } |
| | | 30 | | } |