Skip to content

Commit

Permalink
Fix test for import-backend
Browse files Browse the repository at this point in the history
Another split function needed mocking
  • Loading branch information
gjanssens committed Feb 23, 2023
1 parent fa980fb commit 549c93e
Show file tree
Hide file tree
Showing 2 changed files with 8 additions and 0 deletions.
7 changes: 7 additions & 0 deletions libgnucash/engine/mocks/gmock-Split.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -103,6 +103,13 @@ xaccSplitGetMemo (const Split *split)
return mocksplit ? mocksplit->get_memo() : "";
}

void
xaccSplitSetMemo (Split *split, const char *memo)
{
ASSERT_TRUE(GNC_IS_MOCKSPLIT(split));
gnc_mocksplit(split)->set_memo(memo);
}

char
xaccSplitGetReconcile (const Split *split)
{
Expand Down
1 change: 1 addition & 0 deletions libgnucash/engine/mocks/gmock-Split.h
Original file line number Diff line number Diff line change
Expand Up @@ -71,6 +71,7 @@ class MockSplit : public Split
MOCK_CONST_METHOD0(get_value, gnc_numeric());
MOCK_METHOD1(set_value, void(gnc_numeric));
MOCK_CONST_METHOD0(get_memo, const char *());
MOCK_METHOD1(set_memo, void(const char *));
MOCK_CONST_METHOD0(get_reconcile, char());
MOCK_METHOD1(set_reconcile, void(char));
MOCK_METHOD1(set_date_reconciled_secs, void(time64));
Expand Down

0 comments on commit 549c93e

Please sign in to comment.