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

Move IDE tests into it's own workflow file #20019

Merged
merged 6 commits into from
Oct 24, 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/e2e.yml
Original file line number Diff line number Diff line change
Expand Up @@ -70,7 +70,7 @@ jobs:
if: ${{ needs.diff.outputs.isTypescriptSDK == 'true' || needs.diff.outputs.isRust == 'true'}}
run: pnpm dlx concurrently --kill-others --success command-1 "$E2E_RUN_LOCAL_NET_CMD" 'pnpm --filter @mysten/sui test:e2e'

- name: Run RPC/GrpahQL comaptability e2e tests
- name: Run RPC/GraphQL compatibility e2e tests
if: ${{ needs.diff.outputs.isGraphQlTransport == 'true' || needs.diff.outputs.isRust == 'true' }}
run: pnpm dlx concurrently --kill-others --success command-1 "$E2E_RUN_LOCAL_NET_CMD" 'pnpm --filter @mysten/graphql-transport test:e2e'

Expand Down
91 changes: 91 additions & 0 deletions .github/workflows/ide-tests.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,91 @@
name: IDE Tests

on:
push:
branches: main
pull_request:
types: [ opened, synchronize, reopened, ready_for_review ]
workflow_dispatch:
inputs:
sui_repo_ref:
description: "Branch / commit to test"
type: string
required: false
default: ''

jobs:
diff:
runs-on: [ubuntu-latest]
outputs:
isMoveAutoFormatter: ${{ steps.diff.outputs.isMoveAutoFormatter }}
isMoveAnalyzerTraceAdapter: ${{ steps.diff.outputs.isMoveAnalyzerTraceAdapter }}
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # Pin v4.1.1
- name: Detect Changes
uses: './.github/actions/diffs'
id: diff

move-auto-formatter-ci-test:
name: Move Auto-formatter Test
needs: diff
if: needs.diff.outputs.isMoveAutoFormatter == 'true'
runs-on: [ ubuntu-latest ]

steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # Pin v4.1.1
with:
ref: ${{ github.event.inputs.sui_repo_ref || github.ref }}

- name: pnpm setup
uses: pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d # [email protected]
with:
version: 9.1.1

- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # [email protected]
with:
node-version: '20'
cache: 'pnpm'

- name: Install dependencies
working-directory: ./external-crates/move/crates/move-analyzer/prettier-plugin
run: npm install && npm i web-tree-sitter

- name: Run npm test
working-directory: ./external-crates/move/crates/move-analyzer/prettier-plugin
shell: bash
run: npm run test

move-analyzer-trace-adapter-ci-test:
name: Trace Adapter Test
needs: diff
if: needs.diff.outputs.isMoveAnalyzerTraceAdapter == 'true'
runs-on: [ ubuntu-latest ]

steps:
- name: Checkout
uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # Pin v4.1.1
with:
ref: ${{ github.event.inputs.sui_repo_ref || github.ref }}

- name: pnpm setup
uses: pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d # [email protected]
with:
version: 9.1.1

- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # [email protected]
with:
node-version: '20'
cache: 'pnpm'

- name: Install dependencies
working-directory: ./external-crates/move/crates/move-analyzer/trace-adapter
shell: bash
run: npm install

- name: Run npm test
working-directory: ./external-crates/move/crates/move-analyzer/trace-adapter
shell: bash
run: npm run test
62 changes: 0 additions & 62 deletions .github/workflows/rust.yml
Original file line number Diff line number Diff line change
Expand Up @@ -55,8 +55,6 @@ jobs:
outputs:
isRust: ${{ steps.diff.outputs.isRust }}
isMove: ${{ steps.diff.outputs.isMove }}
isMoveAutoFormatter: ${{ steps.diff.outputs.isMoveAutoFormatter }}
isMoveAnalyzerTraceAdapter: ${{ steps.diff.outputs.isMoveAnalyzerTraceAdapter }}
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # Pin v4.1.1
with:
Expand All @@ -74,66 +72,6 @@ jobs:
ref: ${{ github.event.inputs.sui_repo_ref || github.ref }}
- run: cargo xlint

move-auto-formatter-ci-test:
needs: diff
if: needs.diff.outputs.isMoveAutoFormatter == 'true'
runs-on: [ ubuntu-latest ]
strategy:
matrix:
node-version: [ 20 ]
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # Pin v4.1.1
with:
ref: ${{ github.event.inputs.sui_repo_ref || github.ref }}
- uses: pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d # [email protected]
with:
version: 9.1.1
- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # [email protected]
with:
node-version: '20.x'
cache: 'pnpm'
- name: Install dependencies
working-directory: ./external-crates/move/crates/move-analyzer/prettier-plugin
run: npm install && npm i web-tree-sitter
- name: Run npm test
working-directory: ./external-crates/move/crates/move-analyzer/prettier-plugin
shell: bash
run: npm run test

move-analyzer-trace-adapter-ci-test:
name: Move Analyzer Trace Adapter Test
needs: diff
if: needs.diff.outputs.isMoveAnalyzerTraceAdapter == 'true'
runs-on: [ ubuntu-latest ]
strategy:
matrix:
node-version: [ 20 ]
steps:
- uses: actions/checkout@b4ffde65f46336ab88eb53be808477a3936bae11 # Pin v4.1.1
with:
ref: ${{ github.event.inputs.sui_repo_ref || github.ref }}

- uses: pnpm/action-setup@a3252b78c470c02df07e9d59298aecedc3ccdd6d # [email protected]
with:
version: 9.1.1

- name: Setup Node
uses: actions/setup-node@60edb5dd545a775178f52524783378180af0d1f8 # [email protected]
with:
node-version: '20.x'
cache: 'pnpm'

- name: Install dependencies
working-directory: ./external-crates/move/crates/move-analyzer/trace-adapter
shell: bash
run: npm install

- name: Run npm test
working-directory: ./external-crates/move/crates/move-analyzer/trace-adapter
shell: bash
run: npm run test

test:
needs: diff
if: needs.diff.outputs.isRust == 'true'
Expand Down
Loading