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

[CI] Add workflow for quasar-types #670

Merged
merged 2 commits into from
Jul 18, 2024
Merged
Show file tree
Hide file tree
Changes from all 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
2 changes: 1 addition & 1 deletion .github/workflows/cl_vault.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
contract: 'cl-vault'
target: 'contracts/cl-vault'
test-tube:
uses: ./.github/workflows/rust_test_tube.yml
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/dex_router_osmosis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
contract: 'dex-router-osmosis'
target: 'contracts/dex-router-osmosis'
test-tube:
uses: ./.github/workflows/rust_test_tube.yml
with:
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/lst_adapter_osmosis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
contract: 'lst-adapter-osmosis'
target: 'contract/lst-adapter-osmosis'
2 changes: 1 addition & 1 deletion .github/workflows/lst_dex_adapter_osmosis.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
contract: 'lst-dex-adapter-osmosis'
target: 'contract/lst-dex-adapter-osmosis'
2 changes: 1 addition & 1 deletion .github/workflows/merkle_incentives.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,7 +15,7 @@ jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
contract: 'merkle-incentives'
target: 'contract/merkle-incentives'
test-tube:
uses: ./.github/workflows/rust_test_tube.yml
with:
Expand Down
18 changes: 18 additions & 0 deletions .github/workflows/quasar_types.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Test quasar-types

on:
pull_request:
branches:
- main
paths:
- 'smart-contracts/packages/quasar-types/**'
push:
branches:
- main
workflow_dispatch:

jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
target: 'packages/quasar-types'
2 changes: 1 addition & 1 deletion .github/workflows/range_middleware.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
contract: 'range-middleware'
target: 'contract/range-middleware'
8 changes: 4 additions & 4 deletions .github/workflows/rust_basic.yml
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,7 @@ name: Unit Test (rust)
on:
workflow_call:
inputs:
contract:
target:
required: true
type: string

Expand Down Expand Up @@ -35,12 +35,12 @@ jobs:
- name: Rust lint
if: env.GIT_DIFF
run: RUSTFLAGS="-Dwarnings" cargo clippy --workspace -- -D warnings --A deprecated
working-directory: smart-contracts/contracts/${{ inputs.contract }}
working-directory: smart-contracts/${{ inputs.target }}
- name: Rust format check
if: env.GIT_DIFF
run: cargo fmt --all -- --check
working-directory: smart-contracts/contracts/${{ inputs.contract }}
working-directory: smart-contracts/${{ inputs.target }}
- name: Run unit-tests
if: env.GIT_DIFF
run: cargo unit-test
working-directory: smart-contracts/contracts/${{ inputs.contract }}
working-directory: smart-contracts/${{ inputs.target }}
2 changes: 1 addition & 1 deletion .github/workflows/token_burner.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,4 +15,4 @@ jobs:
unit-test:
uses: ./.github/workflows/rust_basic.yml
with:
contract: 'token-burner'
target: 'contract/token-burner'
12 changes: 0 additions & 12 deletions smart-contracts/packages/quasar-types/CHANGELOG.md

This file was deleted.

3 changes: 2 additions & 1 deletion smart-contracts/packages/quasar-types/Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -19,9 +19,10 @@ cw20 = { workspace = true }
cosmos-sdk-proto = { workspace = true }
serde-json-wasm = { workspace = true }
serde_json = { workspace = true }

derive_more = {version = "0.99.17", default-features = false, features = [
"display",
]}
rust_decimal = "1.24.0"

[dev-dependencies]
serde_test = "1.0"
Loading