Completed
Last Updated: 16 Sep 2021 08:37 by ADMIN
Megges
Created on: 25 Aug 2021 14:51
Type: Bug Report
0
OccursNever does not work with InOrder anymore

The following test is not working anymore since version JustMock_2021_2_615_4 but was working with JustMock_2021_1_326_1 and older versions:

public interface ITest
{
    void Test(string text);
}

[TestMethod]
public void MyTestMethod()
{
    var mock = Mock.Create<ITest>();
    Mock.Arrange(() => mock.Test("")).IgnoreArguments().OccursNever();
    Mock.Arrange(() => mock.Test(Arg.Matches<string>(a => a == "a"))).InOrder().OccursOnce();
    Mock.Arrange(() => mock.Test(Arg.Matches<string>(a => a == "b"))).InOrder().OccursOnce();


    mock.Test("a");
    mock.Test("b");

    Mock.Assert(mock);
}

If I remove the OccorsNever line, its working.
If I remove the 2 InOrder, its working.

Seems that something change there: https://www.telerik.com/support/whats-new/justmock/release-history/justmock-r2-sp1-2021

2 comments
ADMIN
Mihail
Posted on: 16 Sep 2021 08:37

The issue is fixed and it is available with the R3 2021 version 2021.3.915.1.

Regards,
Mihail
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.

ADMIN
Ivo
Posted on: 27 Aug 2021 16:30

Hello Max,

I confirm that we have introduced a regression with newly added enhancements in R2.2021.SP1 release related to InOrder. I believe that we are able to solve it and deliver the fix timely.

In appreciation for your involvement, I have also updated your Telerik points. If you have any questions or comments feel free to write back to us.

Regards,
Ivo
Progress Telerik

Love the Telerik and Kendo UI products and believe more people should try them? Invite a fellow developer to become a Progress customer and each of you can get a $50 Amazon gift voucher.