Skip to content

Commit

Permalink
Replace default off-chain engine with experimental one, remove old one
Browse files Browse the repository at this point in the history
  • Loading branch information
cmichi committed Feb 23, 2022
1 parent 2f86746 commit 7771516
Show file tree
Hide file tree
Showing 44 changed files with 418 additions and 4,533 deletions.
27 changes: 0 additions & 27 deletions .gitlab-ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -257,12 +257,6 @@ test:
- cargo test --verbose --all-features --no-fail-fast --workspace
- cargo test --verbose --all-features --no-fail-fast --workspace --doc

# Just needed as long as we have the `ink-experimental-engine` feature.
# We do not invoke `--all-features` here -- this would imply the feature
# `ink-experimental-engine`. So in order to still run the tests without the
# experimental engine feature we need this command.
- cargo test --verbose --features std --no-fail-fast --workspace

docs:
stage: workspace
<<: *docker-env
Expand Down Expand Up @@ -318,11 +312,6 @@ codecov:
# RUSTFLAGS are the cause target cache can't be used here
- cargo build --verbose --all-features --workspace
- cargo test --verbose --all-features --no-fail-fast --workspace
# Just needed as long as we have the `ink-experimental-engine` feature.
# We must additionally run the coverage without `--all-features` here -- this
# would imply the feature `ink-experimental-engine`. So in order to still run
# the tests without the experimental engine feature we need this command.
- cargo test --verbose --features std --no-fail-fast --workspace
# coverage with branches
- grcov . --binary-path ./target/debug/ --source-dir . --output-type lcov --llvm --branch
--ignore-not-existing --ignore "/*" --ignore "tests/*" --output-path lcov-w-branch.info
Expand Down Expand Up @@ -352,22 +341,6 @@ examples-test:
cargo test --verbose --manifest-path examples/delegator/${contract}/Cargo.toml;
done

examples-test-experimental-engine:
stage: examples
<<: *docker-env
<<: *test-refs
needs:
- job: clippy-std
artifacts: false
script:
# We test only the examples for which the tests have already been migrated to
# use the experimental engine.
- cargo test --no-default-features --features std, ink-experimental-engine --verbose --manifest-path examples/erc20/Cargo.toml
- cargo test --no-default-features --features std, ink-experimental-engine --verbose --manifest-path examples/erc1155/Cargo.toml
- cargo test --no-default-features --features std, ink-experimental-engine --verbose --manifest-path examples/contract-terminate/Cargo.toml
- cargo test --no-default-features --features std, ink-experimental-engine --verbose --manifest-path examples/contract-transfer/Cargo.toml


examples-contract-build:
stage: examples
<<: *docker-env
Expand Down
2 changes: 1 addition & 1 deletion crates/engine/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -9,7 +9,7 @@ readme = "README.md"
repository = "https://github.com/paritytech/ink"
documentation = "https://docs.rs/ink_engine/"
homepage = "https://www.parity.io/"
description = "[ink!] Experimental off-chain environment for testing."
description = "[ink!] Off-chain environment for testing."
keywords = ["wasm", "parity", "webassembly", "blockchain", "edsl"]
categories = ["no-std", "embedded"]
include = ["Cargo.toml", "src/**/*.rs", "README.md", "LICENSE"]
Expand Down
2 changes: 1 addition & 1 deletion crates/env/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -56,6 +56,7 @@ std = [
"ink_allocator/std",
"ink_prelude/std",
"ink_primitives/std",
"ink_engine/std",
"scale/std",
"scale-info/std",
"secp256k1",
Expand All @@ -69,5 +70,4 @@ std = [
]
# Enable contract debug messages via `debug_print!` and `debug_println!`.
ink-debug = []
ink-experimental-engine = ["ink_engine"]
wee-alloc = ["ink_allocator/wee-alloc"]
6 changes: 0 additions & 6 deletions crates/env/src/backend.rs
Original file line number Diff line number Diff line change
Expand Up @@ -44,12 +44,6 @@ impl ReturnFlags {
}
self
}

/// Returns the underlying `u32` representation.
#[cfg(not(feature = "ink-experimental-engine"))]
pub(crate) fn into_u32(self) -> u32 {
self.value
}
}

/// The flags used to change the behavior of a contract call.
Expand Down
Loading

0 comments on commit 7771516

Please sign in to comment.