Skip to content

Commit

Permalink
Merge pull request #140 from marp-team/github-actions
Browse files Browse the repository at this point in the history
Set up GitHub Actions CI to test on Windows
  • Loading branch information
yhatt authored Aug 30, 2019
2 parents ead5795 + a926f51 commit 1b37593
Show file tree
Hide file tree
Showing 6 changed files with 42 additions and 75 deletions.
28 changes: 28 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
name: Release for Windows

on:
push:
tags:
- v*

jobs:
win-release:
runs-on: windows-latest
steps:
- uses: actions/checkout@v1
- name: Use Node.js
uses: actions/setup-node@v1
with:
node-version: '10.16.0'
- name: Install with yarn
run: npm install -g yarn && yarn install
- name: Build and create standalone binaries
run: yarn build:standalone
- name: Create package for Windows
run: yarn standalone:pack
env:
TARGET: win
- name: Upload created package to the asset of GitHub release
run: yarn standalone:pack:upload
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
13 changes: 9 additions & 4 deletions .github/workflows/test.yml → .github/workflows/test-win.yml
Original file line number Diff line number Diff line change
@@ -1,8 +1,10 @@
name: Test for Windows

on: push

jobs:
win-test:
runs-on: windows-2016
runs-on: windows-latest

strategy:
fail-fast: false
Expand All @@ -14,16 +16,19 @@ jobs:

steps:
- uses: actions/checkout@v1
with:
fetch-depth: 1
- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node-version }}
- name: Install with yarn
run: npm install -g yarn && yarn install
- name: Jest
run: |
yarn test:coverage --ci -i --reporters=default --reporters=jest-junit
yarn codecov -F windows
run: yarn test:coverage --ci -i --reporters=default --reporters=jest-junit
env:
CI: true
- name: Codecov
run: yarn codecov -F windows
env:
CODECOV_TOKEN: ${{ secrets.CODECOV_TOKEN }}
4 changes: 4 additions & 0 deletions CHANGELOG.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,10 @@

- Add `v8-compile-cache` to make faster startup ([#139](https://github.com/marp-team/marp-cli/pull/139))

### Changed

- Migrate CI for Windows into GitHub Actions ([#132](https://github.com/marp-team/marp-cli/issues/132), [#140](https://github.com/marp-team/marp-cli/pull/140))

## v0.13.0 - 2019-08-23

### Fixed
Expand Down
69 changes: 0 additions & 69 deletions azure-pipelines.yml

This file was deleted.

1 change: 0 additions & 1 deletion jest.config.js
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ const { jestPreset } = require('ts-jest')
module.exports = {
collectCoverageFrom: ['src/**/*.ts'],
coveragePathIgnorePatterns: ['/node_modules/', '.*\\.d\\.ts'],
coverageReporters: ['text', 'lcov', 'cobertura'],
coverageThreshold: { global: { lines: 95 } },
moduleFileExtensions: ['ts', 'js', 'json', 'node'],
setupFiles: ['jest-plugin-context/setup', './jest.setup.js'],
Expand Down
2 changes: 1 addition & 1 deletion test/marp-cli.ts
Original file line number Diff line number Diff line change
Expand Up @@ -737,7 +737,7 @@ describe('Marp CLI', () => {
it('does not open PPTX in preview window', async () => {
await marpCli([onePath, '-p', '--pptx', '--no-output'])
expect(Preview.prototype.open).not.toBeCalled()
}, 15000)
}, 30000)
})

context('when CLI is running in an official Docker image', () => {
Expand Down

0 comments on commit 1b37593

Please sign in to comment.