Skip to content

Commit e9cfddc

Browse files
Merge branch 'main' into feat/database-integration-upgrade-metadata-thirdparty
2 parents 0d727bd + ed6eebf commit e9cfddc

13 files changed

Lines changed: 1939 additions & 22 deletions

File tree

.github/workflows/test.yml

Lines changed: 52 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -6,13 +6,17 @@ on:
66
paths:
77
- 'contracts/lib/**'
88
- 'contracts/traits/**'
9+
- 'contracts/governance/**'
10+
- 'contracts/staking/**'
911
- 'Cargo.toml'
1012
- 'Cargo.lock'
1113
pull_request:
1214
branches: [ main, develop, master ]
1315
paths:
1416
- 'contracts/lib/**'
1517
- 'contracts/traits/**'
18+
- 'contracts/governance/**'
19+
- 'contracts/staking/**'
1620
- 'Cargo.toml'
1721
- 'Cargo.lock'
1822
workflow_dispatch:
@@ -44,3 +48,51 @@ jobs:
4448
- name: Run PropertyRegistry unit tests
4549
working-directory: contracts/lib
4650
run: cargo test --lib
51+
52+
governance-tests:
53+
name: Governance Unit Tests
54+
runs-on: ubuntu-latest
55+
steps:
56+
- uses: actions/checkout@v4
57+
58+
- uses: dtolnay/rust-toolchain@stable
59+
60+
- uses: actions/cache@v4
61+
with:
62+
path: |
63+
~/.cargo/bin/
64+
~/.cargo/registry/index/
65+
~/.cargo/registry/cache/
66+
~/.cargo/git/db/
67+
target/
68+
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
69+
restore-keys: |
70+
${{ runner.os }}-cargo-
71+
72+
- name: Run Governance unit tests
73+
working-directory: contracts/governance
74+
run: cargo test --lib
75+
76+
staking-tests:
77+
name: Staking Unit Tests
78+
runs-on: ubuntu-latest
79+
steps:
80+
- uses: actions/checkout@v4
81+
82+
- uses: dtolnay/rust-toolchain@stable
83+
84+
- uses: actions/cache@v4
85+
with:
86+
path: |
87+
~/.cargo/bin/
88+
~/.cargo/registry/index/
89+
~/.cargo/registry/cache/
90+
~/.cargo/git/db/
91+
target/
92+
key: ${{ runner.os }}-cargo-${{ hashFiles('**/Cargo.lock') }}
93+
restore-keys: |
94+
${{ runner.os }}-cargo-
95+
96+
- name: Run Staking unit tests
97+
working-directory: contracts/staking
98+
run: cargo test --lib

Cargo.lock

Lines changed: 20 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.

contracts/governance/Cargo.toml

Lines changed: 28 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,28 @@
1+
[package]
2+
name = "governance"
3+
version = "0.1.0"
4+
edition = "2021"
5+
authors = ["PropChain Team <dev@propchain.io>"]
6+
license = "MIT"
7+
publish = false
8+
9+
[lib]
10+
name = "governance"
11+
path = "src/lib.rs"
12+
crate-type = ["cdylib", "rlib"]
13+
14+
[dependencies]
15+
ink = { version = "5.0.0", default-features = false }
16+
scale = { package = "parity-scale-codec", version = "3.6.9", default-features = false, features = ["derive"] }
17+
scale-info = { version = "2.10.0", default-features = false, features = ["derive"] }
18+
propchain_traits = { package = "propchain-traits", path = "../traits", default-features = false }
19+
20+
[features]
21+
default = ["std"]
22+
std = [
23+
"ink/std",
24+
"scale/std",
25+
"scale-info/std",
26+
"propchain_traits/std",
27+
]
28+
ink-as-dependency = []

0 commit comments

Comments
 (0)