summary refs log tree commit diff
path: root/src/test/run-make/libtest-json/Makefile
blob: ec91ddfb9f917d85e2efd26bd22b9adff36ebb1d (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
-include ../tools.mk

# Test expected libtest's JSON output

OUTPUT_FILE := $(TMPDIR)/libtest-json-output.json

all:
	$(RUSTC) --test f.rs
	$(call RUN,f) -Z unstable-options --test-threads=1 --format=json > $(OUTPUT_FILE) || true

	cat $(OUTPUT_FILE) | "$(PYTHON)" validate_json.py

	# Compare to output file
	diff output.json $(OUTPUT_FILE)