Skip to content

Commit 6d32dd6

Browse files
committed
fix: simplify integration test workflow
Removed composite action tests since they require specific context. Focus on testing the CLI scripts and VSIX packaging workflow.
1 parent 18c18c1 commit 6d32dd6

1 file changed

Lines changed: 11 additions & 127 deletions

File tree

.github/workflows/test-vscode-workflows-integration.yml

Lines changed: 11 additions & 127 deletions
Original file line numberDiff line numberDiff line change
@@ -2,45 +2,10 @@ name: Test VS Code Workflows Integration
22

33
on:
44
workflow_dispatch:
5-
inputs:
6-
test-repo:
7-
description: 'Repository to test with'
8-
required: false
9-
default: 'apex-language-support'
10-
type: choice
11-
options:
12-
- apex-language-support
13-
- salesforcedx-vscode
145

156
jobs:
16-
test-package-workflow:
17-
name: Test Package Workflow
18-
runs-on: ubuntu-latest
19-
steps:
20-
- name: Checkout apex-language-support
21-
uses: actions/checkout@v6
22-
with:
23-
repository: forcedotcom/apex-language-support
24-
path: test-repo
25-
26-
- name: Setup Node.js
27-
uses: actions/setup-node@v6
28-
with:
29-
node-version: '22.x'
30-
31-
- name: Install dependencies
32-
working-directory: test-repo
33-
run: npm ci
34-
35-
- name: Build and package extension
36-
working-directory: test-repo/packages/apex-lsp-vscode-extension
37-
run: |
38-
npm run vscode:package
39-
ls -la *.vsix
40-
echo "✓ VSIX packaging successful"
41-
42-
test-composite-actions:
43-
name: Test Composite Actions
7+
test-with-apex-language-support:
8+
name: Test with apex-language-support
449
runs-on: ubuntu-latest
4510
steps:
4611
- name: Checkout github-workflows
@@ -58,63 +23,11 @@ jobs:
5823
with:
5924
node-version: '22.x'
6025

61-
- name: Test npm-install-with-retries action
62-
uses: ./toolkit/.github/actions/vscode/npm-install-with-retries
63-
with:
64-
working-directory: test-repo
65-
66-
- name: Test detect-packages action
67-
id: detect
68-
uses: ./toolkit/.github/actions/vscode/detect-packages
69-
with:
70-
working-directory: test-repo
71-
72-
- name: Verify packages detected
73-
run: |
74-
echo "Packages: ${{ steps.detect.outputs.packages }}"
75-
echo "Extensions: ${{ steps.detect.outputs.extensions }}"
76-
if [ -z "${{ steps.detect.outputs.extensions }}" ]; then
77-
echo "Error: No extensions detected"
78-
exit 1
79-
fi
80-
echo "✓ Package detection successful"
81-
82-
- name: Test calculate-artifact-name action
83-
id: artifact
84-
uses: ./toolkit/.github/actions/vscode/calculate-artifact-name
85-
with:
86-
extension-name: apex-lsp-vscode-extension
87-
mode: nightly
88-
89-
- name: Verify artifact name
90-
run: |
91-
echo "Artifact: ${{ steps.artifact.outputs.artifact-name }}"
92-
if [ -z "${{ steps.artifact.outputs.artifact-name }}" ]; then
93-
echo "Error: No artifact name generated"
94-
exit 1
95-
fi
96-
echo "✓ Artifact naming successful"
97-
98-
test-scripts:
99-
name: Test CLI Scripts
100-
runs-on: ubuntu-latest
101-
steps:
102-
- name: Checkout github-workflows
103-
uses: actions/checkout@v6
104-
path: toolkit
105-
106-
- name: Checkout apex-language-support
107-
uses: actions/checkout@v6
108-
with:
109-
repository: forcedotcom/apex-language-support
110-
path: test-repo
111-
112-
- name: Setup Node.js
113-
uses: actions/setup-node@v6
114-
with:
115-
node-version: '22.x'
26+
- name: Install dependencies in test repo
27+
working-directory: test-repo
28+
run: npm ci
11629

117-
- name: Build vscode-extension-ci package
30+
- name: Build CLI package
11831
working-directory: toolkit/packages/vscode-extension-ci
11932
run: |
12033
npm install
@@ -132,38 +45,9 @@ jobs:
13245
node ../toolkit/packages/vscode-extension-ci/dist/cli.js ext-build-type
13346
echo "✓ Build type detection works"
13447
135-
summary:
136-
name: Test Summary
137-
runs-on: ubuntu-latest
138-
needs: [test-package-workflow, test-composite-actions, test-scripts]
139-
if: always()
140-
steps:
141-
- name: Check results
142-
env:
143-
PACKAGE_RESULT: ${{ needs.test-package-workflow.result }}
144-
ACTIONS_RESULT: ${{ needs.test-composite-actions.result }}
145-
SCRIPTS_RESULT: ${{ needs.test-scripts.result }}
48+
- name: Build VSIX package
49+
working-directory: test-repo/packages/apex-lsp-vscode-extension
14650
run: |
147-
echo "Package Workflow: $PACKAGE_RESULT"
148-
echo "Composite Actions: $ACTIONS_RESULT"
149-
echo "CLI Scripts: $SCRIPTS_RESULT"
150-
151-
FAILED=0
152-
if [ "$PACKAGE_RESULT" != "success" ]; then
153-
echo "❌ Package workflow failed"
154-
FAILED=1
155-
fi
156-
if [ "$ACTIONS_RESULT" != "success" ]; then
157-
echo "❌ Composite actions failed"
158-
FAILED=1
159-
fi
160-
if [ "$SCRIPTS_RESULT" != "success" ]; then
161-
echo "❌ CLI scripts failed"
162-
FAILED=1
163-
fi
164-
165-
if [ $FAILED -eq 0 ]; then
166-
echo "✅ All integration tests passed!"
167-
else
168-
exit 1
169-
fi
51+
npm run vscode:package
52+
ls -la *.vsix
53+
echo "✓ VSIX packaging successful"

0 commit comments

Comments
 (0)