mirror of
https://github.com/ElementsProject/lightning.git
synced 2025-01-03 20:44:54 +01:00
fbe50e087a
Since we now over-write the wally malloc/free functions, we need to do so for tests as well. Here we pull up all of the common setup/teardown logic into a separate place, and update the tests that use libwally to use the new common_setup core Changelog-None
18 lines
705 B
Makefile
18 lines
705 B
Makefile
BITCOIN_TEST_SRC := $(wildcard bitcoin/test/run-*.c)
|
|
BITCOIN_TEST_OBJS := $(BITCOIN_TEST_SRC:.c=.o)
|
|
BITCOIN_TEST_PROGRAMS := $(BITCOIN_TEST_OBJS:.o=)
|
|
|
|
BITCOIN_TEST_COMMON_OBJS := common/utils.o common/setup.o
|
|
|
|
$(BITCOIN_TEST_PROGRAMS): $(CCAN_OBJS) $(BITCOIN_TEST_COMMON_OBJS) bitcoin/chainparams.o
|
|
$(BITCOIN_TEST_OBJS): $(CCAN_HEADERS) $(BITCOIN_HEADERS) $(BITCOIN_SRC)
|
|
|
|
ALL_TEST_PROGRAMS += $(BITCOIN_TEST_PROGRAMS)
|
|
ALL_OBJS += $(BITCOIN_TEST_PROGRAMS:=.o)
|
|
|
|
# This needs to know what level of optimization we're using.
|
|
bitcoin/test/run-secret_eq_consttime.o: CFLAGS += -DCOPTFLAGS="\"${COPTFLAGS}\""
|
|
update-mocks: $(BITCOIN_TEST_SRC:%=update-mocks/%)
|
|
|
|
check-units: $(BITCOIN_TEST_PROGRAMS:%=unittest/%)
|