Skip to content

Expect multiple calls to a function #332

@kurt

Description

@kurt

Hi I am wondering how to expect multiple calls to a stub function. I am running a loop in the function that I am calling in my test which calls a nested function multiple times. When I try to use expect it fails as it was called more than once. Thanks! Here is some sudo of what I am trying to do

test_name(){ nested_func_expect(inputs); func_under_test();; }

func_under_test(){ for(i=0;i<14;i++){nested_func(inputs);} }

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions