openbmc-build-scripts icon indicating copy to clipboard operation
openbmc-build-scripts copied to clipboard

Need systemd in the unit test docker

Open ShichenLin opened this issue 4 years ago • 1 comments

I have a problem that I write a new unit test for bmcweb but this test cannot run via the current CI flow. My unit test focuses on the subscription part of Event Service, so it runs bmcweb app partially and mimics a client to check on the broadcasted test events. However, the HTTP part of bmcweb needs systemd-resolved.service to resolve hostnames and thus further depends on systemd while systemd is not supported in the unit test docker, so is it possible to add systemd in the unit test docker?

ShichenLin avatar Jan 20 '22 00:01 ShichenLin

You should mock out the dbus calls that bmcweb would interact with. There should be other examples of creating a dummy dbus end-point.

williamspatrick avatar Jan 20 '22 03:01 williamspatrick