missing mock routine is causes the tests to fail at build time when $rpcenv->check is called.
previous assumption was returning 'root@pam' to get_user() so we can do the same here. Signed-off-by: Oguz Bektas <[email protected]> --- v2->v3: * added new, since we need to run $rpcenv->check inside the unit tests for migration test/MigrationTest/QmMock.pm | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/test/MigrationTest/QmMock.pm b/test/MigrationTest/QmMock.pm index 2d5d5c6..eb6ea53 100644 --- a/test/MigrationTest/QmMock.pm +++ b/test/MigrationTest/QmMock.pm @@ -40,6 +40,11 @@ sub fork_worker { return '123456'; } +sub check { + my ($self, $authuser, $path, $priv, $noerr) = @_; + return 1 if $authuser eq 'root@pam'; +} + # mocked modules my $inotify_module = Test::MockModule->new("PVE::INotify"); -- 2.30.2 _______________________________________________ pve-devel mailing list [email protected] https://lists.proxmox.com/cgi-bin/mailman/listinfo/pve-devel
