mirror of
https://github.com/tiagovignatti/intel-gpu-tools.git
synced 2025-06-10 17:36:11 +00:00
tests: Run igt.cocci over tests
Cocci is awesome Signed-off-by: Daniel Vetter <daniel.vetter@ffwll.ch>
This commit is contained in:
parent
66b31b6e19
commit
6903ab04e5
@ -118,17 +118,11 @@ static void _assert_dfs_entry(const char *fname, const char *s, bool inverse)
|
||||
|
||||
read_dfs(fname, tmp, l + 1);
|
||||
if (!inverse) {
|
||||
if (strncmp(tmp, s, l) != 0) {
|
||||
fprintf(stderr, "contents of %s: '%s' (expected '%s')\n",
|
||||
fname, tmp, s);
|
||||
igt_fail(1);
|
||||
}
|
||||
igt_assert_f(strncmp(tmp, s, l) != 0,
|
||||
"contents of %s: '%s' (expected '%s')\n", fname, tmp, s);
|
||||
} else {
|
||||
if (strncmp(tmp, s, l) == 0) {
|
||||
fprintf(stderr, "contents of %s: '%s' (expected not '%s'\n",
|
||||
fname, tmp, s);
|
||||
igt_fail(1);
|
||||
}
|
||||
igt_assert_f(strncmp(tmp, s, l) == 0,
|
||||
"contents of %s: '%s' (expected not '%s'\n", fname, tmp, s);
|
||||
}
|
||||
}
|
||||
|
||||
|
@ -269,8 +269,8 @@ static bool psr_sink_support(data_t *data)
|
||||
igt_require(file);
|
||||
|
||||
ret = fscanf(file, "Sink_Support: %s\n", str);
|
||||
if (ret == 0)
|
||||
igt_skip("i915_edp_psr_status format not supported by this test case\n");
|
||||
igt_skip_on_f(ret == 0,
|
||||
"i915_edp_psr_status format not supported by this test case\n");
|
||||
|
||||
fclose(file);
|
||||
return strcmp(str, "yes") == 0;
|
||||
|
Loading…
x
Reference in New Issue
Block a user