Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

PHPDoc improvements #542

Open
wants to merge 303 commits into
base: develop
Choose a base branch
from
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
303 commits
Select commit Hold shift + click to select a range
934a261
Don't create test tables as temporary
trepmal Mar 23, 2017
fe48900
Don't cache when get_object_terms fails
mjangda Mar 28, 2017
3248dfc
Update travis config to handle phpunit + php7
mjangda Mar 28, 2017
f53d8f7
Update Travis environment matrix
mjangda Mar 28, 2017
ed38119
Merge pull request #406 from Automattic/fix/get_the_terms-ordering
philipjohn Apr 3, 2017
82444c3
Merge pull request #404 from Automattic/release/3.2.2
philipjohn Apr 3, 2017
525f211
Update version constant
philipjohn Apr 3, 2017
e6a4f24
Remove associated guest user when mapped user id deleted.
May 24, 2017
0fbede4
Removed Duplicate Left Join and kept Alias
May 30, 2017
1602f48
Revert "Removed Duplicate Left Join and kept Alias"
May 30, 2017
6e7da2b
Removed duplicate left join for optimization
May 30, 2017
1387ae1
Merge branch 'master' of https://github.com/Automattic/Co-Authors-Plus
May 30, 2017
f759744
Fixed WP CLI create-terms-for-posts if no co-authors found
May 30, 2017
76c59ef
Revert "Fixed WP CLI create-terms-for-posts if no co-authors found"
May 30, 2017
9f8a1d5
Revert "Removed duplicate left join for optimization"
May 30, 2017
68bcb6e
Fixed WP CLI create-terms-for-posts if no co-authors found
May 30, 2017
a5222a9
Removed double left join on posts_join_filter (#419)
May 30, 2017
8ab4751
Merge remote-tracking branch 'upstream/master'
May 30, 2017
ea4ef62
CoAuthors display now for Pages and JS is being enqueued on Pages
May 31, 2017
bcc875b
JS error goes away from js_vars()
May 31, 2017
f226e9c
changed is_post_type_enabled() to clean up code
May 31, 2017
29e1e90
removed extra whitespace
May 31, 2017
6b3ea35
removed all traces of $post_type in functions, since is_post_type_ena…
May 31, 2017
5ac7d9a
Revert "Update version constant"
trepmal May 31, 2017
8f498c4
Edited words to match glossary
Jun 1, 2017
8ba4611
Removed continue because the script would stop running.
Jun 1, 2017
4c23011
Added better consistencies with glossary
Jun 1, 2017
8c23eeb
Merge branch 'master' into reduce-sleep
trepmal Jun 1, 2017
586dcdc
Revert "Revert "Update version constant""
trepmal Jun 1, 2017
1a272fa
doesn't return false after quick edit saves
Jun 2, 2017
84d8394
replaced hardcoded 'author' with $this->coauthor_taxonomy
Jun 2, 2017
5206a53
Tested tag to 4.8
philipjohn Jun 8, 2017
20efecf
Merge pull request #400 from Automattic/reduce-sleep
philipjohn Jun 17, 2017
7bdae3c
Merge pull request #420 from rebeccahum/cli-create-terms-for-posts
philipjohn Jun 17, 2017
1f61855
Merge pull request #423 from rebeccahum/terminology
philipjohn Jun 17, 2017
39276d1
Merge pull request #426 from rebeccahum/replace_hardcoded_author
philipjohn Jun 17, 2017
830987b
Move parenthesis to fix esc_html and sprintf
trepmal Jun 27, 2017
06c123d
Added progress so users have an idea of how long it will take
Jun 28, 2017
832ac30
Merge pull request #430 from Automattic/trepmal-patch-1
philipjohn Jun 28, 2017
b91e7d4
Added a better style of progress bar!
Jun 29, 2017
d404fec
Deleting guest authors is less confusing
Jun 29, 2017
19d94b9
Fixed merge conflicts
Jun 29, 2017
c278908
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Jun 29, 2017
3380114
Hopefully now merge conflict is gone now...
Jun 29, 2017
e80cb47
some extra notes.
Jun 29, 2017
0883406
Merge remote-tracking branch 'refs/remotes/Automattic/master' into de…
Jun 29, 2017
5433e37
featured image to avatar
Jun 30, 2017
e0902c0
Removed avatar sizing
Jun 30, 2017
b5fd5d5
remove duplicated linked author byline
Jun 30, 2017
9b57a43
coauthors_wp_list_authors has the option now of listing only guest au…
Jun 30, 2017
95f8c03
Merge pull request #433 from rebeccahum/featured_image_avatar
philipjohn Jul 2, 2017
fb7ba91
Merge pull request #434 from rebeccahum/remove_avatar_sizing
philipjohn Jul 2, 2017
95866e1
Merge pull request #435 from rebeccahum/remove_duplicated_byline
philipjohn Jul 2, 2017
9f64154
remove duplicates from linked accounts
Jul 4, 2017
f4791d0
changes as per philipjoin
Jul 4, 2017
3fbbebc
Added later escaping
Jul 5, 2017
631e719
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Jul 5, 2017
c281135
Use linked account for accurate post count
Jul 5, 2017
863a6e6
Redid README.md with better markdown formatting
Jul 5, 2017
cdd7e0f
added readme.txt back
Jul 5, 2017
90e201c
remove quotes, stray =s and upgrade notice section
Jul 5, 2017
bc5a46b
added check for false $term
Jul 6, 2017
c066be2
Do not 404 when guest author archive has 0 posts. Addresses #425 (#440)
trepmal Jul 6, 2017
f6a82ca
Move parenthesis to fix esc_html and sprintf
trepmal Jun 27, 2017
f2eba65
featured image to avatar
Jun 30, 2017
555cd72
Removed avatar sizing
Jun 30, 2017
0372cf0
remove duplicated linked author byline
Jun 30, 2017
28a62ed
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Jul 7, 2017
56f977d
Merge branch 'master' of https://github.com/rebeccahum/Co-Authors-Plus
Jul 7, 2017
bec8e03
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Jul 7, 2017
8f8a0e7
fixed author archive title
Jul 7, 2017
b60a7ef
revised comment
Jul 7, 2017
0be3eca
Fix invalid CSS (#442)
jordie23 Jul 12, 2017
8a8424b
fixed coauthors_link_single to work with guest authors
Jul 13, 2017
9746d3d
added _blank target
Jul 13, 2017
5abc3ce
switched logic around
Jul 13, 2017
69e6402
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Jul 13, 2017
b3fb700
added hooks for creating/deleting guest authors
Aug 11, 2017
6f5627b
Merge pull request #446 from rebeccahum/added_guest-author_hooks
sboisvert Aug 11, 2017
a2592a8
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Aug 11, 2017
32c7f09
Merge pull request #439 from rebeccahum/new_readme.MD
Aug 11, 2017
ac7ac32
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Aug 13, 2017
2953a4c
Merge pull request #438 from rebeccahum/accurate_guest_post_count
sboisvert Aug 28, 2017
2eeb8b7
fix logic for doing_autosave check
Aug 31, 2017
3da2471
Move parenthesis to fix esc_html and sprintf
trepmal Jun 27, 2017
c0341e7
featured image to avatar
Jun 30, 2017
84de506
Removed avatar sizing
Jun 30, 2017
c8b4a16
remove duplicated linked author byline
Jun 30, 2017
39e7e5e
Redid README.md with better markdown formatting
Jul 5, 2017
457033d
added readme.txt back
Jul 5, 2017
51ac366
remove quotes, stray =s and upgrade notice section
Jul 5, 2017
b78650f
Do not 404 when guest author archive has 0 posts. Addresses #425 (#440)
trepmal Jul 6, 2017
0e25f15
Fix invalid CSS (#442)
jordie23 Jul 12, 2017
ca4d450
added hooks for creating/deleting guest authors
Aug 11, 2017
fb30e18
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Sep 8, 2017
6ca9945
Merge branch 'master' of https://github.com/rebeccahum/Co-Authors-Plus
Sep 8, 2017
1c8b684
Merge remote-tracking branch 'refs/remotes/origin/user_login-spaces' …
Sep 8, 2017
4756ca8
Fixes "Notice: Trying to get property of non-object" for users who ha…
Sep 8, 2017
636397a
Fixes issue of not being able to reassign posts to user with user_log…
Sep 8, 2017
53ca493
Merge pull request #437 from rebeccahum/dedupe_coauthors_wp_list_authors
philipjohn Oct 13, 2017
461ed11
Merge pull request #436 from rebeccahum/coauthors_wp_list_authors
philipjohn Oct 13, 2017
2206272
Merge pull request #432 from rebeccahum/delete_guest_author
philipjohn Oct 13, 2017
3fbad83
Merge pull request #407 from haleeben/fix/no_authors_found_message
philipjohn Oct 13, 2017
51f890f
Merge pull request #441 from rebeccahum/filter_author_archive
philipjohn Oct 13, 2017
c848150
Merge pull request #414 from mdchiragpatel/fixed-120
philipjohn Oct 13, 2017
9e49399
Merge pull request #453 from rebeccahum/user_login_spaces
philipjohn Oct 13, 2017
c4624ca
Adding escaping
Oct 13, 2017
2f12e55
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Oct 13, 2017
b1d8a37
Adding details of filter for slow performance
pkevan Oct 20, 2017
6d4d250
Merge pull request #444 from rebeccahum/fix_coauthors_links_single
philipjohn Oct 22, 2017
ef47e04
Merge pull request #456 from Automattic/fix/issue319
philipjohn Oct 22, 2017
03dd563
Remove redundant test for 404 on Author Archive
philipjohn Oct 22, 2017
918517d
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Oct 30, 2017
1ae3db4
Fixed counting for guest author posts
Oct 30, 2017
ec2209a
Users table will give accurate post count if linked guest author has …
Oct 30, 2017
eddbc21
No need to add $guest_count->count anymore now that the Users table d…
Oct 30, 2017
c8456e6
Added one more validation
Oct 31, 2017
dfc3951
Merge pull request #461 from rebeccahum/guest_author_count_table
sboisvert Nov 13, 2017
28c6458
Merge pull request #450 from mslinnea/fix-autosave-logic
sboisvert Nov 13, 2017
717609f
Merge pull request #422 from rebeccahum/pages_quick_edit
sboisvert Nov 13, 2017
0c3d90a
Merge pull request #386 from trepmal/milestone/kl-375
sboisvert Nov 13, 2017
3c7cd54
Merge pull request #431 from rebeccahum/wpcli_create-guest-author_pro…
rebeccahum Nov 13, 2017
2070487
Merge remote-tracking branch 'refs/remotes/Automattic/master'
Dec 8, 2017
7617511
set $coauthors_loading
Dec 8, 2017
b2bc1d3
Merge pull request #468 from rebeccahum/set-coauthors_loading
rebeccahum Dec 8, 2017
a1b3d43
[#198] Fix guest authors with non-ASCII characters
sanketio Dec 21, 2017
3fb9b33
[#198] Replace .html() with .text() for simple string in js
sanketio Dec 21, 2017
4037ea0
[#279] Fix duplicate name display issue
sanketio Dec 21, 2017
8f4f7c3
[#198] Improve unit testing for non-ASCII character issue
sanketio Dec 22, 2017
8bf7a9a
[#198] Improve phpunit test cases + cosmetic changes
sanketio Dec 22, 2017
cc36104
[#198] Assign values to variables instead of keeping empty for test c…
sanketio Dec 22, 2017
08b7b66
[#184] Started unit tests for template tags
sanketio Dec 26, 2017
18ece5b
[#184] Unit tests for coauthors() for template tags
sanketio Dec 26, 2017
892cd22
[#184] Unit tests for coauthors_posts_links_single() for template tags
sanketio Dec 26, 2017
7fa2a4b
[#184] Unit tests for coauthors_firstnames() for template tags
sanketio Dec 26, 2017
79e9fc1
[#184] Method description for coauthors_firstnames() for template tags
sanketio Dec 26, 2017
cde4e0b
[#184] Unit tests for coauthors_lastnames() for template tags
sanketio Dec 26, 2017
238f082
[#184] Unit tests for coauthors_nicknames() for template tags
sanketio Dec 26, 2017
25679f8
[#184] Unit tests for coauthors_emails() for template tags
sanketio Dec 26, 2017
991a65b
[#184] Unit tests for coauthors_links_single() for template tags
sanketio Dec 26, 2017
f42aa5a
[#184] Unit tests for coauthors_ids() for template tags
sanketio Dec 26, 2017
d1283ec
[#184] Unit tests for get_the_coauthor_meta() for template tags
sanketio Dec 26, 2017
ae0071f
[#184] Unit tests for coauthors_wp_list_authors() for template tags
sanketio Dec 27, 2017
83412ce
[#184] Unit tests for coauthors_get_avatar() for template tags
sanketio Dec 27, 2017
3654b25
[#184] Fix undefined variable warnings and add feed_type for feed link
sanketio Dec 27, 2017
4c4c23d
[#388] Unit tests for is_guest_authors_enabled() method
sanketio Dec 27, 2017
0057e72
[#388] Unit tests for get_coauthor_by() method
sanketio Dec 27, 2017
5423d3e
[#184] Improve unit tests
sanketio Dec 27, 2017
c90d7e8
[#388] Unit tests for is_post_type_enabled() method
sanketio Dec 27, 2017
6a05c8b
[#388] Fix unit tests for is_post_type_enabled() method using current…
sanketio Dec 27, 2017
a072306
[#184] Remove not needed assertions and add proper commenting
sanketio Dec 27, 2017
4bf67ec
[#388] Unit tests for current_user_can_set_authors() method
sanketio Dec 28, 2017
f0e203d
[#388] Unit tests for search_authors() method
sanketio Dec 28, 2017
2aa752b
[#388] Unit tests for get_author_term() method
sanketio Dec 28, 2017
a104f77
[#388] Unit tests for update_author_term() method
sanketio Dec 28, 2017
4c9675c
[#388] Unit tests for get_guest_author_by() method
sanketio Dec 28, 2017
5b73757
[#388] Unit tests for get_guest_author_thumbnail() method
sanketio Dec 28, 2017
513d3e0
[#388] Unit tests for get_guest_author_fields() method
sanketio Dec 28, 2017
900daab
[#388] Unit tests for get_all_linked_accounts() method
sanketio Dec 28, 2017
ea55216
[#388] Unit tests for create_guest_author_from_user_id() method
sanketio Dec 29, 2017
341b36c
[#388] Unit tests for handle_delete_guest_author_action() method
sanketio Dec 29, 2017
6b394d2
[#388] Unit tests for CoAuthors_Guest_Authors::delete() method
sanketio Dec 29, 2017
c796f08
[#388] Unit tests for coauthors orders
sanketio Dec 29, 2017
ef1a6db
[#388] Improve unit tests
sanketio Jan 1, 2018
417b6f2
[#184] Unit tests for coauthors orders
sanketio Jan 1, 2018
b5a2144
[#388] Remove unit tests for coauthors orders
sanketio Jan 1, 2018
bfd7436
[#388] Improve unit tests
sanketio Jan 1, 2018
6393550
[#279] Add issue link as ref
sanketio Dec 22, 2017
b2375f5
[#279] Improve phpunit test cases
sanketio Dec 22, 2017
8863cc1
[#279] Improve condition checking for unit test cases
sanketio Dec 25, 2017
e75c528
[#279] Refactor comments for test cases
sanketio Dec 25, 2017
2902cdb
Update class-wp-cli.php
megfh Jan 5, 2018
7cfba09
Merge pull request #480 from megfh/patch-1
rebeccahum Jan 15, 2018
9806b14
[#198] Replace urlencode/urldecode with rawurlencode/rawurldecode
sanketio Jan 30, 2018
c8539e6
[#279] Code cleanup
sanketio Jan 30, 2018
fd08f52
[#388] Modify where condition when WordPress generates `post_author I…
sanketio Jan 30, 2018
85a7b50
Merge pull request #473 from sanketio/fix/198
philipjohn Jan 31, 2018
930129f
[#458] Update travis file
sanketio Feb 1, 2018
156c719
Changes to resolve issue #332 about missing coauthor meta in get_the_…
nmeh20 Feb 2, 2018
57851b7
Changes to resolve issue #332. Updated funtion resolve error generate…
nmeh20 Feb 8, 2018
d522c09
Changes for optimizing code of get_the_coauthor_meta function
nmeh20 Feb 14, 2018
6aa05fd
[#458] Include WP 4.6 env in travis file
sanketio Mar 2, 2018
f6a3991
Merge pull request #482 from sanketio/fix/458
philipjohn Mar 2, 2018
969d059
Merge pull request #476 from sanketio/fix/388
philipjohn Mar 2, 2018
3760cb1
Merge pull request #475 from sanketio/fix/184
philipjohn Mar 2, 2018
bbd2e06
Merge pull request #457 from Automattic/fix/author_404_test
philipjohn Mar 2, 2018
539db91
Updating function to allow fetching meta data based on user_id to sup…
nmeh20 Mar 2, 2018
96330a6
Removing unused global variables
nmeh20 Mar 7, 2018
bf3aac1
Merge branch 'master' into fix/279
sanketio Mar 14, 2018
61be196
Formatting in my changes as per PHPCS
nmeh20 Mar 14, 2018
010d2d1
Space alignment and adding escape to output
nmeh20 Mar 21, 2018
55259dd
Merge pull request #474 from sanketio/fix/279
philipjohn Apr 7, 2018
da40f56
Release v3.2: Update version numbers etc
philipjohn Apr 7, 2018
17aebd5
Merge pull request #484 from nilzari/master
philipjohn Apr 7, 2018
492aee6
Release v3.3: Changelog and props
philipjohn Apr 7, 2018
cdb725c
Fix failing test cases
sanketio Apr 9, 2018
a34519e
Merge pull request #500 from sanketio/fix/499
philipjohn Apr 10, 2018
a9bbf98
Merge branch 'release/3.3'
philipjohn Apr 10, 2018
2755efc
Unexpected output of template tag 'coauthors_links' is resolved by up…
binodkalathil Apr 14, 2018
889f422
Corrected PHPUnit test cases to work with the udpated code
binodkalathil Apr 15, 2018
533449d
Bump last version of WP to 4.8
pkevan Apr 16, 2018
0cd0f2f
Merge branch 'master' into issues/469-function-return-author-login-na…
binodkalathil Apr 17, 2018
432d6b0
Merge pull request #504 from binodkalathil/issues/469-function-return…
sboisvert Apr 17, 2018
869e060
Revert "Merge pull request #438 from rebeccahum/accurate_guest_post_c…
rebeccahum May 22, 2018
fcc1d50
Added i18n support to Author title and name for author archive
blunce24 May 25, 2018
9161eb2
changed author display name on author archive page to be Full Name ra…
blunce24 May 25, 2018
ec1718f
added check for before using it in query
blunce24 May 26, 2018
65da6c4
updated truthiness check for current_coauthor_term object
blunce24 May 28, 2018
2f9c4a1
formatting adjustments
blunce24 May 28, 2018
0fd0734
formatting updates
blunce24 May 28, 2018
a29b9bd
allow PHPCS inspection of file
blunce24 May 28, 2018
4497edd
Replacing search_fields argument (non-existent) in get_users() call w…
TheCrowned May 29, 2018
786b478
Merge pull request #516 from blunce24/i18n-author-archive
rebeccahum May 29, 2018
dece50b
fixed tab issue
blunce24 May 29, 2018
8d585bf
changed check on coauthor term to be more concise
blunce24 May 29, 2018
f82f9fa
Merge pull request #517 from blunce24/current-user-no-terms-warning
sboisvert May 30, 2018
cfa8aa9
Merge pull request #519 from TheCrowned/fix/513-author-search-argument
philipjohn May 30, 2018
c4c3f9b
Merge remote-tracking branch 'upstream/master'
May 30, 2018
39da33c
Add isset() checkes to post registration
May 30, 2018
290b18e
remove trailing whitespace
May 30, 2018
a8ad969
Updated readme with FAQ on how to disable Guest Authors. Fix #122.
TheCrowned May 31, 2018
98d6dbd
Merge pull request #521 from paulschreiber/fix/warnings
mdbitz May 31, 2018
70a5646
Fix test_coauthors_links_single_when_guets_author(), which was wrongl…
TheCrowned Jun 4, 2018
c7f573a
Updated coauthors_links_single so that CAP coauthor link matches Core…
TheCrowned Jun 4, 2018
c5c9d43
Removed function action_pre_user_query and its hooks, as it was obsolete
TheCrowned Jun 5, 2018
e5967da
Merge pull request #529 from TheCrowned/fix/505-test-wrong-meta-key
sboisvert Jun 5, 2018
4602090
Merge pull request #523 from TheCrowned/fix/122-faq-disable-guest-author
sboisvert Jun 5, 2018
30d546a
Merge remote-tracking branch 'upstream/master'
Jun 5, 2018
5684a26
Only filter author template for title
jacobarriola Jun 5, 2018
c3a4e65
Merge pull request #531 from TheCrowned/fix/530-remove-action_pre_use…
sboisvert Jun 6, 2018
d966dee
Merge remote-tracking branch 'upstream/master'
paulschreiber Jun 8, 2018
fd3c8ca
add PHPCS/WPCS to composer.json
paulschreiber Jun 8, 2018
94ca1f9
Add phpcs.xml
paulschreiber Jun 8, 2018
e5459b2
update composer.lock
paulschreiber Jun 8, 2018
02091e7
gitignore vendor folder
paulschreiber Jun 8, 2018
9803e24
PHPCBF: automated fixes (spacing, parens)
paulschreiber Jun 8, 2018
18f4691
remove spaces used for alignment
paulschreiber Jun 8, 2018
c5b1b80
PHPDoc for deprecated.php
paulschreiber Jun 8, 2018
9393683
PHPDoc for wpcom-helper.php
paulschreiber Jun 8, 2018
ad44337
PHPDoc for tests
paulschreiber Jun 8, 2018
75a781b
PHPDoc improvements for classes
paulschreiber Jun 8, 2018
2026d4c
Allow guest authors have personal data exported (#528)
mariovalney Jun 13, 2018
2be4599
Re-enabled Test_Author_Queries->test__author_arg__user_is_coauthor__a…
TheCrowned Jun 15, 2018
d559799
Re-enabled Test_Author_Queries->tests__author_name_arg_plus_tax_query…
TheCrowned Jun 15, 2018
d63ab9b
Merge pull request #546 from TheCrowned/fix/538-re-enable-tests
sboisvert Jun 18, 2018
96a0efa
Add post type parameter to the Mine link, so it works for Pages
Jun 18, 2018
b0c2871
Merge pull request #547 from pdemarte/post-type-pages-fix
rebeccahum Jun 18, 2018
ab422f7
Merge branch 'master' into patch-1
jacobarriola Jun 25, 2018
7f3651a
Merge pull request #535 from jacobarriola/patch-1
rebeccahum Jun 25, 2018
682055a
Merge branch 'master' into fix/phpdoc
paulschreiber Jun 25, 2018
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions .gitignore
Original file line number Diff line number Diff line change
@@ -1,3 +1,5 @@
.DS_Store
.svn
.idea/
vendor/

88 changes: 78 additions & 10 deletions .travis.yml
Original file line number Diff line number Diff line change
@@ -1,17 +1,85 @@
language: php

php:
- 5.3
- 5.5
matrix:
include:
# aliased to a recent 5.6.x version
- php: "5.6"
env: WP_VERSION=4.8

env:
- WP_VERSION=latest
- WP_VERSION=4.1
- WP_VERSION=4.0
- php: '5.6'
env:
- WP_VERSION=latest
#- SNIFF=1
- WP_MULTISITE=0

- php: '5.6'
env:
- WP_VERSION=latest
#- SNIFF=1
- WP_MULTISITE=1

# aliased to a recent 7.x version
- php: '7.0'
env: WP_VERSION=4.8

- php: '7.0'
env: WP_VERSION=latest

- php: '7.1'
env: WP_VERSION=4.8

- php: '7.1'
env: WP_VERSION=latest

before_script:
- bash bin/install-wp-tests.sh wordpress_test root '' localhost $WP_VERSION
# Set up CodeSniffer
- export PHPCS_DIR=/tmp/phpcs
- export SNIFFS_DIR=/tmp/sniffs
# Install CodeSniffer for WordPress Coding Standards checks.
- if [[ "$SNIFF" == "1" ]]; then git clone -b master --depth 1 https://github.com/squizlabs/PHP_CodeSniffer.git $PHPCS_DIR; fi
# Install WordPress Coding Standards.
- if [[ "$SNIFF" == "1" ]]; then git clone -b master --depth 1 https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards.git $SNIFFS_DIR; fi
# Install PHP Compatibility sniffs.
- if [[ "$SNIFF" == "1" ]]; then git clone -b master --depth 1 https://github.com/wimg/PHPCompatibility.git $SNIFFS_DIR/PHPCompatibility; fi
# Set install path for PHPCS sniffs.
# @link https://github.com/squizlabs/PHP_CodeSniffer/blob/4237c2fc98cc838730b76ee9cee316f99286a2a7/CodeSniffer.php#L1941
- if [[ "$SNIFF" == "1" ]]; then $PHPCS_DIR/scripts/phpcs --config-set installed_paths $SNIFFS_DIR; fi
# After CodeSniffer install you should refresh your path.
- if [[ "$SNIFF" == "1" ]]; then phpenv rehash; fi
# Set up unit tests
- bash bin/install-wp-tests.sh wordpress_test root '' localhost $WP_VERSION
# Properly handle PHPUnit versions
- export PATH="$HOME/.composer/vendor/bin:$PATH"
- |
if [[ ${TRAVIS_PHP_VERSION:0:3} == "5.6" ]]; then
composer global require "phpunit/phpunit=4.8.*"
elif [[ ${TRAVIS_PHP_VERSION:0:2} == "7." && ${WP_VERSION} == "4.8" ]]; then
composer global require "phpunit/phpunit=5.7.*"
fi
- |
if [[ -n $COMPOSER_BIN_DIR && -x $COMPOSER_BIN_DIR/phpunit ]]; then
$COMPOSER_BIN_DIR/phpunit --version
else
phpunit --version
fi

script:
- make lint
- make phpunit
# Search for PHP syntax errors.
- find -L . -name '*.php' -print0 | xargs -0 -n 1 -P 4 php -l
# WordPress Coding Standards.
# @link https://github.com/WordPress-Coding-Standards/WordPress-Coding-Standards
# @link http://pear.php.net/package/PHP_CodeSniffer/
# -p flag: Show progress of the run.
# -s flag: Show sniff codes in all reports.
# -v flag: Print verbose output.
# -n flag: Do not print warnings. (shortcut for --warning-severity=0)
# --standard: Use WordPress as the standard.
# --extensions: Only sniff PHP files.
- if [[ "$SNIFF" == "1" ]]; then $PHPCS_DIR/scripts/phpcs -p -s -v -n . --standard="WordPress-VIP" --extensions=php; fi
# Run unit tests
- |
if [[ -n $COMPOSER_BIN_DIR && -x $COMPOSER_BIN_DIR/phpunit ]]; then
$COMPOSER_BIN_DIR/phpunit
else
phpunit
fi
301 changes: 301 additions & 0 deletions README.md

Large diffs are not rendered by default.

Loading