-
Notifications
You must be signed in to change notification settings - Fork 3
58 lines (48 loc) · 1.41 KB
/
ci-test-lint-deprecated.yml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
# This workflow will do a clean install of node dependencies, build the source code and run tests across different versions of node
# For more information see: https://help.github.com/actions/language-and-framework-guides/using-nodejs-with-github-actions
name: Deprecated Test and Lint
on:
push:
branches:
- develop
pull_request:
branches:
- develop
env:
plugin_name: vk-blocks-pro
jobs:
build:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v2
- name: Setup Node.js (.node-version)
uses: actions/setup-node@v2
with:
node-version: 20.x
- name: Setup PHP 7.4
uses: shivammathur/setup-php@v2
with:
php-version: 7.4
- name: Install NPM Scripts
run: npm install
- name: Install Composer Package ( no-dev )
run: composer install --no-dev
- name: Install @wordpress/env
run: npm install -g @wordpress/env
- name: Run @wordpress/env
run: npx wp-env start
- name: Install WP-CLI
run: |
curl -O https://raw.githubusercontent.com/wp-cli/builds/gh-pages/phar/wp-cli.phar
chmod +x wp-cli.phar
mv wp-cli.phar /usr/local/bin/wp
- name: Build
run: npm run build
# 各ブロックのlintを実行
- name: Run lint.
run: |
npm run lint
# 後方互換テスト実行
- name: Run deprecated test.
run: |
npm run test-unit