Skip to content

Commit

Permalink
✨ Use @percy/cli (#301)
Browse files Browse the repository at this point in the history
* 🔥 Purge v3

* 🙈 Update .gitignore

* 🔧 Add babel config

* 🔧 Add eslint config

* 🔧 Add nyc config

* 📦 Update packages

* ✨ Add storybook command

* ♻ Reorganize command

* ⬆ Upgrade dependencies

* 🔧 Update config files

* ♻ Dust off command

* ✨ Add Percy config options include & exclude

* ✅ Add tests

* 👷 Use GitHub Actions

* 🐛 Handle errors when start-storybook doesn't work

* ✅ Use cross-spawn in tests for windows

* ✅ Don't wait for storybook process to exit after tests

* 🐛 Move jasmine to devdeps

* 🔥 Remove config migration init since there is none

* ✅ Move jasmine config

* ✨ Export commands for programmatic usage

* ✨ Add back old command with a deprecation message

* 🐛 Use consistent command class names

* 📝 Update README

* ✨ Allow include and exclude story parameters

* ✏ README typo

* ✅ Give storybook a minute to start

* 🔊 Update old command deprecation message

* ✏ Fix more readme typos

* 📝 Reorganize breaking changes a little

* ✅ Increase test timeout to account for storybook start

* ⚗ Dump failed test logs

* 🐛 Retry 404s when waiting for storybook to start

* ✅ Update failed request test
  • Loading branch information
Wil Wilsman authored May 27, 2021
1 parent 88c6db9 commit 4f62387
Show file tree
Hide file tree
Showing 75 changed files with 8,573 additions and 14,733 deletions.
19 changes: 0 additions & 19 deletions .babelrc

This file was deleted.

18 changes: 18 additions & 0 deletions .eslintrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
parser: '@babel/eslint-parser'
extends: standard
plugins:
- '@babel/eslint-plugin'
rules:
prefer-const: off
no-unused-expressions: off
promise/param-names: off
semi: [error, always]
generator-star-spacing:
- error
- before: false
after: false
space-before-function-paren:
- error
- anonymous: never
asyncArrow: always
named: never
16 changes: 0 additions & 16 deletions .eslintrc.js

This file was deleted.

8 changes: 8 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
version: 2
updates:
- package-ecosystem: npm
directory: /
schedule:
interval: weekly
commit-message:
prefix: ⬆️
31 changes: 31 additions & 0 deletions .github/release-drafter.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name-template: 'v$RESOLVED_VERSION'
tag-template: 'v$RESOLVED_VERSION'
categories:
- title: '💥 Breaking Changes'
labels:
- breaking
- title: '✨ Enhancements'
labels:
- feature
- enhancement
- title: '🐛 Bug Fixes'
labels:
- fix
- bugfix
- bug
- title: '🏗 Maintenance'
labels:
- maintenance
- dependencies
change-title-escapes: '\<*_&#@'
version-resolver:
major:
labels:
- breaking
minor:
labels:
- feature
- enhancement
default: patch
template: '$CHANGES'
prerelease: true
12 changes: 12 additions & 0 deletions .github/workflows/changelog.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
name: Changelog
on:
push:
branches: [master]
jobs:
update:
name: Update
runs-on: ubuntu-latest
steps:
- uses: release-drafter/release-drafter@v5
env:
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }}
34 changes: 0 additions & 34 deletions .github/workflows/ci.yml

This file was deleted.

24 changes: 24 additions & 0 deletions .github/workflows/lint.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
name: Lint
on:
push:
branches: [master]
pull_request:
workflow_dispatch:
jobs:
lint:
name: Lint
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 14
- uses: actions/cache@v2
with:
path: node_modules
key: ${{ runner.os }}/node-14/${{ hashFiles('**/yarn.lock') }}
restore-keys: ${{ runner.os }}/node-14/
- run: yarn
env:
PERCY_POSTINSTALL_BROWSER: true
- run: yarn lint
18 changes: 18 additions & 0 deletions .github/workflows/release.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
name: Release
on:
release:
types: [published]
jobs:
publish:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: 14
registry-url: 'https://registry.npmjs.org'
- run: yarn
- run: yarn build
- run: npm publish --tag next
env:
NODE_AUTH_TOKEN: ${{ secrets.NPM_TOKEN }}
31 changes: 31 additions & 0 deletions .github/workflows/test.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,31 @@
name: Test
on:
push:
branches: [master]
pull_request:
workflow_dispatch:
jobs:
test:
name: Test
strategy:
matrix:
os: [ubuntu-latest, windows-latest]
node: [12]
runs-on: ${{ matrix.os }}
steps:
- uses: actions/checkout@v2
- uses: actions/setup-node@v1
with:
node-version: ${{ matrix.node }}
- uses: actions/cache@v2
with:
path: node_modules
key: ${{ runner.os }}/node-${{ matrix.node }}/${{ hashFiles('**/yarn.lock') }}
restore-keys: ${{ runner.os }}/node-${{ matrix.node }}/
- run: yarn
env:
PERCY_POSTINSTALL_BROWSER: true
- run: yarn build
- run: yarn test
env:
DUMP_FAILED_TEST_LOGS: true
57 changes: 6 additions & 51 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,53 +1,8 @@
# Logs
logs
*.log
npm-debug.log*

# Runtime data
pids
*.pid
*.seed

# Directory for instrumented libs generated by jscoverage/JSCover
lib-cov

# Coverage directory used by tools like istanbul
coverage

# nyc test coverage
.DS_Store
.nyc_output

# Grunt intermediate storage (http://gruntjs.com/creating-plugins#storing-task-files)
.grunt

# node-waf configuration
.lock-wscript

# Compiled binary addons (http://nodejs.org/api/addons.html)
build/Release

# Dependency directories
yarn-error.log
node_modules
jspm_packages

# Optional npm cache directory
.npm

# Optional REPL history
.node_repl_history

# ESLint cache
.eslintcache

# Mac files
.DS_Store

# Nested Yarn files
packages/*/yarn.lock

# Output directories
integration-tests/lib
/lib

# Packed npm
*.tgz
coverage
dist
oclif.manifest.json
test/.storybook-build
8 changes: 8 additions & 0 deletions .nycrc
Original file line number Diff line number Diff line change
@@ -0,0 +1,8 @@
{
"include": ["src"],
"check-coverage": true,
"branches": 100,
"lines": 100,
"functions": 100,
"statements": 100
}
71 changes: 0 additions & 71 deletions HOWITWORKS.md

This file was deleted.

Loading

0 comments on commit 4f62387

Please sign in to comment.