|
suricata
|
#include "../detect-engine.h"#include "../detect-engine-helper.h"#include "../detect-parse.h"#include "../util-byte.h"#include "../util-unittest.h"

Go to the source code of this file.
Data Structures | |
| struct | UtilPluginTestKwData_ |
Macros | |
| #define | UTIL_PLUGIN_TEST_KW "util-plugin-test" |
Typedefs | |
| typedef struct UtilPluginTestKwData_ | UtilPluginTestKwData |
Functions | |
| void | UtilPluginRegisterTests (void) |
Tests for plugin patterns.
These tests exercise the API as it is used by plugins and by keywords implemented in Rust, which can't see Suricata internals such as the Signature and SigMatch structs. Some of these patterns are not used by Suricata itself, so these tests may be their only in-tree user.
Write the tests the way a plugin would: register through the public helpers (e.g. SCDetectHelperKeywordRegister()) and only use SC-prefixed API functions for keyword and signature access, never struct fields. This file can see the internals, so nothing but this rule enforces that.
Definition in file util-plugin.c.
| #define UTIL_PLUGIN_TEST_KW "util-plugin-test" |
Definition at line 48 of file util-plugin.c.
| typedef struct UtilPluginTestKwData_ UtilPluginTestKwData |
| void UtilPluginRegisterTests | ( | void | ) |
Definition at line 211 of file util-plugin.c.
References UtRegisterTest().
