Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

readme #140

Merged
merged 3 commits into from
Dec 20, 2022
Merged
Show file tree
Hide file tree
Changes from 2 commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
15 changes: 5 additions & 10 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -5,23 +5,18 @@
</p>

# Local Money P2P marketplace

Welcome to Local Money, Decentralized P2P marketplace for Interchain & IBC assets.

## App

[see more](app/README.md)

## Contracts
## Tests
[see more](app/tests/README.md)

## Contracts
[see more](contracts/README.md)

## Integration Tests

[see more](integration-tests/README.md)

## Testsuite

[see more](testsuite/README.md)
## Deploy
[see more](deploy/README.md)

#### License: [GPL V3.0](LICENSE)
28 changes: 28 additions & 0 deletions app/tests/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
# Local Money Testsuite
The Testsuite is a set of tests that are used to verify the proper functioning of the protocol. It involves instantiating the protocol and running integration tests.
### Commands

To run all tests:
```bash
yarn test
```

To only instantiate the protocol:
```bash
yarn test -t 'setup protocol'
```

To setup fees configurations:
```bash
yarn test -t 'fees'
```

To pre-populate the price contract, you can run this code:
```bash
yarn test -t 'price test'
```

You can also combine all this tests using `|` between each code, example:
```bash
yarn test -t 'setup protocol|fees|price test'
```
14 changes: 13 additions & 1 deletion contracts/README.md
Original file line number Diff line number Diff line change
@@ -1,3 +1,15 @@
# Local Money Smart Contracts
All the contracts from the LocalMoney protocol.

### Commands

To build the protocol, you will need to use a specific version of cargo: `cargo 1.67.0-nightly (16b097879 2022-11-14)`. This version of cargo is necessary to ensure that the protocol is built correctly.
```bash
cargo +nightly build
```

To compile the protocol, you will need to have Docker installed on your computer. Once Docker is installed, you can use the script in the `/contracts` directory to generate `.wasm` files in the `/contracts/artifacts` path.
```bash
sh optimize.sh
```

CosmWasm Smart Contracts for Local Money P2P Marketplace.
36 changes: 10 additions & 26 deletions deploy/README.md
Original file line number Diff line number Diff line change
@@ -1,35 +1,19 @@
# Local Money Protocol Integration Tests
# Local Money Deploy

Integration tests that calls Contracts using LCD.
These scripts allow you to upload the `.wasm` files after they have been compiled.

# Instructions

Run `yarn install` and then `node index.js` with the desired env vars as described below.

On the 1st run, you must run it with `DEPLOY=all` to upload all the contracts to the chain and generate the code ids for the contracts.

# ENV Variables

**DEPLOY**: name of contract (name of the wasm file without the extension) or `all` to upload all the contracts.

**CONTRACTS**: the folder with the optmized wasm files.

**FACTORY**: factory address, if Factory is already instantiated you can pass its address on this parameter to skip the deployment process.

# Examples
### Commands

To upload all wasm compiled you can run:
```bash
npm run bombay:all
yarn deploy:all

# expands to
#expands

DEPLOY=all CONTRACTS=../localterra-contracts/artifacts ./node_modules/node/bin/node index.js
DEPLOY=all CONTRACTS=../contracts/artifacts ./node_modules/node/bin/node index.js
```

To upload only one wasm compiled you can run:
```bash
npm run terrarium:all

# expands to

DEPLOY=all NETWORK=localterra CW20ID=1 CONTRACTS=../localterra-contracts/artifacts ./node_modules/node/bin/node index.js
```
DEPLOY={CONTRACT_NAME} CONTRACTS=../contracts/artifacts ./node_modules/node/bin/node index.js
```