[08/33] cocci: Fixup assert() rule to only apply to tests/

Submitted by Lyude Paul on June 10, 2019, 3:02 p.m.

Details

Message ID 20190610150321.512-8-lyude@redhat.com
State New
Headers show
Series "Series without cover letter" ( rev: 1 ) in IGT - Trybot

Not browsing as part of any series.

Commit Message

Lyude Paul June 10, 2019, 3:02 p.m.
From: Lyude Paul <lyude@redhat.com>

See the discussion in 3f26aa32f2f9a17dd7fdf1a22321be02a6e63374 for more
information.

Signed-off-by: Lyude Paul <lyude@redhat.com>
---
 lib/igt.cocci | 4 ++--
 1 file changed, 2 insertions(+), 2 deletions(-)

Patch hide | download patch | download mbox

diff --git a/lib/igt.cocci b/lib/igt.cocci
index 8e72be55..c241f34a 100644
--- a/lib/igt.cocci
+++ b/lib/igt.cocci
@@ -91,8 +91,8 @@  expression pipe;
 ...
 }
 
-// Tests and test libraries really shouldn't use plain assert!
-@@
+// Tests really shouldn't use plain assert!
+@depends on file in "tests/"@
 expression E;
 @@
 - assert(E);