WordPress.org

Make WordPress Core

Opened 7 months ago

Closed 7 months ago

Last modified 6 months ago

#49485 closed task (blessed) (fixed)

Make Travis CI builds pass for all supported branches

Reported by: SergeyBiryukov Owned by: SergeyBiryukov
Milestone: 5.4 Priority: normal
Severity: normal Version:
Component: Build/Test Tools Keywords:
Focuses: Cc:

Description

Previously:

#40106
Test the 3.7 branch on Travis
#40463
Get the tests for the 4.0 branch passing
#46646
Fix Travis CI builds for the 4.0 branch


Background:

#26042
wp_save_post_revision() can compare against the wrong $last_revision post
#28706
Lots of Multisite tests are exploding
#30284
Remove failing automated tests from the suite
#31091
A number of external-http requests are failing due to HTTPS redirects
#35105
Specifiy minimum node and npm version in package.json
#39486
In Travis, skip some tests when not on trunk
#40086
Get Travis tests working again on PHP 7


Since we're still backporting security fixes all the way back to 3.7 for the time being, it would be helpful to get the tests running on these older branches, so that we could be more confident in patch releases.

By backporting some changes from the 4.0 branch, we can make the tests pass on 3.9 and older branches.

Change History (19)

#1 @SergeyBiryukov
7 months ago

  • Owner set to SergeyBiryukov
  • Status changed from new to accepted

#2 @SergeyBiryukov
7 months ago

  • Summary changed from Make Travic CI builds pass for all supported branches to Make Travis CI builds pass for all supported branches

#4 @SergeyBiryukov
7 months ago

In 47331:

Build/Test Tools: Merge some test fixes to the 4.0 branch, for consistency with other branches.

This backports [30518], [30520], [30526], [31253-31254], [31257].

See #49485.

#5 @SergeyBiryukov
7 months ago

In 47332:

Build/Test Tools: Merge some test fixes to the 4.1 branch, for consistency with other branches.

This backports [31253-31254], [31257].

See #49485.

#6 @SergeyBiryukov
7 months ago

In 47333:

Build/Test Tools: Improve Travis CI configuration for better performance on 3.9 branch.

This backports [28799] and [28873].

See #49485.

#7 @SergeyBiryukov
7 months ago

In 47334:

Posts, Post Types: Ensure edit_post() promotes an auto-draft to draft.

This fixes a regression in 3.8 branch introduced in [44074].

Follow-up to [28073].

See #49485.

#8 @SergeyBiryukov
7 months ago

In 47335:

Posts, Post Types: Ensure edit_post() promotes an auto-draft to draft.

This fixes a regression in 3.7 branch introduced in [44076].

Follow-up to [28073].

Merges [47334] to the 3.7 branch.
See #49485.

#9 @SergeyBiryukov
7 months ago

In 47336:

Build/Test Tools: Display PHPUnit information for PHP tests only (for 5.2 branch).

This avoids a build error on travis:format job, caused by Travis running PHPUnit 9.x by default, which requires PHP 7.3+.

See #49485.

#10 @SergeyBiryukov
7 months ago

In 47337:

Build/Test Tools: Display PHPUnit information for PHP tests only (for 5.1 branch).

This avoids a build error on travis:format job, caused by Travis running PHPUnit 9.x by default, which requires PHP 7.3+.

Merges [47336] to the 5.1 branch.
See #49485.

#12 @SergeyBiryukov
7 months ago

In 47341:

Build/Test Tools: Remove unused ::assertPostHasTerms() method from tests/term.php.

The associated test was removed in [30241].

See #49485.

#15 @SergeyBiryukov
7 months ago

#40106 was marked as a duplicate.

#16 @SergeyBiryukov
6 months ago

In 47489:

Build/Test Tools: Remove unused ::assertPostHasTerms() method from tests/term.php.

The associated test was removed in [30241].

Merges [47341] to 3.7+ branches.
See #49485.

#17 @SergeyBiryukov
6 months ago

In 47490:

When asserting microtime output as a number, make it a number.

microtime is by default a string. Doing a greater then or less than check of that string is a bad idea since it uses the first part (the micro part of microtime) rather then the actual time. This adds a helper to convert microtime output into a float which we can then use to properly compare the output of microtime.

This fixes an intermittent test failure.

Props jorbin.
Merges [30337] to the 3.9 branch.
See #30336, #49485.

#18 @SergeyBiryukov
6 months ago

In 47491:

When asserting microtime output as a number, make it a number.

microtime is by default a string. Doing a greater then or less than check of that string is a bad idea since it uses the first part (the micro part of microtime) rather then the actual time. This adds a helper to convert microtime output into a float which we can then use to properly compare the output of microtime.

This fixes an intermittent test failure.

Props jorbin.
Merges [30337] to the 3.8 branch.
See #30336, #49485.

#19 @SergeyBiryukov
6 months ago

In 47492:

When asserting microtime output as a number, make it a number.

microtime is by default a string. Doing a greater then or less than check of that string is a bad idea since it uses the first part (the micro part of microtime) rather then the actual time. This adds a helper to convert microtime output into a float which we can then use to properly compare the output of microtime.

This fixes an intermittent test failure.

Props jorbin.
Merges [30337] to the 3.7 branch.
See #30336, #49485.

Note: See TracTickets for help on using tickets.