Skip to content

Commit 25c1750

Browse files
Sort out inclusions of <test/build_info.h> vs "test_common.h"
Include `"test_common.h"` as the first thing in C files, and `<test/build_info.h>` as the first thing in header files. This requires moving `<test/test_common.h>` to its intended location `"test_common.h"`. Signed-off-by: Gilles Peskine <Gilles.Peskine@arm.com>
1 parent 30d9a62 commit 25c1750

30 files changed

Lines changed: 33 additions & 17 deletions

tests/include/test/arguments.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -14,7 +14,7 @@
1414
#ifndef TEST_ARGUMENTS_H
1515
#define TEST_ARGUMENTS_H
1616

17-
#include "test_common.h"
17+
#include "build_info.h"
1818
#include <stdint.h>
1919
#include <stdlib.h>
2020

tests/include/test/asn1_helpers.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -8,7 +8,7 @@
88
#ifndef ASN1_HELPERS_H
99
#define ASN1_HELPERS_H
1010

11-
#include "test_common.h"
11+
#include "build_info.h"
1212
#include "test/helpers.h"
1313

1414
/** Skip past an INTEGER in an ASN.1 buffer.

tests/include/test/bignum_codepath_check.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -17,7 +17,7 @@
1717
#ifndef BIGNUM_CODEPATH_CHECK_H
1818
#define BIGNUM_CODEPATH_CHECK_H
1919

20-
#include "test_common.h"
20+
#include "build_info.h"
2121

2222
#include "bignum_core.h"
2323

tests/include/test/bignum_helpers.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef TEST_BIGNUM_HELPERS_H
1414
#define TEST_BIGNUM_HELPERS_H
1515

16-
#include "test_common.h"
16+
#include "build_info.h"
1717

1818
#if defined(MBEDTLS_BIGNUM_C)
1919

tests/include/test/constant_flow.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
#ifndef TEST_CONSTANT_FLOW_H
1313
#define TEST_CONSTANT_FLOW_H
1414

15-
#include "test_common.h"
15+
#include "build_info.h"
1616

1717
/*
1818
* This file defines the two macros

tests/include/test/fake_external_rng_for_test.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#ifndef FAKE_EXTERNAL_RNG_FOR_TEST_H
1111
#define FAKE_EXTERNAL_RNG_FOR_TEST_H
1212

13-
#include "test_common.h"
13+
#include "build_info.h"
1414

1515
#if defined(MBEDTLS_PSA_CRYPTO_EXTERNAL_RNG)
1616
/** Enable the insecure implementation of mbedtls_psa_external_get_random().

tests/include/test/helpers.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -13,7 +13,7 @@
1313
#ifndef TEST_HELPERS_H
1414
#define TEST_HELPERS_H
1515

16-
#include "test_common.h"
16+
#include "build_info.h"
1717

1818
#if defined(__SANITIZE_ADDRESS__) /* gcc -fsanitize=address */
1919
# define MBEDTLS_TEST_HAVE_ASAN

tests/include/test/macros.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
#ifndef TEST_MACROS_H
1313
#define TEST_MACROS_H
1414

15-
#include "test_common.h"
15+
#include "build_info.h"
1616

1717
#include <stdlib.h>
1818

tests/include/test/memory.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -12,7 +12,7 @@
1212
#ifndef TEST_MEMORY_H
1313
#define TEST_MEMORY_H
1414

15-
#include "test_common.h"
15+
#include "build_info.h"
1616

1717
#include "mbedtls/platform.h"
1818
#include "test/helpers.h"

tests/include/test/pk_helpers.h

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -10,7 +10,7 @@
1010
#ifndef PK_HELPERS_H
1111
#define PK_HELPERS_H
1212

13-
#include "test_common.h"
13+
#include "build_info.h"
1414

1515
#if defined(MBEDTLS_PK_C)
1616

0 commit comments

Comments
 (0)