On 24.03.2017 20:00, Martin Kletzander wrote:
All mocked functions are related to numactl/virNuma and rely only on virsysfs, so the paths they touch can be nicely controlled. And because it is so nicely self-contained NUMA mock, it is named numamock (instead of naming it after the test that will use it first).
I'd also mention that we need the top level API mock, because some APIs might call libnuma API directly, e.g. virNumaIsAvailable(), virNumaGetMaxNode(), and so on. It took me a while to realize why you're not mocking just where src/util/virnuma gets the info from.
Signed-off-by: Martin Kletzander <mkletzan@xxxxxxxxxx> --- tests/Makefile.am | 7 ++ tests/virnumamock.c | 191 ++++++++++++++++++++++++++++++++++++++++++++++++++++ 2 files changed, 198 insertions(+) create mode 100644 tests/virnumamock.c
Michal -- libvir-list mailing list libvir-list@xxxxxxxxxx https://www.redhat.com/mailman/listinfo/libvir-list