WordPress.org

Make WordPress Core

Opened 12 months ago

Closed 12 months ago

Last modified 12 months ago

#51487 closed enhancement (fixed)

Update 3rd-party Video Unit Tests to use more permanent videos

Reported by: garrett-eclipse Owned by: garrett-eclipse
Milestone: 5.6 Priority: normal
Severity: normal Version:
Component: Media Keywords: has-patch has-unit-tests commit
Focuses: Cc:

Description

This is a follow-up ticket from a discussion on slack, ticket in meta and associated core ticket #46986. To answer, what videos to use in unit tests for vimeo and youtube.

I'll quote the meta response from @dd32 as I feel it the most appropriate path forward;

Instead of using WordPress test accounts, could we instead fall back onto using a video uploaded by the embed company instead?

For example, for Vimeo, anything from Vimeo Staff https://vimeo.com/staff or the test video from https://player.vimeo.com/embed should be safe to use going forward. edit: The player embed page actually has a bunch of test videos with various states, such as not-embeddable, hosted by official vimeo test accounts, seems perfect for this use-case.

Having official WordPress accounts for every embed platform is not going to be viable from a management perspective IMHO, and having accounts everywhere with only a single W logo video doesn't lead to a super great experience when it ends up in search results.

Where WordPress does have a use for the service (Such as Youtube) using one of our uploads such as a release video does make sense though.

This ticket is to update those urls to use the youtube suggested video and the one from the Vimeo embed tutorial.
Youtube - https://www.youtube.com/watch?v=72xdCU__XCk
Vimeo - https://vimeo.com/76979871

Attachments (1)

51487.diff (10.7 KB) - added by garrett-eclipse 12 months ago.
Initial patch to bring consistency to the vimeo/youtube urls used for tests.

Download all attachments as: .zip

Change History (9)

@garrett-eclipse
12 months ago

Initial patch to bring consistency to the vimeo/youtube urls used for tests.

#1 @garrett-eclipse
12 months ago

Note: While creating the patch I found some instances in Gutenberg so once this gets some review we can look to also bring consistency to those tests too.

#2 @Mista-Flo
12 months ago

  • Keywords needs-testing removed

Hey Garrett, nice one!

I have run the unit tests with the patch applied and it works, no regression.

This ticket was mentioned in Slack in #core-media by hellofromtonya. View the logs.


12 months ago

#4 @garrett-eclipse
12 months ago

  • Keywords commit added
  • Milestone changed from Awaiting Review to 5.6

Awesome, let's get a committers review and see if we can land this in 5.6.

#5 @garrett-eclipse
12 months ago

  • Owner set to garrett-eclipse
  • Status changed from new to accepted

#6 @SergeyBiryukov
12 months ago

  • Resolution set to fixed
  • Status changed from accepted to closed

In 49117:

Tests: Update third-party video URLs in unit tests with more permanent videos.

This brings some consistency to the YouTube and Vimeo URLs used for tests:

  • For YouTube, use the video of WordPress 5.0 release.
  • For Vimeo, use one of the official test videos.

Props garrett-eclipse, dd32.
Fixes #51487. See #meta5467.

This ticket was mentioned in Slack in #docs by garrett-eclipse. View the logs.


12 months ago

#8 @garrett-eclipse
12 months ago

Thanks @SergeyBiryukov I've added a note to the Automated Testing document here;
https://make.wordpress.org/core/handbook/testing/automated-testing/

Note: See TracTickets for help on using tickets.