Skip to content

Update dependency Moq to 4.21.0 - #424

Open
renovate[bot] wants to merge 1 commit into
mainfrom
renovate/moq-4.x
Open

renovate[bot] wants to merge 1 commit into
mainfrom
renovate/moq-4.x

Conversation

@renovate

@renovate renovate Bot commented Sep 25, 2026

Copy link
Copy Markdown

This PR contains the following updates:

Package Change Age Confidence
Moq 4.18.4 → 4.21.0 age confidence

Test plan: CI should pass with updated dependencies. No review required: this is an automated dependency update PR.


Release Notes

moq/moq (Moq)

v4.21.0

Full Changelog

✨ Implemented enhancements:

  • Constructor arguments should be nullable #​1494
  • Moq "set" matcher fails when setting StringValues with string #​1465
  • Add the ability to compare ref argument by value #​1437
  • The public API is still missing nullable reference type annotations #​1418
  • "Invalid Callback" in NonVoidSetupPhrase.Returns -> ValidateCallbackReturnType is not informative or actionable #​1297
  • Allow passing method parameters to Throws/ThrowsAsync #​1296
  • Fail message on VerifyNoOtherCalls #​1263
  • Custom formatter for error messages #​1144
  • SetupSequence: CallBase Support for Void methods #​1096
  • Ability to specify proxy generator or invalidate it #​925
  • Performance improvement for Mocking many large classes #​1530 (@​crinksdr)
  • Updated ctor params to support nullable args #​1518 (@​Asafima)
  • Improve performance of It.Is matcher when used with an expression by compiling only once #​1512 (@​peterder72)

🐛 Fixed bugs:

  • Unit tests using Moq fail with runtime error after updating Moq to 4.20.72 (failure to load System.Threading.Tasks.Extensions) #​1648
  • [4.20.72] Missing XML Documentation #​1632
  • CollectionBuilderAttribute not considered for "default empty" #​1565
  • MockException reports wrong invocation list #​1534
  • Weird issue using spread operator on IEnumerable<Task> when using mocked methods #​1526
  • Changes made between 4.14.7 and 4.15.1 break exception handling #​1519
  • Generic method setups of parent types invoked #​1498
  • IVerifies.Verifiable* documentation comments errata? #​1481
  • It.IsAny<StructObject>() isn't #​1466
  • Mock.Protected().Verify fails sometimes #​1464
  • VerifySet throws TargetInvocationException when constructer refers to itself #​1455
  • Wrong Setup by using String interpolation within It.Is<string> #​1439
  • Cannot cast inside the Action<T> parameter of Verify method #​1438
  • mock.Invocations.Clear() violates self-consistency of inner mocks #​1120
  • Fix #​1648 reliably (lazy ValueTask registration + committed harness verification) #​1680 (@​kzu)
  • Minor enhancement to avoid null exceptions #​1542 (@​ShirAvneri)

🔨 Other:

  • Example for Scenario not covered in Examples #​1655
  • Adding Try Catch to Method returns empty List #​1595
  • Will Native AOT supported in future? #​1552
  • Possibility of adding Callback to ISetupSequentialAction #​1541
  • Mock.VerifyAll() with no parameters passed in should throw ArgumentOutOfRangeException #​1540
  • Could we add Verify methods to IMock<T>? #​1538
  • [FeatureRequest] Allow setting the default MockBehavior constructor parameter value #​1537
  • Question: Will parallel running mess up invocation counts? #​1536
  • Minor enhancement to avoid null exceptions. #​1533
  • Unable to use Callback or Returns on methods with more than 16 parameters. #​1531
  • Add Way to Exclude Calls from VerifyNoOtherCalls #​1490
  • Semantic error in unit test MatchesIsNotInEnumerable()? #​1483
  • Moq Setup does not work with "object" as generic type? #​1478
  • Explicit support for matching cancellation tokens with It class. (It.IsCancellationToken()) #​1477
  • Request: Ability to setup a property of type Task<ConcreteType> by mocking interface #​1460
  • Add ability for asynchronously waiting for an invocation #​1457
  • DefaultValueProvider extensibility #​1450
  • Should allow null references as constructor parameters. #​1416
  • Support Static Abstract property #​1398
  • IProtectedMock fails on a new virtual methods #​1341
  • Mocking an interface that has a sealed implementation of a method #​1334
  • Issue with multiple identical setups #​1330
  • Proper usage of It.IsAnyType #​1329
  • Better (Async) support for method returning nongeneric Task #​1328
  • Opt in parameters matching logic #​1267
  • Invocations.Clear() does not work on recursive mocks #​1242
  • VerifyNoOtherCalls fails reporting issue with different mock when using factory pattern #​1181
  • InSequence is not available for protected #​1173
  • MockRepository.Verify() also verifies mocks created outside of the repo #​1018
  • Cannot mock subclass of superclass with internal virtual methods #​991

🔀 Merged:

v4.20.72

Full Changelog

🔨 Other:

  • Question: Sponsorable Attribute in release v4.20.71 #​1513

🔀 Merged:

v4.20.71

Full Changelog

🐛 Fixed bugs:

🔨 Other:

  • Documentation Unavailable Online #​1473
  • Some source code files is filled with comments like: "Unmerged change from project " #​1451
  • Question: would it make sense to call verify all on a strict mock when the mock gets disposed? #​1440
  • SponsorLink Integration Makes Moq Unuasable due to PII and GDPR Requirements #​1433
  • Default value ILookup<> in loose mode is null #​1391
  • Verifying a protected method when the exact parameter types are not statically known #​1339

🔀 Merged:

v4.20.70

Full Changelog

🔨 Other:

  • a minor changes to improve the readability #​1419
  • Change log is not updated since version 4.18.4 #​1406
  • Stop using Moq as a guinea pig to get feedback on and develop SponsorLink #​1396
  • Permanently delete all data from SponsorLink's database that has been collected during builds that included Moq (notably any version 4.20.*) #​1395
  • SponsorLink is now OSS too and no longer bundled #​1384
  • Performance issue with large interfaces #​1350

🔀 Merged:

v4.20.69

Full Changelog

🔨 Other:

  • Trouble to unit test a lambda expression with Moq #​1387
  • Strange System.UnauthorizedAccessException during build using latest version #​1377
  • Privacy issues with SponsorLink, starting from version 4.20 #​1372
  • Upgrading to version 4.20.1 breaks the build #​1371
  • Warnings with latest version from SponsorLink #​1370
  • Missing License Information In Nuget metadata #​1348

🔀 Merged:

v4.20.2

Full Changelog

🐛 Fixed bugs:

🔨 Other:

  • Running unit tests through Rider causes AD0001 : Analyzer 'Moq.SponsorLinker' threw an exception of type 'System.UnauthorizedAccessException' #​1369

v4.20.1

Full Changelog

v4.20.0

Full Changelog

🔨 Other:

  • Documentation link in readme is broken #​1349

🔀 Merged:


Configuration

📅 Schedule: (in timezone America/Los_Angeles)

  • Branch creation
    • At any time (no schedule defined)
  • Automerge
    • At any time (no schedule defined)

🚦 Automerge: Disabled by config. Please merge this manually once you are satisfied.

♻ Rebasing: Whenever PR becomes conflicted, or you tick the rebase/retry checkbox.

🔕 Ignore: Close this PR and you won't be reminded about this update again.


  • If you want to rebase/retry this PR, check this box

This PR was generated by Mend Renovate. View the repository job log.

@renovate renovate Bot added the bot label Sep 25, 2026
@github-actions

Copy link
Copy Markdown

Test Results

0 tests  ±0   0 ✅ ±0   0s ⏱️ ±0s
0 suites ±0   0 💤 ±0 
0 files   ±0   0 ❌ ±0 

Results for commit 63af3e4. ± Comparison against base commit 9dd188e.

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.

0 participants