Skip to content

W-22975399: Add hybrid template support to test_template.sh#538

Merged
wmathurin merged 1 commit into
forcedotcom:devfrom
wmathurin:W-22975399-hybrid-test-template-sh
Jun 16, 2026
Merged

W-22975399: Add hybrid template support to test_template.sh#538
wmathurin merged 1 commit into
forcedotcom:devfrom
wmathurin:W-22975399-hybrid-test-template-sh

Conversation

@wmathurin

Copy link
Copy Markdown
Contributor

Summary

Extends `test_template.sh` to build hybrid templates (`HybridLocalTemplate`, `HybridRemoteTemplate`) using the Cordova CLI directly — without depending on `forcehybrid` or the Package repo.

Changes

`test_template.sh`

  • Add `test_hybrid` function that mirrors the steps in `createHybridApp()` in `SalesforceMobileSDK-Package/shared/createHelper.js` (comment in code points there)
    • Runs template `install.js` to clone SDK source (enables composite build, avoids Maven Central dependency on unreleased versions)
    • `cordova create` → `cordova platform add ios@8.1.0` / `android@15.0.0` → `cordova plugin add` → copy `www/` → `cordova prepare` → build
  • Add `--plugin-repo-uri` flag (default: `https://github.com/forcedotcom/SalesforceMobileSDK-CordovaPlugin#dev\`)
  • Remove hybrid skip guard; add hybrid dispatch alongside native/RN

`.gitignore`: Add `tmp/` (generated apps land there during testing)

GitHub Actions: Add `npm install -g cordova@13` step to both reusable workflows

Test results (local)

  • ✅ HybridLocalTemplate (Android)
  • ✅ HybridLocalTemplate (iOS)
  • ✅ HybridRemoteTemplate (Android)
  • ✅ HybridRemoteTemplate (iOS)
  • ✅ AndroidNativeKotlinTemplate (Android) — no regression

GUS

W-22975399

- Add test_hybrid function using Cordova CLI directly (no forcehybrid dependency)
  with comment pointing to createHelper.js in Package repo
- Add --plugin-repo-uri flag (default: forcedotcom CordovaPlugin dev branch)
- Remove hybrid skip guard; add hybrid dispatch in test_template
- Add tmp/ to .gitignore (generated apps land there)
- Install Cordova CLI in GitHub Actions reusable workflows (ios + android)
@wmathurin wmathurin merged commit 5bd39c4 into forcedotcom:dev Jun 16, 2026
9 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants