mirror of
https://gitlab.freedesktop.org/NetworkManager/NetworkManager.git
synced 2026-05-09 03:38:09 +02:00
shared: move "nm-test-utils.h" to "src/libnm-glib-aux/"
"nm-test-utils.h" is a header-only, helper library for our unit tests. It was somewhat unmotivated in "shared/nm-utils", because all tests use it, but it was not part of a "module". Move it to "src/libnm-glib-aux/". It fits there very well. They both have (only) a dependency on glib.
This commit is contained in:
parent
3906cc9cf4
commit
b53c50e778
19 changed files with 18 additions and 20 deletions
|
|
@ -435,6 +435,7 @@ src_libnm_glib_aux_libnm_glib_aux_la_SOURCES = \
|
||||||
src/libnm-glib-aux/nm-shared-utils.c \
|
src/libnm-glib-aux/nm-shared-utils.c \
|
||||||
src/libnm-glib-aux/nm-shared-utils.h \
|
src/libnm-glib-aux/nm-shared-utils.h \
|
||||||
src/libnm-glib-aux/nm-str-buf.h \
|
src/libnm-glib-aux/nm-str-buf.h \
|
||||||
|
src/libnm-glib-aux/nm-test-utils.h \
|
||||||
src/libnm-glib-aux/nm-time-utils.c \
|
src/libnm-glib-aux/nm-time-utils.c \
|
||||||
src/libnm-glib-aux/nm-time-utils.h \
|
src/libnm-glib-aux/nm-time-utils.h \
|
||||||
src/libnm-glib-aux/nm-value-type.h \
|
src/libnm-glib-aux/nm-value-type.h \
|
||||||
|
|
@ -5478,11 +5479,8 @@ EXTRA_DIST += \
|
||||||
\
|
\
|
||||||
po/meson.build \
|
po/meson.build \
|
||||||
\
|
\
|
||||||
shared/nm-test-libnm-utils.h \
|
|
||||||
shared/nm-test-utils-impl.c \
|
|
||||||
shared/nm-utils/nm-compat.c \
|
shared/nm-utils/nm-compat.c \
|
||||||
shared/nm-utils/nm-compat.h \
|
shared/nm-utils/nm-compat.h \
|
||||||
shared/nm-utils/nm-test-utils.h \
|
|
||||||
shared/nm-utils/nm-vpn-editor-plugin-call.h \
|
shared/nm-utils/nm-vpn-editor-plugin-call.h \
|
||||||
shared/nm-utils/nm-vpn-plugin-macros.h \
|
shared/nm-utils/nm-vpn-plugin-macros.h \
|
||||||
shared/nm-utils/nm-vpn-plugin-utils.c \
|
shared/nm-utils/nm-vpn-plugin-utils.c \
|
||||||
|
|
|
||||||
|
|
@ -5,7 +5,7 @@
|
||||||
#include "nm-cloud-setup-utils.h"
|
#include "nm-cloud-setup-utils.h"
|
||||||
#include "libnm-core-aux-intern/nm-libnm-core-utils.h"
|
#include "libnm-core-aux-intern/nm-libnm-core-utils.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -9,7 +9,7 @@
|
||||||
#include "nm-vpn-helpers.h"
|
#include "nm-vpn-helpers.h"
|
||||||
#include "nm-client-utils.h"
|
#include "nm-client-utils.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@
|
||||||
#include "libnm-core-aux-extern/nm-libnm-core-aux.h"
|
#include "libnm-core-aux-extern/nm-libnm-core-aux.h"
|
||||||
#include "libnm-core-aux-intern/nm-libnm-core-utils.h"
|
#include "libnm-core-aux-intern/nm-libnm-core-utils.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
#include "nm-dispatcher-utils.h"
|
#include "nm-dispatcher-utils.h"
|
||||||
#include "libnm-core-aux-extern/nm-dispatcher-api.h"
|
#include "libnm-core-aux-extern/nm-dispatcher-api.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
#include "nmdbus-dispatcher.h"
|
#include "nmdbus-dispatcher.h"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -24,7 +24,7 @@
|
||||||
#include "nm-vpn-service-plugin.h"
|
#include "nm-vpn-service-plugin.h"
|
||||||
#include "libnm-core-aux-intern/nm-libnm-core-utils.h"
|
#include "libnm-core-aux-intern/nm-libnm-core-utils.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -8,7 +8,7 @@
|
||||||
|
|
||||||
#include "NetworkManager.h"
|
#include "NetworkManager.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
typedef struct {
|
typedef struct {
|
||||||
GDBusConnection *bus;
|
GDBusConnection *bus;
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
|
|
||||||
#define _NMTST_INSIDE_CORE 1
|
#define _NMTST_INSIDE_CORE 1
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
|
|
||||||
#include "nm-property-compare.h"
|
#include "nm-property-compare.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
static void
|
static void
|
||||||
compare_ints(void)
|
compare_ints(void)
|
||||||
|
|
|
||||||
|
|
@ -15,7 +15,7 @@
|
||||||
#include "nm-errors.h"
|
#include "nm-errors.h"
|
||||||
#include "libnm-core-intern/nm-core-internal.h"
|
#include "libnm-core-intern/nm-core-internal.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -64,7 +64,7 @@
|
||||||
|
|
||||||
#include "test-general-enums.h"
|
#include "test-general-enums.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/* When passing a "bool" typed argument to a variadic function that
|
/* When passing a "bool" typed argument to a variadic function that
|
||||||
* expects a gboolean, the compiler will promote the integer type
|
* expects a gboolean, the compiler will promote the integer type
|
||||||
|
|
|
||||||
|
|
@ -16,7 +16,7 @@
|
||||||
#include "nm-setting-user.h"
|
#include "nm-setting-user.h"
|
||||||
#include "nm-setting-proxy.h"
|
#include "nm-setting-proxy.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
||||||
#define TEST_WIRED_TLS_CA_CERT TEST_CERT_DIR "/test-ca-cert.pem"
|
#define TEST_WIRED_TLS_CA_CERT TEST_CERT_DIR "/test-ca-cert.pem"
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@
|
||||||
#include "nm-utils.h"
|
#include "nm-utils.h"
|
||||||
#include "libnm-core-intern/nm-core-internal.h"
|
#include "libnm-core-intern/nm-core-internal.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
||||||
#define TEST_NEED_SECRETS_EAP_TLS_CA_CERT TEST_CERT_DIR "/test_ca_cert.pem"
|
#define TEST_NEED_SECRETS_EAP_TLS_CA_CERT TEST_CERT_DIR "/test_ca_cert.pem"
|
||||||
|
|
|
||||||
|
|
@ -28,7 +28,7 @@
|
||||||
#include "nm-errors.h"
|
#include "nm-errors.h"
|
||||||
#include "libnm-core-intern/nm-keyfile-internal.h"
|
#include "libnm-core-intern/nm-keyfile-internal.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
#define TEST_CERT_DIR NM_BUILD_SRCDIR "/src/libnm-core-impl/tests/certs"
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -20,7 +20,7 @@
|
||||||
#include "nm-setting-wireless.h"
|
#include "nm-setting-wireless.h"
|
||||||
#include "nm-setting-wireless-security.h"
|
#include "nm-setting-wireless-security.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
static void
|
static void
|
||||||
test_defaults(GType type, const char *name)
|
test_defaults(GType type, const char *name)
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
|
|
||||||
#include "libnm-glib-aux/nm-json-aux.h"
|
#include "libnm-glib-aux/nm-json-aux.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -11,7 +11,7 @@
|
||||||
#include "libnm-glib-aux/nm-time-utils.h"
|
#include "libnm-glib-aux/nm-time-utils.h"
|
||||||
#include "libnm-glib-aux/nm-ref-string.h"
|
#include "libnm-glib-aux/nm-ref-string.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -6,7 +6,7 @@
|
||||||
#include "libnm-platform/nm-netlink.h"
|
#include "libnm-platform/nm-netlink.h"
|
||||||
#include "libnm-platform/nmp-netns.h"
|
#include "libnm-platform/nmp-netns.h"
|
||||||
|
|
||||||
#include "nm-utils/nm-test-utils.h"
|
#include "libnm-glib-aux/nm-test-utils.h"
|
||||||
|
|
||||||
/*****************************************************************************/
|
/*****************************************************************************/
|
||||||
|
|
||||||
|
|
|
||||||
Loading…
Add table
Reference in a new issue