Skip to content

Commit f49b1d7

Browse files
committed
feat(wasm-privacy-coin): support for merkle tree and java packaging
Ticket: CSHLD-1061
1 parent 1d5845f commit f49b1d7

26 files changed

Lines changed: 3473 additions & 1 deletion

.github/scripts/detect-changes.mjs

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -2,7 +2,7 @@
22
import { execSync } from 'child_process';
33
import { appendFileSync } from 'fs';
44

5-
const ALL_PACKAGES = ['wasm-bip32', 'wasm-mps', 'wasm-utxo', 'wasm-solana', 'wasm-dot', 'wasm-ton'];
5+
const ALL_PACKAGES = ['wasm-bip32', 'wasm-mps', 'wasm-utxo', 'wasm-solana', 'wasm-dot', 'wasm-ton', 'wasm-privacy-coin'];
66

77
function setOutput(packages) {
88
const value = JSON.stringify(packages);

.github/workflows/build-and-test.yaml

Lines changed: 42 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -64,6 +64,7 @@ jobs:
6464
packages/wasm-solana
6565
packages/wasm-dot
6666
packages/wasm-ton
67+
packages/wasm-privacy-coin
6768
cache-on-failure: true
6869

6970
- name: Setup Node
@@ -101,6 +102,23 @@ jobs:
101102
- name: Build packages
102103
run: npm --workspaces run build
103104

105+
- name: Setup JDK 17 (for wasm-privacy-coin JAR)
106+
uses: actions/setup-java@v4
107+
with:
108+
distribution: corretto
109+
java-version: "17"
110+
111+
- name: Cache Maven dependencies
112+
uses: actions/cache@v4
113+
with:
114+
path: ~/.m2/repository
115+
key: ${{ runner.os }}-maven-${{ hashFiles('packages/wasm-privacy-coin/pom.xml') }}
116+
restore-keys: ${{ runner.os }}-maven-
117+
118+
- name: Build wasm-privacy-coin JAR
119+
working-directory: packages/wasm-privacy-coin
120+
run: make jar
121+
104122
- name: Check Source Code Formatting
105123
run: npm run check-fmt
106124

@@ -121,6 +139,7 @@ jobs:
121139
packages/wasm-dot/js/wasm/
122140
packages/wasm-ton/dist/
123141
packages/wasm-ton/js/wasm/
142+
packages/wasm-privacy-coin/dist/
124143
retention-days: 1
125144

126145
- name: Upload webui artifact
@@ -156,6 +175,9 @@ jobs:
156175
- package: wasm-ton
157176
needs-wasm-pack: false
158177
has-wasm-pack-tests: false
178+
- package: wasm-privacy-coin
179+
needs-wasm-pack: false
180+
has-wasm-pack-tests: false
159181
steps:
160182
- uses: actions/checkout@v4
161183
with:
@@ -203,6 +225,26 @@ jobs:
203225
run: cargo test --workspace
204226
working-directory: packages/${{ matrix.package }}
205227

228+
- name: Cache Maven dependencies
229+
if: matrix.package == 'wasm-privacy-coin'
230+
uses: actions/cache@v4
231+
with:
232+
path: ~/.m2/repository
233+
key: ${{ runner.os }}-maven-${{ hashFiles('packages/wasm-privacy-coin/pom.xml') }}
234+
restore-keys: ${{ runner.os }}-maven-
235+
236+
- name: Setup JDK 17 (wasm-privacy-coin Java tests)
237+
if: matrix.package == 'wasm-privacy-coin'
238+
uses: actions/setup-java@v4
239+
with:
240+
distribution: corretto
241+
java-version: "17"
242+
243+
- name: Java Test
244+
if: matrix.package == 'wasm-privacy-coin'
245+
working-directory: packages/wasm-privacy-coin
246+
run: make test-java
247+
206248
- name: Wasm-Pack Test (Node)
207249
if: matrix.has-wasm-pack-tests
208250
run: npm run test:wasm-pack-node

package-lock.json

Lines changed: 8 additions & 0 deletions
Some generated files are not rendered by default. Learn more about customizing how changed files appear on GitHub.
Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,4 @@
1+
src/main/resources/wasm/
2+
target/
3+
dist/
4+
.flattened-pom.xml
Lines changed: 7 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,7 @@
1+
{
2+
"plugins": [
3+
"@semantic-release/commit-analyzer",
4+
"@semantic-release/release-notes-generator",
5+
["@semantic-release/github", { "failComment": false }]
6+
]
7+
}

0 commit comments

Comments
 (0)