Skip to content

refactor: replaced states and country imports with context #34

refactor: replaced states and country imports with context

refactor: replaced states and country imports with context #34

# .github/workflows/e2e-ios.yml
name: e2e-ios
on: push
jobs:
e2e-ios:
runs-on: macos-14
steps:
- name: Checkout repository
uses: actions/checkout@v3
- name: Checkout iOS Repo
uses: actions/checkout@v4
with:
repository: juspay/hyperswitch-sdk-ios
ref: main
path: ios
fetch-depth: 0
- name: Setup Node.js
uses: actions/setup-node@v3
with:
node-version: '20'
- name: Dependency Install
run: |
jq 'del(.resolutions) |
del(.dependencies["react-native-hyperswitch-netcetera-3ds"]) |
del(.dependencies["react-native-hyperswitch-scancard"])' package.json > package.json.tmp &&
mv package.json.tmp package.json
npm install
- name: Create .env file
run: |
touch .env
echo ${{ secrets.HYPERSWITCH_PUBLISHABLE_KEY }}
echo STATIC_DIR = ./dist >> .env
echo HYPERSWITCH_PUBLISHABLE_KEY = ${{ secrets.HYPERSWITCH_PUBLISHABLE_KEY }}>> .env
echo HYPERSWITCH_SECRET_KEY = ${{ secrets.HYPERSWITCH_SECRET_KEY }}>> .env
echo PROFILE_ID = ${{ secrets.PROFILE_ID }}>> .env
- name: Start server
run: |
nohup node server.js &
- name: Check Server
run: |
curl http://localhost:5252/create-payment-intent
- name: Install macOS dependencies
run: |
brew tap wix/brew
brew install applesimutils
env:
HOMEBREW_NO_AUTO_UPDATE: 1
HOMEBREW_NO_INSTALL_CLEANUP: 1
# - name: Setup Ruby, JRuby and TruffleRuby
# uses: ruby/[email protected]
# - name: Cache CocoaPods
# id: cache-cocoapods
# uses: actions/cache@v3
# with:
# path: ios/Pods
# key: ${{ runner.os }}-pods-${{ hashFiles('ios/Podfile.lock') }}
# restore-keys: |
# ${{ runner.os }}-pods-
- name: Install CocoaPods
run: |
ls
cd ios
ls
pod setup --verbose
sudo gem install cocoapods
pod install
cd ..
- name: Detox rebuild framework cache
run: npx detox rebuild-framework-cache
- name: Start Rescript
run: |
npm run re:start
- name: Start Metro
run: |
nohup npm run start &
- name: Cache Detox build
id: cache-detox-build
uses: actions/cache@v3
with:
path: ios/build
key: ${{ runner.os }}-detox-build
restore-keys: |
${{ runner.os }}-detox-build
- name: Detox build
run: npx detox build --configuration ios.sim.debug
- name: Detox test
run: npx detox test --configuration ios.sim.debug --loglevel trace --record-logs all
- name: Upload artifacts
if: failure()
uses: actions/upload-artifact@v3
with:
name: detox-artifacts
path: artifacts