Skip to content

Commit

Permalink
ci: add NPM publish simulation workflow (#1117)
Browse files Browse the repository at this point in the history
The workflow tests bob in the context 
of interactive-examples using install-local.
  • Loading branch information
queengooborg authored Feb 24, 2023
1 parent 38bb023 commit 764f099
Showing 1 changed file with 47 additions and 0 deletions.
47 changes: 47 additions & 0 deletions .github/workflows/npm-published-simulation.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,47 @@
# Instead of waiting for BoB to be published to npmjs.com and be upgraded
# inside mdn/interactive-examples by Dependabot, we do all those steps here
# using `npm pack`.

name: NPM Publish simulation

on:
pull_request:
branches:
- main

jobs:
build:
runs-on: ubuntu-latest

steps:
- name: Setup Node.js environment (interactive-examples)
uses: actions/setup-node@v3
with:
node-version: 18

- name: Checkout mdn/interactive-examples
uses: actions/checkout@v3
with:
repository: mdn/interactive-examples
path: interactive-examples

- name: Install all packages (interactive-examples)
working-directory: interactive-examples
run: npm ci

- name: Checkout this repository
uses: actions/checkout@v3
with:
path: bob

- name: Install all packages (bob)
working-directory: bob
run: npm ci

- name: Install local BoB in interactive-examples
working-directory: interactive-examples
run: npx install-local ../bob

- name: Build interactive-examples
working-directory: interactive-examples
run: npm run build

0 comments on commit 764f099

Please sign in to comment.