Skip to content

Commit cefb094

Browse files
committed
Makefile: Database tests need backend
fixes this error: make test-sqlite go test -c code.gitea.io/gitea/tests/integration -o integrations.sqlite.test -tags ' sqlite sqlite_unlock_notify' sed -e 's|{{REPO_TEST_DIR}}||g' \ -e 's|{{TEST_LOGGER}}|test,file|g' \ -e 's|{{TEST_TYPE}}|integration|g' \ tests/sqlite.ini.tmpl > tests/sqlite.ini GITEA_ROOT="/home/hramrach/gitea" GITEA_CONF=tests/sqlite.ini ./integrations.sqlite.test Could not find gitea binary at /home/hramrach/gitea/gitea make: *** [Makefile:506: test-sqlite] Error 1
1 parent db5de52 commit cefb094

File tree

1 file changed

+18
-18
lines changed

1 file changed

+18
-18
lines changed

Makefile

Lines changed: 18 additions & 18 deletions
Original file line numberDiff line numberDiff line change
@@ -503,11 +503,11 @@ generate-ini-sqlite:
503503
tests/sqlite.ini.tmpl > tests/sqlite.ini
504504

505505
.PHONY: test-sqlite
506-
test-sqlite: integrations.sqlite.test generate-ini-sqlite
506+
test-sqlite: integrations.sqlite.test generate-ini-sqlite backend
507507
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/sqlite.ini ./integrations.sqlite.test
508508

509509
.PHONY: test-sqlite\#%
510-
test-sqlite\#%: integrations.sqlite.test generate-ini-sqlite
510+
test-sqlite\#%: integrations.sqlite.test generate-ini-sqlite backend
511511
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/sqlite.ini ./integrations.sqlite.test -test.run $(subst .,/,$*)
512512

513513
.PHONY: test-sqlite-migration
@@ -524,11 +524,11 @@ generate-ini-mysql:
524524
tests/mysql.ini.tmpl > tests/mysql.ini
525525

526526
.PHONY: test-mysql
527-
test-mysql: integrations.mysql.test generate-ini-mysql
527+
test-mysql: integrations.mysql.test generate-ini-mysql backend
528528
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mysql.ini ./integrations.mysql.test
529529

530530
.PHONY: test-mysql\#%
531-
test-mysql\#%: integrations.mysql.test generate-ini-mysql
531+
test-mysql\#%: integrations.mysql.test generate-ini-mysql backend
532532
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mysql.ini ./integrations.mysql.test -test.run $(subst .,/,$*)
533533

534534
.PHONY: test-mysql-migration
@@ -547,11 +547,11 @@ generate-ini-pgsql:
547547
tests/pgsql.ini.tmpl > tests/pgsql.ini
548548

549549
.PHONY: test-pgsql
550-
test-pgsql: integrations.pgsql.test generate-ini-pgsql
550+
test-pgsql: integrations.pgsql.test generate-ini-pgsql backend
551551
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/pgsql.ini ./integrations.pgsql.test
552552

553553
.PHONY: test-pgsql\#%
554-
test-pgsql\#%: integrations.pgsql.test generate-ini-pgsql
554+
test-pgsql\#%: integrations.pgsql.test generate-ini-pgsql backend
555555
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/pgsql.ini ./integrations.pgsql.test -test.run $(subst .,/,$*)
556556

557557
.PHONY: test-pgsql-migration
@@ -568,11 +568,11 @@ generate-ini-mssql:
568568
tests/mssql.ini.tmpl > tests/mssql.ini
569569

570570
.PHONY: test-mssql
571-
test-mssql: integrations.mssql.test generate-ini-mssql
571+
test-mssql: integrations.mssql.test generate-ini-mssql backend
572572
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mssql.ini ./integrations.mssql.test
573573

574574
.PHONY: test-mssql\#%
575-
test-mssql\#%: integrations.mssql.test generate-ini-mssql
575+
test-mssql\#%: integrations.mssql.test generate-ini-mssql backend
576576
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mssql.ini ./integrations.mssql.test -test.run $(subst .,/,$*)
577577

578578
.PHONY: test-mssql-migration
@@ -623,27 +623,27 @@ test-e2e-mssql\#%: playwright e2e.mssql.test generate-ini-mssql
623623
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mssql.ini ./e2e.mssql.test -test.run TestE2e/$*
624624

625625
.PHONY: bench-sqlite
626-
bench-sqlite: integrations.sqlite.test generate-ini-sqlite
626+
bench-sqlite: integrations.sqlite.test generate-ini-sqlite backend
627627
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/sqlite.ini ./integrations.sqlite.test -test.cpuprofile=cpu.out -test.run DontRunTests -test.bench .
628628

629629
.PHONY: bench-mysql
630-
bench-mysql: integrations.mysql.test generate-ini-mysql
630+
bench-mysql: integrations.mysql.test generate-ini-mysql backend
631631
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mysql.ini ./integrations.mysql.test -test.cpuprofile=cpu.out -test.run DontRunTests -test.bench .
632632

633633
.PHONY: bench-mssql
634-
bench-mssql: integrations.mssql.test generate-ini-mssql
634+
bench-mssql: integrations.mssql.test generate-ini-mssql backend
635635
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mssql.ini ./integrations.mssql.test -test.cpuprofile=cpu.out -test.run DontRunTests -test.bench .
636636

637637
.PHONY: bench-pgsql
638-
bench-pgsql: integrations.pgsql.test generate-ini-pgsql
638+
bench-pgsql: integrations.pgsql.test generate-ini-pgsql backend
639639
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/pgsql.ini ./integrations.pgsql.test -test.cpuprofile=cpu.out -test.run DontRunTests -test.bench .
640640

641641
.PHONY: integration-test-coverage
642-
integration-test-coverage: integrations.cover.test generate-ini-mysql
642+
integration-test-coverage: integrations.cover.test generate-ini-mysql backend
643643
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mysql.ini ./integrations.cover.test -test.coverprofile=integration.coverage.out
644644

645645
.PHONY: integration-test-coverage-sqlite
646-
integration-test-coverage-sqlite: integrations.cover.sqlite.test generate-ini-sqlite
646+
integration-test-coverage-sqlite: integrations.cover.sqlite.test generate-ini-sqlite backend
647647
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/sqlite.ini ./integrations.cover.sqlite.test -test.coverprofile=integration.coverage.out
648648

649649
integrations.mysql.test: git-check $(GO_SOURCES)
@@ -665,22 +665,22 @@ integrations.cover.sqlite.test: git-check $(GO_SOURCES)
665665
$(GO) test $(GOTESTFLAGS) -c code.gitea.io/gitea/tests/integration -coverpkg $(shell echo $(GO_TEST_PACKAGES) | tr ' ' ',') -o integrations.cover.sqlite.test -tags '$(TEST_TAGS)'
666666

667667
.PHONY: migrations.mysql.test
668-
migrations.mysql.test: $(GO_SOURCES) generate-ini-mysql
668+
migrations.mysql.test: $(GO_SOURCES) generate-ini-mysql backend
669669
$(GO) test $(GOTESTFLAGS) -c code.gitea.io/gitea/tests/integration/migration-test -o migrations.mysql.test
670670
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mysql.ini ./migrations.mysql.test
671671

672672
.PHONY: migrations.pgsql.test
673-
migrations.pgsql.test: $(GO_SOURCES) generate-ini-pgsql
673+
migrations.pgsql.test: $(GO_SOURCES) generate-ini-pgsql backend
674674
$(GO) test $(GOTESTFLAGS) -c code.gitea.io/gitea/tests/integration/migration-test -o migrations.pgsql.test
675675
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/pgsql.ini ./migrations.pgsql.test
676676

677677
.PHONY: migrations.mssql.test
678-
migrations.mssql.test: $(GO_SOURCES) generate-ini-mssql
678+
migrations.mssql.test: $(GO_SOURCES) generate-ini-mssql backend
679679
$(GO) test $(GOTESTFLAGS) -c code.gitea.io/gitea/tests/integration/migration-test -o migrations.mssql.test
680680
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/mssql.ini ./migrations.mssql.test
681681

682682
.PHONY: migrations.sqlite.test
683-
migrations.sqlite.test: $(GO_SOURCES) generate-ini-sqlite
683+
migrations.sqlite.test: $(GO_SOURCES) generate-ini-sqlite backend
684684
$(GO) test $(GOTESTFLAGS) -c code.gitea.io/gitea/tests/integration/migration-test -o migrations.sqlite.test -tags '$(TEST_TAGS)'
685685
GITEA_ROOT="$(CURDIR)" GITEA_CONF=tests/sqlite.ini ./migrations.sqlite.test
686686

0 commit comments

Comments
 (0)