summaryrefslogtreecommitdiffstats
path: root/fluent-bit/tests/runtime/data/stackdriver/stackdriver_test_source_location.h
diff options
context:
space:
mode:
Diffstat (limited to 'fluent-bit/tests/runtime/data/stackdriver/stackdriver_test_source_location.h')
-rw-r--r--fluent-bit/tests/runtime/data/stackdriver/stackdriver_test_source_location.h70
1 files changed, 70 insertions, 0 deletions
diff --git a/fluent-bit/tests/runtime/data/stackdriver/stackdriver_test_source_location.h b/fluent-bit/tests/runtime/data/stackdriver/stackdriver_test_source_location.h
new file mode 100644
index 00000000..0bf419f5
--- /dev/null
+++ b/fluent-bit/tests/runtime/data/stackdriver/stackdriver_test_source_location.h
@@ -0,0 +1,70 @@
+#define SOURCELOCATION_COMMON_CASE "[" \
+ "1591111124," \
+ "{" \
+ "\"logging.googleapis.com/sourceLocation\": " \
+ "{" \
+ "\"file\": \"test_file\"," \
+ "\"line\": 123," \
+ "\"function\": \"test_function\"" \
+ "}" \
+ "}]"
+
+#define SOURCELOCATION_COMMON_CASE_LINE_IN_STRING "[" \
+ "1591111124," \
+ "{" \
+ "\"logging.googleapis.com/sourceLocation\": " \
+ "{" \
+ "\"file\": \"test_file\"," \
+ "\"line\": \"123\"," \
+ "\"function\": \"test_function\"" \
+ "}" \
+ "}]"
+
+#define EMPTY_SOURCELOCATION "[" \
+ "1591111124," \
+ "{" \
+ "\"logging.googleapis.com/sourceLocation\": " \
+ "{" \
+ "}" \
+ "}]"
+
+#define SOURCELOCATION_IN_STRING "[" \
+ "1591111124," \
+ "{" \
+ "\"logging.googleapis.com/sourceLocation\": \"some string\"" \
+ "}]"
+
+#define PARTIAL_SOURCELOCATION "[" \
+ "1591111124," \
+ "{" \
+ "\"logging.googleapis.com/sourceLocation\": " \
+ "{" \
+ "\"function\": \"test_function\"" \
+ "}" \
+ "}]"
+
+#define SOURCELOCATION_SUBFIELDS_IN_INCORRECT_TYPE "[" \
+ "1591111124," \
+ "{" \
+ "\"logging.googleapis.com/sourceLocation\": " \
+ "{" \
+ "\"file\": 123," \
+ "\"line\": \"some string\"," \
+ "\"function\": true" \
+ "}" \
+ "}]"
+
+#define SOURCELOCATION_EXTRA_SUBFIELDS_EXISTED "[" \
+ "1591111124," \
+ "{" \
+ "\"logging.googleapis.com/sourceLocation\": " \
+ "{" \
+ "\"file\": \"test_file\"," \
+ "\"line\": 123," \
+ "\"function\": \"test_function\"," \
+ "\"extra_key1\": \"extra_val1\"," \
+ "\"extra_key2\": 123," \
+ "\"extra_key3\": true" \
+ "}" \
+ "}]"
+ \ No newline at end of file