.PHONY: build build-release build-all-features test test-rust check check-full fmt fmt-check clippy audit outdated deny \
test-parity-phase-a test-parity-phase-b test-parity-phase-c test-parity-phase-d \
test-parity-phase-e test-parity-phase-f test-parity-phase-g test-parity-phases \
sparkless-parity all
export RUSTUP_TOOLCHAIN ?= stable
export CARGO_HOME := $(HOME)/.cargo
build:
cargo build
build-release:
cargo build --release
build-all-features:
cargo build --all-features
test-rust:
cargo test
test: test-rust
check: fmt-check clippy audit deny build-all-features test-rust
@echo "All checks passed"
check-full: check
@echo "check-full (Rust-only): format, clippy, audit, deny, tests"
fmt:
cargo fmt
@echo "Formatted"
fmt-check:
cargo fmt --check
clippy:
cargo clippy -- -D warnings
audit:
cargo audit
outdated:
cargo outdated
deny:
cargo deny check advisories bans sources
test-parity-phase-a:
PARITY_PHASE=a cargo test pyspark_parity_fixtures
test-parity-phase-b:
PARITY_PHASE=b cargo test pyspark_parity_fixtures
test-parity-phase-c:
PARITY_PHASE=c cargo test pyspark_parity_fixtures
test-parity-phase-d:
PARITY_PHASE=d cargo test pyspark_parity_fixtures
test-parity-phase-e:
PARITY_PHASE=e cargo test pyspark_parity_fixtures
test-parity-phase-f:
PARITY_PHASE=f cargo test pyspark_parity_fixtures
test-parity-phase-g:
PARITY_PHASE=g cargo test pyspark_parity_fixtures
test-parity-phases:
cargo test pyspark_parity_fixtures
sparkless-parity:
@if [ -z "$$SPARKLESS_EXPECTED_OUTPUTS" ]; then \
echo "SPARKLESS_EXPECTED_OUTPUTS is not set; see docs/CONVERTER_STATUS.md"; \
exit 1; \
fi
python tests/convert_sparkless_fixtures.py --batch "$$SPARKLESS_EXPECTED_OUTPUTS" tests/fixtures --output-subdir converted --dedupe
python tests/regenerate_expected_from_pyspark.py tests/fixtures/converted
cargo test pyspark_parity_fixtures
all: check
@echo "All updates and checks complete"