diff options
Diffstat (limited to 'tests/include/test.h')
-rw-r--r-- | tests/include/test.h | 31 |
1 files changed, 29 insertions, 2 deletions
diff --git a/tests/include/test.h b/tests/include/test.h index b4e0dd2b5..ef0b9a6f6 100644 --- a/tests/include/test.h +++ b/tests/include/test.h @@ -1,5 +1,17 @@ -/* SPDX-License-Identifier: GPL-2.0-only */ -/* This file is part of the coreboot project. */ +/* + * This file is part of the flashrom project. + * + * Copyright 2020 Google LLC + * + * This program is free software; you can redistribute it and/or modify + * it under the terms of the GNU General Public License as published by + * the Free Software Foundation; version 2 of the License. + * + * This program is distributed in the hope that it will be useful, + * but WITHOUT ANY WARRANTY; without even the implied warranty of + * MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the + * GNU General Public License for more details. + */ #ifndef _TESTS_TEST_H #define _TESTS_TEST_H @@ -15,4 +27,19 @@ #include <setjmp.h> #include <cmocka.h> +#define NON_ZERO (0xf000baaa) + +#define MOCK_FD (0x10ec) + +#define SKIP_TEST(name) \ + void name (void **state) { skip(); } + +/* + * Having this as function allows to set a breakpoint on the address, + * as it has a named symbol associated with the address number. + */ +void *not_null(void); + +#define LOG_ME printf("%s is called\n", __func__) + #endif /* _TESTS_TEST_H */ |