2
0
mirror of https://github.com/koreader/koreader synced 2024-11-10 01:10:34 +00:00

make: fix testfront rule

Same behavior as for base: build and install test data before running.
This commit is contained in:
Benoit Pierre 2024-07-31 01:55:37 +02:00 committed by Frans de Jonge
parent 1add3b5772
commit 47a2d3900f
2 changed files with 6 additions and 6 deletions

View File

@ -9,6 +9,6 @@ pushd install/koreader && {
BUSTED_SPEC_FILE="$(circleci tests glob "spec/front/unit/*_spec.lua" | circleci tests split --split-by=timings --timings-type=filename | tr '\n' ' ')"
} && popd || exit
make testfront BUSTED_SPEC_FILE="${BUSTED_SPEC_FILE}"
make testfront --assume-old=all BUSTED_SPEC_FILE="${BUSTED_SPEC_FILE}"
# vim: sw=4

View File

@ -1,4 +1,4 @@
PHONY = all android-ndk android-sdk base clean coverage distclean doc fetchthirdparty po pot re static-check test testfront
PHONY = all android-ndk android-sdk base clean coverage distclean doc fetchthirdparty po pot re static-check test testbase testfront
SOUND = $(INSTALL_DIR)/%
# koreader-base directory
@ -103,14 +103,14 @@ $(INSTALL_DIR)/koreader/.busted: .busted
$(INSTALL_DIR)/koreader/.luacov:
$(SYMLINK) .luacov $@
testfront: $(INSTALL_DIR)/koreader/.busted
testbase: base-test
testfront: all test-data $(INSTALL_DIR)/koreader/.busted
# sdr files may have unexpected impact on unit testing
-rm -rf spec/unit/data/*.sdr
cd $(INSTALL_DIR)/koreader && $(BUSTED_LUAJIT) $(BUSTED_OVERRIDES) $(BUSTED_SPEC_FILE)
test: $(INSTALL_DIR)/koreader/.busted
$(MAKE) -C $(KOR_BASE) test
$(MAKE) testfront
test: testbase testfront
coverage: $(INSTALL_DIR)/koreader/.luacov
-rm -rf $(INSTALL_DIR)/koreader/luacov.*.out