2023-06-29 22:00:20 +08:00
|
|
|
name: Tests
|
|
|
|
|
|
|
|
on:
|
|
|
|
push:
|
|
|
|
branches:
|
|
|
|
- master
|
|
|
|
- '*.x'
|
|
|
|
pull_request:
|
|
|
|
schedule:
|
|
|
|
- cron: '0 0 * * *'
|
|
|
|
|
|
|
|
permissions:
|
|
|
|
contents: read
|
|
|
|
|
|
|
|
jobs:
|
|
|
|
tests:
|
|
|
|
runs-on: centos
|
|
|
|
|
|
|
|
name: PHP
|
|
|
|
|
|
|
|
steps:
|
2023-06-30 13:12:43 +08:00
|
|
|
- name: '检查代码'
|
2023-06-30 10:09:39 +08:00
|
|
|
uses: https://github.com/actions/checkout@v3
|
2023-06-29 22:00:20 +08:00
|
|
|
|
2023-06-30 13:12:43 +08:00
|
|
|
- name: '安装PHP'
|
2023-06-29 22:00:20 +08:00
|
|
|
uses: XiaoLFeng/setup-php@v2
|
|
|
|
with:
|
|
|
|
coverage: none
|
2023-06-30 13:12:43 +08:00
|
|
|
tools: phpmd
|
2023-06-29 22:00:20 +08:00
|
|
|
|
2023-06-30 13:12:43 +08:00
|
|
|
- name: '运行PHPMD'
|
|
|
|
run: phpmd ./ text codesize
|
|
|
|
continue-on-error: true
|