Skip to content

Commit 3c264c5

Browse files
authored
fix(action-builder): version bump for action builder (#422)
## Describe your changes ## Issue ticket number and link ## Checklist before requesting a review (skip if just adding/editing APIs & templates) - [ ] I added tests, otherwise the reason is: - [ ] External API requests have `retries` - [ ] Pagination is used where appropriate - [ ] The built in `nango.paginate` call is used instead of a `while (true)` loop - [ ] Third party requests are NOT parallelized (this can cause issues with rate limits) - [ ] If a sync requires metadata the `nango.yaml` has `auto_start: false` - [ ] If the sync is a `full` sync then `track_deletes: true` is set - [ ] I followed the best practices and guidelines from the [Writing Integration Scripts](/NangoHQ/integration-templates/blob/main/guides/WRITING_SCRIPTS.md) doc
1 parent 0c9611d commit 3c264c5

File tree

13 files changed

+1955
-1028
lines changed

13 files changed

+1955
-1028
lines changed

.claude/commands/build-actions.md

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -149,12 +149,14 @@ Example output.json:
149149

150150
### RED - Generate Failing Test
151151

152-
**CRITICAL: Use `npx nango generate:tests` to create tests automatically.**
152+
**CRITICAL: Use `npx nango generate:tests` with specific flags to create tests for only the action you're building.**
153153

154154
```bash
155-
npx nango generate:tests
155+
npx nango generate:tests -i {integrationId} -a <action-name>
156156
```
157157

158+
This generates a test for only the specified action, avoiding regeneration of all tests.
159+
158160
**VERIFY the test file was created:**
159161
```bash
160162
ls -la {integrationId}/tests/{integrationId}-<action-name>.test.ts
@@ -359,7 +361,7 @@ The dryrun creates a mock with hash based on headers like `Nango-Is-Script`. Tes
359361
**Per action:**
360362
- [ ] **Old/unused mocks cleaned up** (if changing endpoint or implementation)
361363
- [ ] Mock files created (input.json, output.json)
362-
- [ ] Test generated using `npx nango generate:tests` AND verified file exists
364+
- [ ] Test generated using `npx nango generate:tests -i {integrationId} -a <action-name>` AND verified file exists
363365
- [ ] Action implemented (GREEN)
364366
- [ ] **Action imported in `index.ts`** (e.g., `import './provider/actions/action-name.js';`)
365367
- [ ] Compilation passes (`npx nango compile`)
@@ -376,7 +378,7 @@ The dryrun creates a mock with hash based on headers like `Nango-Is-Script`. Tes
376378
| Running commands from wrong directory | Commands fail or can't find files | Always `cd nango-integrations/` first |
377379
| Forgetting to update index.ts | Action won't be loaded/compiled | Add import to index.ts after creating action file |
378380
| Not cleaning up old mocks | Tests pass with stale/incorrect data | Delete old mocks before running `--save-responses` again |
379-
| Manually writing test files | Wrong structure, missing test utilities | Use `npx nango generate:tests` |
381+
| Manually writing test files | Wrong structure, missing test utilities | Use `npx nango generate:tests -i {integrationId} -a <action-name>` |
380382
| Skipping dryrun validation | Action may fail in production | Always run dryrun with real API for each action |
381383
| Not verifying test file creation | Tests not generated, workflow blocked | Check file exists after `generate:tests` |
382384
| Looking for nango.yaml | File doesn't exist in this setup | Use index.ts for imports instead |

0 commit comments

Comments
 (0)