## Issue Addressed Which issue # does this PR address? #2629 ## Proposed Changes Please list or describe the changes introduced by this PR. 1. ci would dowload the bls test cases from https://github.com/ethereum/bls12-381-tests/ 2. all the bls test cases(except eth ones) would use cases in the archive from step one 3. The bls test cases from https://github.com/ethereum/consensus-spec-tests would stay there and no use . For the future , these bls test cases would be remove suggested from https://github.com/ethereum/consensus-spec-tests/issues/25 . So it would do no harm and compatible for future cases. ## Additional Info Please provide any additional information. For example, future considerations or information useful for reviewers. Question: I am not sure if I should implement tests about `deserialization_G1`, `deserialization_G2` and `hash_to_G2` for the issue.
43 lines
1.1 KiB
Makefile
43 lines
1.1 KiB
Makefile
TESTS_TAG := v1.2.0-rc.3
|
|
TESTS = general minimal mainnet
|
|
TARBALLS = $(patsubst %,%-$(TESTS_TAG).tar.gz,$(TESTS))
|
|
|
|
REPO_NAME := consensus-spec-tests
|
|
OUTPUT_DIR := ./$(REPO_NAME)
|
|
BASE_URL := https://github.com/ethereum/$(REPO_NAME)/releases/download/$(TESTS_TAG)
|
|
|
|
BLS_TEST_REPO_NAME := bls12-381-tests
|
|
BLS_TEST_TAG := v0.1.1
|
|
BLS_TEST = bls_tests_yaml
|
|
BLS_TARBALL = $(patsubst %,%-$(BLS_TEST_TAG).tar.gz,$(BLS_TEST))
|
|
BLS_OUTPUT_DIR := $(OUTPUT_DIR)/$(BLS_TEST_REPO_NAME)
|
|
BLS_BASE_URL := https://github.com/ethereum/$(BLS_TEST_REPO_NAME)/releases/download/$(BLS_TEST_TAG)
|
|
|
|
all:
|
|
make $(OUTPUT_DIR)
|
|
make $(BLS_OUTPUT_DIR)
|
|
|
|
$(OUTPUT_DIR): $(TARBALLS)
|
|
mkdir $(OUTPUT_DIR)
|
|
for test_tarball in $^; do \
|
|
tar -xzf $$test_tarball -C $(OUTPUT_DIR);\
|
|
done
|
|
|
|
$(BLS_OUTPUT_DIR):
|
|
mkdir $(BLS_OUTPUT_DIR)
|
|
wget $(BLS_BASE_URL)/$(BLS_TEST).tar.gz -O $(BLS_TARBALL)
|
|
tar -xzf $(BLS_TARBALL) -C $(BLS_OUTPUT_DIR)
|
|
|
|
%-$(TESTS_TAG).tar.gz:
|
|
wget $(BASE_URL)/$*.tar.gz -O $@
|
|
|
|
clean-test-files:
|
|
rm -rf $(OUTPUT_DIR) $(BLS_OUTPUT_DIR)
|
|
|
|
clean-archives:
|
|
rm -f $(TARBALLS) $(BLS_TARBALL)
|
|
|
|
clean: clean-test-files clean-archives
|
|
|
|
.PHONY: clean clean-archives clean-test-files
|