CI: LFS support for the beacon-chain tests

- Travis: switch language
- AppVeyor: disable `mingw32-make go-checks` for now
- `make update`: export GIT_LFS_SKIP_SMUDGE=1
- CI: disable the LFS script inside Makefile,
  since we run it separately (and git-lfs is not installed in the Travis
  macOS image if we found a valid cache).
This commit is contained in:
Ștefan Talpalaru 2019-08-14 20:43:02 +02:00
parent a0d1c2718a
commit 33494634aa
No known key found for this signature in database
GPG Key ID: CBF7934204F1B6F9
4 changed files with 18 additions and 8 deletions

View File

@ -9,6 +9,7 @@ environment:
cache: cache:
- NimBinaries - NimBinaries
- jsonTestsCache
matrix: matrix:
# We always want 32-bit and 64-bit compilation # We always want 32-bit and 64-bit compilation
@ -27,7 +28,7 @@ install:
- IF "%PLATFORM%" == "x64" SET PATH=C:\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\bin;%PATH% - IF "%PLATFORM%" == "x64" SET PATH=C:\mingw-w64\x86_64-8.1.0-posix-seh-rt_v6-rev0\mingw64\bin;%PATH%
build_script: build_script:
- cd C:\projects\%APPVEYOR_PROJECT_SLUG% #- cd C:\projects\%APPVEYOR_PROJECT_SLUG%
# the 32-bit build is done on a 64-bit image, so we need to override the architecture # the 32-bit build is done on a 64-bit image, so we need to override the architecture
- mingw32-make -j2 ARCH_OVERRIDE=%PLATFORM% CI_CACHE=NimBinaries update - mingw32-make -j2 ARCH_OVERRIDE=%PLATFORM% CI_CACHE=NimBinaries update
- mingw32-make -j2 ARCH_OVERRIDE=%PLATFORM% fetch-dlls - mingw32-make -j2 ARCH_OVERRIDE=%PLATFORM% fetch-dlls
@ -38,8 +39,10 @@ test_script:
- build\nimbus.exe --help - build\nimbus.exe --help
- mingw32-make -j2 ARCH_OVERRIDE=%PLATFORM% test - mingw32-make -j2 ARCH_OVERRIDE=%PLATFORM% test
- IF "%PLATFORM%" == "x64" mingw32-make -j2 test-reproducibility - IF "%PLATFORM%" == "x64" mingw32-make -j2 test-reproducibility
- mingw32-make -C vendor/nim-beacon-chain -j2 test # LFS test fixtures
- mingw32-make go-checks - cd vendor\nim-beacon-chain & bash scripts\process_lfs.sh ..\..\jsonTestsCache & cd ..\..
- mingw32-make -C vendor/nim-beacon-chain DISABLE_LFS_SCRIPT=1 -j2 test
#- mingw32-make go-checks
deploy: off deploy: off

View File

@ -1,10 +1,11 @@
language: c language: go
# https://docs.travis-ci.com/user/caching/ # https://docs.travis-ci.com/user/caching/
cache: cache:
directories: directories:
- rocksdbCache - rocksdbCache
- vendor/Nim/bin - vendor/Nim/bin
- jsonTestsCache
git: git:
# when multiple CI builds are queued, the tested commit needs to be in the last X commits cloned with "--depth X" # when multiple CI builds are queued, the tested commit needs to be in the last X commits cloned with "--depth X"
@ -12,6 +13,9 @@ git:
# disable LFS file downloading during regular cloning # disable LFS file downloading during regular cloning
lfs_skip_smudge: true lfs_skip_smudge: true
go:
- "1.12.x"
matrix: matrix:
include: include:
- os: linux - os: linux
@ -26,11 +30,14 @@ install:
# build our own rocksdb to test with a fixed version that we think works # build our own rocksdb to test with a fixed version that we think works
- ./build_rocksdb.sh rocksdbCache - ./build_rocksdb.sh rocksdbCache
# LFS test fixtures
- cd vendor/nim-beacon-chain; scripts/process_lfs.sh ../../jsonTestsCache; cd ../..
script: script:
- set -e # fail fast - set -e # fail fast
- make -j2 - make -j2
- ./build/nimbus --help - ./build/nimbus --help
- make -j2 test test-reproducibility - make -j2 test test-reproducibility
- make -C vendor/nim-beacon-chain -j2 test - make -C vendor/nim-beacon-chain DISABLE_LFS_SCRIPT=1 -j2 test
- make go-checks - make go-checks

View File

@ -160,7 +160,7 @@ build-nim: | sanity-checks
"$(CURDIR)/build_nim.sh" "$(NIM_DIR)" ../Nim-csources ../nimble "$(CI_CACHE)" "$(CURDIR)/build_nim.sh" "$(NIM_DIR)" ../Nim-csources ../nimble "$(CI_CACHE)"
#- in case of submodule URL changes, it propagates that change in the parent repo's .git directory #- in case of submodule URL changes, it propagates that change in the parent repo's .git directory
#- initialises and updates the Git submodules #- initialises and updates the Git submodules, avoiding automated LFS downloads
#- manages the AppVeyor cache of Nim compiler binaries #- manages the AppVeyor cache of Nim compiler binaries
#- deletes the ".nimble" dir to force the execution of the "deps" target #- deletes the ".nimble" dir to force the execution of the "deps" target
#- deletes and recreates "nimbus.nims" which on Windows is a copy instead of a proper symlink #- deletes and recreates "nimbus.nims" which on Windows is a copy instead of a proper symlink
@ -168,7 +168,7 @@ build-nim: | sanity-checks
#- rebuilds the Nim compiler if the corresponding submodule is updated #- rebuilds the Nim compiler if the corresponding submodule is updated
$(NIM_BINARY) update: | sanity-checks $(NIM_BINARY) update: | sanity-checks
git submodule sync --quiet --recursive git submodule sync --quiet --recursive
git submodule update --init --recursive export GIT_LFS_SKIP_SMUDGE=1; git submodule update --init --recursive
rm -rf $(NIMBLE_DIR) nimbus.nims && \ rm -rf $(NIMBLE_DIR) nimbus.nims && \
$(MAKE) nimbus.nims $(MAKE) nimbus.nims
+ $(MAKE) build-nim + $(MAKE) build-nim

@ -1 +1 @@
Subproject commit 4daeebbf7e1ce1e86a1acad73714ab24a2747223 Subproject commit 6a4d27f4ac46b2b3f86b82f2bf56f97da6290007