Set cookie with location of request country #2788
Workflow file for this run
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
name: Functions | |
on: | |
pull_request: | |
push: | |
branches: | |
- main | |
jobs: | |
check_applicability: | |
name: Check applicability | |
runs-on: ubuntu-latest | |
outputs: | |
should_skip: ${{ steps.skip_check.outputs.should_skip }} | |
steps: | |
- id: skip_check | |
uses: fkirc/skip-duplicate-actions@v5 | |
with: | |
paths: '["functions/**", "shared/**", ".github/workflows/functions.yml"]' | |
skip_after_successful_duplicate: "false" | |
do_not_skip: '["push"]' | |
test: | |
name: Test functions | |
needs: check_applicability | |
if: needs.check_applicability.outputs.should_skip != 'true' | |
runs-on: ubuntu-latest | |
steps: | |
- name: Checkout repository | |
uses: actions/checkout@v3 | |
- name: Initialize repository | |
uses: ./.github/workflows/actions/init | |
- name: Run tests | |
env: | |
TWILIO_SID: ${{ secrets.TWILIO_TEST_SID }} | |
TWILIO_TOKEN: ${{ secrets.TWILIO_TEST_TOKEN }} | |
TWILIO_SENDER_PHONE: ${{ secrets.TWILIO_TEST_SENDER_PHONE }} | |
run: npm run functions:test | |
# TODO: re-enable | |
# - name: Run Playwright tests | |
# run: npm run functions:test:playwright | |
# | |
# - name: Deploy Playwright Report to GitHub Pages | |
# uses: rossjrw/pr-preview-action@v1 | |
# if: always() | |
# with: | |
# source-dir: functions/playwright-report/ | |
# preview-branch: gh-pages | |
# umbrella-dir: functions-playwright-report | |
# action: auto | |
deploy: | |
name: Deploy functions on Firebase (social-income-staging) | |
needs: test | |
if: github.ref == 'refs/heads/main' | |
uses: ./.github/workflows/deployment.yml | |
secrets: inherit | |
with: | |
component: functions | |
project: social-income-staging |