Skip to content

Commit

Permalink
Merge pull request #317 from Parsely/release/2.5.0
Browse files Browse the repository at this point in the history
Release 2.5.0
  • Loading branch information
jblz authored May 17, 2021
2 parents de02bbd + 049889e commit 50cb853
Show file tree
Hide file tree
Showing 57 changed files with 39,699 additions and 2,943 deletions.
4 changes: 4 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
Expand Up @@ -9,6 +9,8 @@
# They are also used when pushing to WordPress.org SVN using the
# https://github.com/10up/action-wordpress-plugin-deploy GitHub Action.

# Likewise, anything marked `export-ignore` will be excluded by `bin/export-plugin.sh`

# Directories
/.github export-ignore
/.wordpress-org export-ignore
Expand All @@ -22,10 +24,12 @@
/.gitignore export-ignore
/.phpcs.xml.dist export-ignore
/.prettierrc export-ignore
/.nvmrc export-ignore
/.travis.yml export-ignore
/CHANGELOG.md export-ignore
/CODE_OF_CONDUCT.md export-ignore
/CONTRIBUTING.md export-ignore
/composer.json export-ignore
/composer.lock export-ignore
/package-lock.json export-ignore
/phpunit.xml.dist export-ignore
28 changes: 28 additions & 0 deletions .github/ISSUE_TEMPLATE/bug_report.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,28 @@
---
name: Bug report
about: Create a report to help us improve

---

## Describe the bug
<!-- A clear and concise description of what the bug is. -->

## To Reproduce
<!-- Steps to reproduce the behaviour:
1. Go to '...'
2. Click on '....'
3. Scroll down to '....'
4. See error -->

## Expected behaviour
<!-- A clear and concise description of what you expected to happen. -->

## Screenshots
<!-- If applicable, add screenshots to help explain your problem. -->

## Environment

<!-- OS, browser, browser version, PHP version, WordPress version, active plugins, active theme, etc. -->

## Additional context
<!-- Add any other context about the problem here. -->
17 changes: 17 additions & 0 deletions .github/ISSUE_TEMPLATE/feature_request.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,17 @@
---
name: Feature request
about: Suggest an idea for this project

---

## Is your feature request related to a problem?
<!-- A clear and concise description of what the problem is. Ex. I'm always frustrated when [...] -->

## Describe the solution you'd like
<!-- A clear and concise description of what you want to happen. -->

## Describe alternatives you've considered
<!-- A clear and concise description of any alternative solutions or features you've considered. -->

## Additional context
<!-- Add any other context or screenshots about the feature request here. -->
24 changes: 24 additions & 0 deletions .github/ISSUE_TEMPLATE/release-template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,24 @@
---
name: Release template
about: Internally used for new releases
title: Release x.y.z
labels: 'Type: Maintenance'

---

:warning: DO NOT MERGE (YET) :warning:

[Remaining work for this Milestone](https://github.com/Parsely/wp-parsely/milestone/14)

PR for tracking changes for the X.Y.Z release. Target release date: DOW DD MMMM YYYY.

- [ ] Merge any outstanding PRs due for this release.
- [ ] Add/Update changelog for this release: PR #XXX
- [ ] Add commit/PR which increases version numbers in the README, plugin bootstrap file, and in the `test_class_version` test in `tests/class-all-test.php`.
- [ ] Merge this PR.
- [ ] Add signed release tag against `trunk`.
- [ ] Close the current milestone.
- [ ] Open a new milestone for the next release.
- [ ] If any open PRs/issues which were milestoned for this release do not make it into the release, update their milestone.
- [ ] Write a Lobby post.
- [ ] Write an internal P2 post.
13 changes: 13 additions & 0 deletions .github/dependabot.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,13 @@
version: 2
updates:
- package-ecosystem: 'npm'
reviewers:
- 'Parsely/wp-parsely'
directory: '/'
schedule:
interval: 'daily'

- package-ecosystem: 'composer'
directory: '/'
schedule:
interval: 'daily'
21 changes: 21 additions & 0 deletions .github/pull_request_template.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,21 @@
<!--- Provide a general summary of your changes in the Title above -->

## Description
<!--- Describe your changes in detail -->

## Motivation and Context
<!--- Why is this change required? What problem does it solve? -->
<!--- If it fixes an open issue, please link to the issue here. -->

## How Has This Been Tested?
<!--- Please describe in detail how you tested your changes. -->
<!--- Include details of your testing environment, and the tests you ran to -->
<!--- see how your change affects other areas of the code, etc. -->

## Screenshots (if appropriate):

## Types of changes
<!--- What types of changes does your code introduce? Put an `x` in all the boxes that apply: -->
- [ ] Bug fix (non-breaking change which fixes an issue)
- [ ] New feature (non-breaking change which adds functionality)
- [ ] Breaking change (fix or feature that would cause existing functionality to change)
2 changes: 1 addition & 1 deletion .github/workflows/deploy.yml
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@ jobs:
name: New tag
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@master
- uses: actions/checkout@v2
- name: Build # Remove or modify this step as needed
run: |
npm install
Expand Down
68 changes: 42 additions & 26 deletions .github/workflows/integration-tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -13,55 +13,71 @@ on:
jobs:
test:
name: PHP ${{ matrix.php }}
runs-on: ubuntu-latest
continue-on-error: ${{ matrix.allowed_failure }}
# ubuntu-20.04 / ubuntu-latest includes MySQL 8, which has issues with older versions of PHP.
# ubuntu-18.04 includes PHP versions 7.1-8.0, but 5.6-7.1 are cached, so setup is about 5 seconds.
# See https://setup-php.com/i/452
runs-on: ubuntu-18.04

env:
WP_VERSION: latest

strategy:
matrix:
php: [ '5.6', '7.0', '7.1', '7.2', '7.3', '7.4', '8.0' ]
allowed_failure: [ false ]
php: ['5.6', '7.0', '7.1', '7.2', '7.3', '7.4']
include:
# PHP nightly.
- php: '8.1'
allowed_failure: true
- php: '8.0'
# Ignore platform requirements, so that PHPUnit 7.5 can be installed on PHP 8.0 (and above).
composer-options: '--ignore-platform-reqs'
extensions: pcov
ini-values: pcov.directory=., "pcov.exclude=\"~(vendor|tests)~\""
coverage: pcov
# There is no PHP nightly. Due to https://github.com/sebastianbergmann/phpunit/issues/4575 this is never
# going to succeed as WordPress is hard-coded to only support PHPUnit 7.5, and then fix only appears
# in PHPUnit 8.5.14.
fail-fast: false
steps:
- name: Checkout code
uses: actions/checkout@master
uses: actions/checkout@v2

- name: Setup PHP 7.4
- name: Setup PHP ${{ matrix.php }}
uses: shivammathur/setup-php@v2
with:
php-version: '7.4'
coverage: pcov
# https://make.wordpress.org/hosting/handbook/handbook/server-environment/#php-extensions
extensions: curl, dom, exif, fileinfo, hash, json, mbstring, mysqli, libsodium, openssl, pcre, imagick, xml, zip
php-version: ${{ matrix.php }}
extensions: ${{ matrix.extensions }}
ini-values: ${{ matrix.ini-values }}
coverage: ${{ matrix.coverage }}

- name: Install Composer dependencies (PHP < 8.0 )
if: ${{ matrix.php < 8.0 }}
uses: ramsey/composer-install@v1
- name: Setup problem matchers for PHP
run: echo "::add-matcher::${{ runner.tool_cache }}/php.json"

- name: Install Composer dependencies (PHP >= 8.0)
if: ${{ matrix.php >= 8.0 }}
uses: ramsey/composer-install@v1
with:
composer-options: --ignore-platform-reqs
# Setup PCOV since we're using PHPUnit < 8 which has it integrated. Requires PHP 7.1.
# Ignore platform reqs to make it install on PHP 8.
# https://github.com/krakjoe/pcov-clobber
- name: Setup PCOV
if: ${{ matrix.php == 8.0 }}
run: |
composer require pcov/clobber --ignore-platform-reqs
vendor/bin/pcov clobber
- name: Setup Problem Matchers for PHPUnit
run: echo "::add-matcher::${{ runner.tool_cache }}/phpunit.json"

# - name: Run unit tests
# run: composer unit
- name: Install Composer dependencies
uses: ramsey/composer-install@v1
with:
composer-options: '${{ matrix.composer-options }}'

- name: Start MySQL Service
run: sudo systemctl start mysql.service

- name: Prepare environment for integration tests
run: composer prepare
run: composer prepare-ci

- name: Run integration tests (single site)
run: composer integration
if: ${{ matrix.php != 8.0 }}
run: composer test
- name: Run integration tests (single site with code coverage)
if: ${{ matrix.php == 8.0 }}
run: composer coverage-ci
- name: Run integration tests (multisite)
run: composer integration-ms
run: composer test-ms
57 changes: 57 additions & 0 deletions .github/workflows/node.js.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,57 @@
# 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: Node.js CI

on:
pull_request:
paths:
- .github/workflows/*.js.yml
- '**/*[tj]sx?'
- package*.json
push:
paths:
- .github/workflows/*.js.yml
- '**/*[tj]sx?'
- package*.json
# Allow manually triggering the workflow.
workflow_dispatch:

jobs:
build:
runs-on: ubuntu-latest

strategy:
matrix:
node-version: [14.x, 16.x]
# See supported Node.js release schedule at https://nodejs.org/en/about/releases/

steps:
- uses: actions/checkout@v2

- name: Use Node.js ${{ matrix.node-version }}
uses: actions/setup-node@v2
with:
node-version: ${{ matrix.node-version }}

# See: https://docs.github.com/en/actions/guides/caching-dependencies-to-speed-up-workflows
- name: Cache node modules
uses: actions/cache@v2
env:
cache-name: cache-node-modules
with:
path: ~/.npm
key: "${{ runner.os }}-build-${{ env.cache-name }}-${{ hashFiles('**/package-lock.json') }}"
restore-keys: |
${{ runner.os }}-build-${{ env.cache-name }}-
${{ runner.os }}-build-
${{ runner.os }}-
- name: Install JavaScript dependencies
run: npm ci

- name: Build application
run: npm run build

- name: Run tests
run: npm test
4 changes: 4 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,5 +1,9 @@
/composer.lock
/vendor
/build/*.map
.DS_Store
.idea
node_modules
/build/logs/
/build/coverage-html/

1 change: 1 addition & 0 deletions .nvmrc
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
14
Binary file modified .wordpress-org/screenshot-1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified .wordpress-org/screenshot-2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified .wordpress-org/screenshot-3.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed .wordpress-org/screenshot-4.png
Binary file not shown.
Loading

0 comments on commit 50cb853

Please sign in to comment.