-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathMakefile
More file actions
23 lines (18 loc) · 856 Bytes
/
Copy pathMakefile
File metadata and controls
23 lines (18 loc) · 856 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
.PHONY: webserver
webserver:
RUST_LOG=info SQLX_OFFLINE=true DATABASE_URL="sqlite:memory:" DATABASE_MIGRATION_DIR="migrations" cargo build --bin=tvserver --package=tvserver --manifest-path=./Cargo.toml --features=webserver --no-default-features
.PHONY: build
build: webserver
.PHONY: run-webserver
run-webserver:
RUST_LOG=info SQLX_OFFLINE=true DATABASE_URL="sqlite:memory:" DATABASE_MIGRATION_DIR="migrations" cargo run --bin=tvserver --package=tvserver --manifest-path=./Cargo.toml --features=webserver --no-default-features
.PHONY: test-unit
test-unit:
cargo test --no-default-features --features webserver --lib
.PHONY: test-integration
test-integration:
set -e; for test in tests/*_test.rs; do \
cargo test --no-default-features --features webserver --test "$$(basename "$$test" .rs)"; \
done
.PHONY: test
test: test-unit test-integration