提交 a6493694 编写于 作者: P Peter Krempa

tests: storage: Remove unused test modes

EXP_WARN and ALLOW_PROBE flags for the testStorageChain cases are no
longer used so we can remove them.
Signed-off-by: NPeter Krempa <pkrempa@redhat.com>
Reviewed-by: NMichal Privoznik <mprivozn@redhat.com>
上级 7e582fe9
......@@ -242,8 +242,6 @@ struct _testFileData
enum {
EXP_PASS = 0,
EXP_FAIL = 1,
EXP_WARN = 2,
ALLOW_PROBE = 4,
};
struct testChainData
......@@ -288,25 +286,15 @@ testStorageChain(const void *args)
fprintf(stderr, "call should have failed\n");
return -1;
}
if (data->flags & EXP_WARN) {
if (virGetLastErrorCode() == VIR_ERR_OK) {
fprintf(stderr, "call should have warned\n");
return -1;
}
virResetLastError();
if (virStorageFileChainGetBroken(meta, &broken) || !broken) {
fprintf(stderr, "call should identify broken part of chain\n");
return -1;
}
} else {
if (virGetLastErrorCode()) {
fprintf(stderr, "call should not have warned\n");
return -1;
}
if (virStorageFileChainGetBroken(meta, &broken) || broken) {
fprintf(stderr, "chain should not be identified as broken\n");
return -1;
}
if (virGetLastErrorCode()) {
fprintf(stderr, "call should not have reported error\n");
return -1;
}
if (virStorageFileChainGetBroken(meta, &broken) || broken) {
fprintf(stderr, "chain should not be identified as broken\n");
return -1;
}
elt = meta;
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册