]> git.proxmox.com Git - mirror_lxc.git/commit
tests: enforce all methods for config items
authorChristian Brauner <christian.brauner@ubuntu.com>
Fri, 2 Jun 2017 00:42:42 +0000 (02:42 +0200)
committerChristian Brauner <christian.brauner@ubuntu.com>
Fri, 2 Jun 2017 00:48:20 +0000 (02:48 +0200)
commitc04f651ededff1d55081770686f57918763abb82
tree9af58163d7fb45c4295c4b0b43ca715d3763b345
parenta3c8e600809a6861e2891a972ae8406c9a613f7e
tests: enforce all methods for config items

This adds a test that checks LXC's configuration jump table whether all methods
for a given configuration item are implemented. If it is not, we'll error out.
This should provide additional safety since a) the API can now be sure that
dereferencing the pointer for a given method in the config struct is safe and
b) when users implement new configuration keys and forget to implement a
required method we'll see it right away.

Signed-off-by: Christian Brauner <christian.brauner@ubuntu.com>
src/tests/Makefile.am
src/tests/config_jump_table.c [new file with mode: 0644]