From d49cd5a4dda82a6830cb7a06e0ccc545501aa40f Mon Sep 17 00:00:00 2001 From: Greg Zaitsev Date: Tue, 22 Dec 2020 11:15:29 +0000 Subject: [PATCH] Update build steps in README and cleanup --- --- a/README.md +++ b/README.md @@ -52,28 +52,27 @@ 2. Remove all installed toolchains with `rustup toolchain list` and `rustup toolchain uninstall `. -3. Install Rust Toolchain 1.44.0: +3. Install Toolchain and make it default: ```bash -rustup install 1.44.0 +rustup toolchain install nightly-2020-10-01 +rustup default nightly-2020-10-01 ``` -4. Make it default (actual toochain version may be different, so do a `rustup toolchain list` first) +4. Add wasm target for default toolchain: + ```bash -rustup toolchain list -rustup default 1.44.0-x86_64-unknown-linux-gnu +rustup target add wasm32-unknown-unknown ``` -5. Install nightly toolchain and add wasm target for it: - +5. Build: ```bash -rustup toolchain install nightly-2020-05-01 -rustup target add wasm32-unknown-unknown --toolchain nightly-2020-05-01-x86_64-unknown-linux-gnu +cargo build ``` -6. Build: +optionally, build in release: ```bash -cargo build +cargo build --release ``` ## Run @@ -134,4 +133,8 @@ ## UI custom types -Moved to [runtime_types.json](./runtime_types.json). \ No newline at end of file +Moved to [runtime_types.json](./runtime_types.json). + +## Running Integration Tests + +See [tests/README.md](./tests/README.md). \ No newline at end of file --- a/tests/README +++ /dev/null @@ -1,12 +0,0 @@ -# Tests - -## How to run - -1. Run `npm install`. -2. Setup a test node. You can do it using `docker-compose up -d` in parent directory. -3. Configure tests with env variables or by editing [configuration file](src/config.ts). -4. Run `npm run test`. - -## Don't run on the same node twice - -Some tests fail when ran on the same blockchain node twice. Either always use a new node or purge the existing one with `nft purge-chain --dev`. There is also [a script](../purge-running-node.sh) to purge and restart a node, started with docker-compose. --- /dev/null +++ b/tests/README.md @@ -0,0 +1,9 @@ +# Tests + +## How to run + +1. Run `npm install`. +2. Setup a test node. You can do it using `docker-compose up -d` in parent directory. +3. Optional step - configure tests with env variables or by editing [configuration file](src/config.ts). +4. Run `npm test`. + -- gitstuff