Skip to content

feat(product, pricing, utils): Transaction issues and reference issues #17055

feat(product, pricing, utils): Transaction issues and reference issues

feat(product, pricing, utils): Transaction issues and reference issues #17055

Workflow file for this run

name: Medusa Pipeline
on:
pull_request:
jobs:
setup:
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
steps:
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: "16.10.0"
cache: "yarn"
- name: Assert changed
run: ./scripts/assert-changed-files-actions.sh "packages"
- name: Install dependencies
uses: ./.github/actions/cache-deps
with:
extension: pipeline
unit-tests:
needs: setup
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: "16.10.0"
cache: "yarn"
- name: Assert changed
run: ./scripts/assert-changed-files-actions.sh "packages"
- name: Install dependencies
uses: ./.github/actions/cache-deps
with:
extension: pipeline
- name: Build Packages
run: yarn build
- name: Run unit tests
run: yarn test
integration-tests-packages:
needs: setup
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
services:
redis:
image: redis
options: >-
--health-cmd "redis-cli ping"
--health-interval 1s
--health-timeout 10s
--health-retries 10
ports:
- 6379:6379
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
options: >-
--health-cmd pg_isready
--health-interval 1s
--health-timeout 10s
--health-retries 10
ports:
- 5432:5432
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: "16"
cache: "yarn"
- name: Install dependencies
uses: ./.github/actions/cache-deps
with:
extension: pipeline
- name: Build Packages
run: yarn build
- name: Run integration tests
run: yarn test:integration:packages
env:
DB_PASSWORD: postgres
DB_USERNAME: postgres
SPLIT: ${{ steps['split-tests'].outputs['split'] }}
integration-tests-api:
needs: setup
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
services:
redis:
image: redis
options: >-
--health-cmd "redis-cli ping"
--health-interval 1s
--health-timeout 10s
--health-retries 10
ports:
- 6379:6379
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
options: >-
--health-cmd pg_isready
--health-interval 1s
--health-timeout 10s
--health-retries 10
ports:
- 5432:5432
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: "16.10.0"
cache: "yarn"
- name: Install dependencies
uses: ./.github/actions/cache-deps
with:
extension: pipeline
- name: Build Packages
run: yarn build
- name: Run integration tests
run: yarn test:integration:api
env:
DB_PASSWORD: postgres
SPLIT: ${{ steps['split-tests'].outputs['split'] }}
integration-tests-plugins:
needs: setup
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
options: >-
--health-cmd pg_isready
--health-interval 1s
--health-timeout 10s
--health-retries 10
ports:
- 5432:5432
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: "16.10.0"
cache: "yarn"
- name: Install dependencies
uses: ./.github/actions/cache-deps
with:
extension: pipeline
- name: Build Packages
run: yarn build
- name: Run plugin integration tests
run: yarn test:integration:plugins
env:
DB_PASSWORD: postgres
NODE_OPTIONS: "--max_old_space_size=4096"
integration-tests-repositories:
needs: setup
runs-on: ubuntu-latest
env:
TURBO_TOKEN: ${{ secrets.TURBO_TOKEN }}
TURBO_TEAM: ${{ secrets.TURBO_TEAM }}
services:
postgres:
image: postgres
env:
POSTGRES_PASSWORD: postgres
POSTGRES_USER: postgres
options: >-
--health-cmd pg_isready
--health-interval 1s
--health-timeout 10s
--health-retries 10
ports:
- 5432:5432
steps:
- name: Cancel Previous Runs
uses: styfle/[email protected]
with:
access_token: ${{ github.token }}
- name: Checkout
uses: actions/checkout@v3
with:
fetch-depth: 0
- name: Setup Node.js environment
uses: actions/setup-node@v3
with:
node-version: "16.10.0"
cache: "yarn"
- name: Install dependencies
uses: ./.github/actions/cache-deps
with:
extension: pipeline
- name: Run repository integration tests
run: yarn test:integration:repositories
env:
DB_PASSWORD: postgres