Skip to content
This repository has been archived by the owner on Nov 15, 2023. It is now read-only.

Commit

Permalink
Merge branch 'master' into impl-public
Browse files Browse the repository at this point in the history
  • Loading branch information
gavofyork authored Nov 12, 2019
2 parents 1ecde51 + 6d00431 commit 722f3fe
Show file tree
Hide file tree
Showing 395 changed files with 15,653 additions and 7,501 deletions.
2 changes: 1 addition & 1 deletion .editorconfig
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ tab_width=4
end_of_line=lf
charset=utf-8
trim_trailing_whitespace=true
max_line_length=120
max_line_length=100
insert_final_newline=true

[*.yml]
Expand Down
80 changes: 70 additions & 10 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ variables:
- /^[0-9]+$/ # PRs
retry:
max: 2
when:
when:
- runner_system_failure
- unknown_failure
- api_failure
Expand Down Expand Up @@ -133,7 +133,7 @@ test-linux-stable: &test-linux
variables:
- $DEPLOY_TAG
script:
- time cargo test --all --release --verbose --locked |
- WASM_BUILD_NO_COLOR=1 time cargo test --all --release --verbose --locked |
tee output.log
- sccache -s
after_script:
Expand All @@ -159,13 +159,24 @@ test-srml-staking: &test-srml-staking
- $DEPLOY_TAG
script:
- cd srml/staking/
- time cargo test --release --verbose --no-default-features --features std
- WASM_BUILD_NO_COLOR=1 time cargo test --release --verbose --no-default-features --features std
- sccache -s





test-wasmtime: &test-wasmtime
stage: test
<<: *docker-env
variables:
# Enable debug assertions since we are running optimized builds for testing
# but still want to have debug assertions.
RUSTFLAGS: -Cdebug-assertions=y
RUST_BACKTRACE: 1
except:
variables:
- $DEPLOY_TAG
script:
- cd core/executor
- WASM_BUILD_NO_COLOR=1 time cargo test --release --verbose --features wasmtime
- sccache -s

test-linux-stable-int:
<<: *test-linux
Expand All @@ -177,7 +188,7 @@ test-linux-stable-int:
script:
- echo "___Logs will be partly shown at the end in case of failure.___"
- echo "___Full log will be saved to the job artifacts only in case of failure.___"
- RUST_LOG=sync=trace,consensus=trace,client=trace,state-db=trace,db=trace,forks=trace,state_db=trace,storage_cache=trace
- WASM_BUILD_NO_COLOR=1 RUST_LOG=sync=trace,consensus=trace,client=trace,state-db=trace,db=trace,forks=trace,state_db=trace,storage_cache=trace
time cargo test -p node-cli --release --verbose --locked -- --ignored --test-threads=1
&> ${CI_COMMIT_SHORT_SHA}_int_failure.log
- sccache -s
Expand Down Expand Up @@ -219,6 +230,26 @@ node-exits:
script:
- ./ci/check_for_exit.sh


test-full-crypto-feature: &test-full-crypto-feature
stage: test
<<: *docker-env
variables:
# Enable debug assertions since we are running optimized builds for testing
# but still want to have debug assertions.
RUSTFLAGS: -Cdebug-assertions=y
RUST_BACKTRACE: 1
except:
variables:
- $DEPLOY_TAG
script:
- cd core/primitives/
- time cargo +nightly build --verbose --no-default-features --features full_crypto
- cd ../application-crypto
- time cargo +nightly build --verbose --no-default-features --features full_crypto
- sccache -s


#### stage: build

build-linux-substrate:
Expand All @@ -230,7 +261,7 @@ build-linux-substrate:
variables:
- $DEPLOY_TAG
script:
- time cargo build --release --verbose
- WASM_BUILD_NO_COLOR=1 time cargo build --release --verbose
- mkdir -p ./artifacts/substrate/
- mv ./target/release/substrate ./artifacts/substrate/.
- echo -n "Substrate version = "
Expand Down Expand Up @@ -258,7 +289,7 @@ build-linux-subkey:
script:
- cd ./subkey
- BUILD_DUMMY_WASM_BINARY=1 time cargo build --release --verbose
- cd ..
- cd -
- sccache -s
- mkdir -p ./artifacts/subkey
- mv ./target/release/subkey ./artifacts/subkey/.
Expand Down Expand Up @@ -307,6 +338,35 @@ check_warnings:
fi
allow_failure: true

# Check whether Polkadot 'master' branch builds using this Substrate commit.
check_polkadot:
stage: build
<<: *docker-env
allow_failure: true
dependencies:
- test-linux-stable
script:
- COMMIT_HASH=$(git rev-parse HEAD)
- SUBSTRATE_PATH=$(pwd)
# Clone the current Polkadot master branch into ./polkadot.
- git clone --depth 1 https://gitlab.parity.io/parity/polkadot.git
- cd polkadot
# Within Polkadot 'master' alter each Cargo.toml that references the
# Substrate 'polkadot-master' branch:
# 1. Replace the 'branch = "polkadot-master"' statements with the rev of our
# commit.
# 2. Replace 'git = "https://.*"' with 'git = "file://.*"' (the local
# checked out Substrate repository one folder above).
# 3. Remove any trailing commas.
- git grep -l "polkadot-master" | grep toml | xargs sed -i "s/branch.*=.*\"polkadot-master\"/rev = \"$COMMIT_HASH\"/; s~https://github.com/paritytech/substrate~file://$SUBSTRATE_PATH~; s/,\s*}/ }/"
# Make sure 'Cargo.lock' matches 'Cargo.toml'. It's enough to update one
# package, others are updated along the way.
- cargo update -p sr-io
# Check whether Polkadot 'master' branch builds with this Substrate commit.
- time cargo check
- cd -
- sccache -s

#### stage: publish

.publish-docker-release: &publish-docker-release
Expand Down
Loading

0 comments on commit 722f3fe

Please sign in to comment.