diff --git a/src/tests/get_item.c b/src/tests/get_item.c index f4c8d9228..f2757c29d 100644 --- a/src/tests/get_item.c +++ b/src/tests/get_item.c @@ -600,6 +600,12 @@ int main(int argc, char *argv[]) goto out; } + if (c->set_config_item(c, "lxc.notaconfigkey", "invalid")) { + fprintf(stderr, "%d: Managed to set \"lxc.notaconfigkey\"\n", __LINE__); + goto out; + } + + printf("All get_item tests passed\n"); fret = EXIT_SUCCESS; diff --git a/src/tests/parse_config_file.c b/src/tests/parse_config_file.c index b13982d30..b8b71c8e1 100644 --- a/src/tests/parse_config_file.c +++ b/src/tests/parse_config_file.c @@ -778,6 +778,11 @@ int main(int argc, char *argv[]) goto non_test_error; } + if (c->set_config_item(c, "lxc.notaconfigkey", "invalid")) { + lxc_error("%s\n", "Managed to set to set invalid config item \"lxc.notaconfigkey\" to \"invalid\""); + return -1; + } + fret = EXIT_SUCCESS; non_test_error: