WordPress.org

Make WordPress Core

Ticket #45615: 45615.9.diff

File 45615.9.diff, 25.6 KB (added by joemcgill, 4 months ago)

Ensure test files are included in the patch.

  • src/wp-includes/functions.php

    diff --git src/wp-includes/functions.php src/wp-includes/functions.php
    index 439a2a30ce..8c209ec6bf 100644
    function wp_check_filetype_and_ext( $file, $filename, $mimes = null ) { 
    25692569                         * This means that common mismatches are forgiven: application/vnd.apple.numbers is often misidentified as application/zip,
    25702570                         * and some media files are commonly named with the wrong extension (.mov instead of .mp4)
    25712571                         */
    2572 
    25732572                        if ( substr( $real_mime, 0, strcspn( $real_mime, '/' ) ) !== substr( $type, 0, strcspn( $type, '/' ) ) ) {
    25742573                                $type = $ext = false;
    25752574                        }
     2575                } elseif ( 'text/plain' === $real_mime ) {
     2576                        // A few common file types are occasionally detected as text/plain; allow those.
     2577                        if ( ! in_array( $type, array(
     2578                                        'text/plain',
     2579                                        'text/csv',
     2580                                        'text/richtext',
     2581                                        'text/tsv',
     2582                                        'text/vtt',
     2583                                ) )
     2584                        ) {
     2585                                $type = $ext = false;
     2586                        }
     2587                } elseif( 'text/rtf' === $real_mime ) {
     2588                        // Special casing for RTF files.
     2589                        if ( ! in_array( $type, array(
     2590                                        'text/rtf',
     2591                                        'text/plain',
     2592                                        'application/rtf',
     2593                                ) )
     2594                        ) {
     2595                                $type = $ext = false;
     2596                        }
    25762597                } else {
    25772598                        if ( $type !== $real_mime ) {
    25782599                                /*
  • new file tests/phpunit/data/uploads/test.csv

    diff --git tests/phpunit/data/uploads/test.csv tests/phpunit/data/uploads/test.csv
    new file mode 100644
    index 0000000000..27ad333349
    - +  
     1"country","country group","name (en)","name (fr)","name (de)","latitude","longitude"
     2"at","eu","Austria","Autriche","Österreich","47.6965545","13.34598005"
     3"be","eu","Belgium","Belgique","Belgien","50.501045","4.47667405"
     4"bg","eu","Bulgaria","Bulgarie","Bulgarien","42.72567375","25.4823218"
     5"country","country group","name (en)","name (fr)","name (de)","latitude","longitude"
     6"at","eu","Austria","Autriche","Österreich","47.6965545","13.34598005"
     7"be","eu","Belgium","Belgique","Belgien","50.501045","4.47667405"
     8"bg","eu","Bulgaria","Bulgarie","Bulgarien","42.72567375","25.4823218"
     9"country","country group","name (en)","name (fr)","name (de)","latitude","longitude"
     10"at","eu","Austria","Autriche","Österreich","47.6965545","13.34598005"
     11"be","eu","Belgium","Belgique","Belgien","50.501045","4.47667405"
     12"bg","eu","Bulgaria","Bulgarie","Bulgarien","42.72567375","25.4823218"
     13"country","country group","name (en)","name (fr)","name (de)","latitude","longitude"
     14"at","eu","Austria","Autriche","Österreich","47.6965545","13.34598005"
     15"be","eu","Belgium","Belgique","Belgien","50.501045","4.47667405"
     16"bg","eu","Bulgaria","Bulgarie","Bulgarien","42.72567375","25.4823218"
     17 No newline at end of file
  • new file tests/phpunit/data/uploads/test.dfxp

    diff --git tests/phpunit/data/uploads/test.dfxp tests/phpunit/data/uploads/test.dfxp
    new file mode 100644
    index 0000000000..c3f7cde405
    - +  
     1<?xml version="1.0" encoding="utf-8"?>
     2<tt xml:lang="en" xmlns="http://www.w3.org/ns/ttml"
     3        xmlns:tts="http://www.w3.org/ns/ttml#styling"
     4        xmlns:ttm="http://www.w3.org/ns/ttml#metadata">
     5        <head>
     6                <styling>
     7                        <style xml:id="defaultCaption" tts:fontSize="10" tts:fontFamily="SansSerif"
     8                        tts:fontWeight="normal" tts:fontStyle="normal"
     9                        tts:textDecoration="none" tts:color="white"
     10                        tts:backgroundColor="black" />
     11                </styling>
     12
     13        </head>
     14        <body>
     15                <div style="defaultCaption" xml:lang="en">
     16                        <p begin="00:00:03.400" end="00:00:06.177">In this lesson, we're going to<br />be talking about finance. And</p>
     17                        <p begin="00:00:06.177" end="00:00:10.009">one of the most important aspects<br />of finance is interest.</p>
     18                        <p begin="00:00:10.009" end="00:00:13.655">When I go to a bank or some<br />other lending institution</p>
     19                        <p begin="00:00:13.655" end="00:00:17.720">to borrow money, the bank is happy<br />to give me that money. But then I'm</p>
     20                        <p begin="00:00:17.900" end="00:00:21.480">going to be paying the bank for the<br />privilege of using their money. And that</p>
     21                        <p begin="00:00:21.660" end="00:00:26.440">amount of money that I pay the bank is<br />called interest. Likewise, if I put money</p>
     22                        <p begin="00:00:26.620" end="00:00:31.220">in a savings account or I purchase a<br />certificate of deposit, the bank just</p>
     23                        <p begin="00:00:31.300" end="00:00:35.800">doesn't put my money in a little box<br />and leave it there until later. They take</p>
     24                        <p begin="00:00:35.800" end="00:00:40.822">my money and lend it to someone<br />else. So they are using my money.</p>
     25                        <p begin="00:00:40.822" end="00:00:44.400">The bank has to pay me for the privilege<br />of using my money.</p>
     26                        <p begin="00:00:44.400" end="00:00:48.700">Now what makes banks<br />profitable is the rate</p>
     27                        <p begin="00:00:48.700" end="00:00:53.330">that they charge people to use the bank's<br />money is higher than the rate that they</p>
     28                        <p begin="00:00:53.510" end="00:01:00.720">pay people like me to use my money. The<br />amount of interest that a person pays or</p>
     29                        <p begin="00:01:00.800" end="00:01:06.640">earns is dependent on three things. It's<br />dependent on how much money is involved.</p>
     30                        <p begin="00:01:06.820" end="00:01:11.300">It's dependent upon the rate of interest<br />being paid or the rate of interest being</p>
     31                        <p begin="00:01:11.480" end="00:01:17.898">charged. And it's also dependent upon<br />how much time is involved. If I have</p>
     32                        <p begin="00:01:17.898" end="00:01:22.730">a loan and I want to decrease the amount<br />of interest that I'm going to pay, then</p>
     33                        <p begin="00:01:22.800" end="00:01:28.040">I'm either going to have to decrease how<br />much money I borrow, I'm going to have</p>
     34                        <p begin="00:01:28.220" end="00:01:32.420">to borrow the money over a shorter period<br />of time, or I'm going to have to find a</p>
     35                        <p begin="00:01:32.600" end="00:01:37.279">lending institution that charges a lower<br />interest rate. On the other hand, if I</p>
     36                        <p begin="00:01:37.279" end="00:01:41.480">want to earn more interest on my<br />investment, I'm going to have to invest</p>
     37                        <p begin="00:01:41.480" end="00:01:46.860">more money, leave the money in the<br />account for a longer period of time, or</p>
     38                        <p begin="00:01:46.860" end="00:01:49.970">find an institution that will pay<br />me a higher interest rate.</p>
     39                </div>
     40        </body>
     41</tt>
     42<?xml version="1.0" encoding="utf-8"?>
     43<tt xml:lang="en" xmlns="http://www.w3.org/ns/ttml"
     44        xmlns:tts="http://www.w3.org/ns/ttml#styling"
     45        xmlns:ttm="http://www.w3.org/ns/ttml#metadata">
     46        <head>
     47                <styling>
     48                        <style xml:id="defaultCaption" tts:fontSize="10" tts:fontFamily="SansSerif"
     49                        tts:fontWeight="normal" tts:fontStyle="normal"
     50                        tts:textDecoration="none" tts:color="white"
     51                        tts:backgroundColor="black" />
     52                </styling>
     53
     54        </head>
     55        <body>
     56                <div style="defaultCaption" xml:lang="en">
     57                        <p begin="00:00:03.400" end="00:00:06.177">In this lesson, we're going to<br />be talking about finance. And</p>
     58                        <p begin="00:00:06.177" end="00:00:10.009">one of the most important aspects<br />of finance is interest.</p>
     59                        <p begin="00:00:10.009" end="00:00:13.655">When I go to a bank or some<br />other lending institution</p>
     60                        <p begin="00:00:13.655" end="00:00:17.720">to borrow money, the bank is happy<br />to give me that money. But then I'm</p>
     61                        <p begin="00:00:17.900" end="00:00:21.480">going to be paying the bank for the<br />privilege of using their money. And that</p>
     62                        <p begin="00:00:21.660" end="00:00:26.440">amount of money that I pay the bank is<br />called interest. Likewise, if I put money</p>
     63                        <p begin="00:00:26.620" end="00:00:31.220">in a savings account or I purchase a<br />certificate of deposit, the bank just</p>
     64                        <p begin="00:00:31.300" end="00:00:35.800">doesn't put my money in a little box<br />and leave it there until later. They take</p>
     65                        <p begin="00:00:35.800" end="00:00:40.822">my money and lend it to someone<br />else. So they are using my money.</p>
     66                        <p begin="00:00:40.822" end="00:00:44.400">The bank has to pay me for the privilege<br />of using my money.</p>
     67                        <p begin="00:00:44.400" end="00:00:48.700">Now what makes banks<br />profitable is the rate</p>
     68                        <p begin="00:00:48.700" end="00:00:53.330">that they charge people to use the bank's<br />money is higher than the rate that they</p>
     69                        <p begin="00:00:53.510" end="00:01:00.720">pay people like me to use my money. The<br />amount of interest that a person pays or</p>
     70                        <p begin="00:01:00.800" end="00:01:06.640">earns is dependent on three things. It's<br />dependent on how much money is involved.</p>
     71                        <p begin="00:01:06.820" end="00:01:11.300">It's dependent upon the rate of interest<br />being paid or the rate of interest being</p>
     72                        <p begin="00:01:11.480" end="00:01:17.898">charged. And it's also dependent upon<br />how much time is involved. If I have</p>
     73                        <p begin="00:01:17.898" end="00:01:22.730">a loan and I want to decrease the amount<br />of interest that I'm going to pay, then</p>
     74                        <p begin="00:01:22.800" end="00:01:28.040">I'm either going to have to decrease how<br />much money I borrow, I'm going to have</p>
     75                        <p begin="00:01:28.220" end="00:01:32.420">to borrow the money over a shorter period<br />of time, or I'm going to have to find a</p>
     76                        <p begin="00:01:32.600" end="00:01:37.279">lending institution that charges a lower<br />interest rate. On the other hand, if I</p>
     77                        <p begin="00:01:37.279" end="00:01:41.480">want to earn more interest on my<br />investment, I'm going to have to invest</p>
     78                        <p begin="00:01:41.480" end="00:01:46.860">more money, leave the money in the<br />account for a longer period of time, or</p>
     79                        <p begin="00:01:46.860" end="00:01:49.970">find an institution that will pay<br />me a higher interest rate.</p>
     80                </div>
     81        </body>
     82</tt>
     83<?xml version="1.0" encoding="utf-8"?>
     84<tt xml:lang="en" xmlns="http://www.w3.org/ns/ttml"
     85        xmlns:tts="http://www.w3.org/ns/ttml#styling"
     86        xmlns:ttm="http://www.w3.org/ns/ttml#metadata">
     87        <head>
     88                <styling>
     89                        <style xml:id="defaultCaption" tts:fontSize="10" tts:fontFamily="SansSerif"
     90                        tts:fontWeight="normal" tts:fontStyle="normal"
     91                        tts:textDecoration="none" tts:color="white"
     92                        tts:backgroundColor="black" />
     93                </styling>
     94
     95        </head>
     96        <body>
     97                <div style="defaultCaption" xml:lang="en">
     98                        <p begin="00:00:03.400" end="00:00:06.177">In this lesson, we're going to<br />be talking about finance. And</p>
     99                        <p begin="00:00:06.177" end="00:00:10.009">one of the most important aspects<br />of finance is interest.</p>
     100                        <p begin="00:00:10.009" end="00:00:13.655">When I go to a bank or some<br />other lending institution</p>
     101                        <p begin="00:00:13.655" end="00:00:17.720">to borrow money, the bank is happy<br />to give me that money. But then I'm</p>
     102                        <p begin="00:00:17.900" end="00:00:21.480">going to be paying the bank for the<br />privilege of using their money. And that</p>
     103                        <p begin="00:00:21.660" end="00:00:26.440">amount of money that I pay the bank is<br />called interest. Likewise, if I put money</p>
     104                        <p begin="00:00:26.620" end="00:00:31.220">in a savings account or I purchase a<br />certificate of deposit, the bank just</p>
     105                        <p begin="00:00:31.300" end="00:00:35.800">doesn't put my money in a little box<br />and leave it there until later. They take</p>
     106                        <p begin="00:00:35.800" end="00:00:40.822">my money and lend it to someone<br />else. So they are using my money.</p>
     107                        <p begin="00:00:40.822" end="00:00:44.400">The bank has to pay me for the privilege<br />of using my money.</p>
     108                        <p begin="00:00:44.400" end="00:00:48.700">Now what makes banks<br />profitable is the rate</p>
     109                        <p begin="00:00:48.700" end="00:00:53.330">that they charge people to use the bank's<br />money is higher than the rate that they</p>
     110                        <p begin="00:00:53.510" end="00:01:00.720">pay people like me to use my money. The<br />amount of interest that a person pays or</p>
     111                        <p begin="00:01:00.800" end="00:01:06.640">earns is dependent on three things. It's<br />dependent on how much money is involved.</p>
     112                        <p begin="00:01:06.820" end="00:01:11.300">It's dependent upon the rate of interest<br />being paid or the rate of interest being</p>
     113                        <p begin="00:01:11.480" end="00:01:17.898">charged. And it's also dependent upon<br />how much time is involved. If I have</p>
     114                        <p begin="00:01:17.898" end="00:01:22.730">a loan and I want to decrease the amount<br />of interest that I'm going to pay, then</p>
     115                        <p begin="00:01:22.800" end="00:01:28.040">I'm either going to have to decrease how<br />much money I borrow, I'm going to have</p>
     116                        <p begin="00:01:28.220" end="00:01:32.420">to borrow the money over a shorter period<br />of time, or I'm going to have to find a</p>
     117                        <p begin="00:01:32.600" end="00:01:37.279">lending institution that charges a lower<br />interest rate. On the other hand, if I</p>
     118                        <p begin="00:01:37.279" end="00:01:41.480">want to earn more interest on my<br />investment, I'm going to have to invest</p>
     119                        <p begin="00:01:41.480" end="00:01:46.860">more money, leave the money in the<br />account for a longer period of time, or</p>
     120                        <p begin="00:01:46.860" end="00:01:49.970">find an institution that will pay<br />me a higher interest rate.</p>
     121                </div>
     122        </body>
     123</tt>
     124<?xml version="1.0" encoding="utf-8"?>
     125<tt xml:lang="en" xmlns="http://www.w3.org/ns/ttml"
     126        xmlns:tts="http://www.w3.org/ns/ttml#styling"
     127        xmlns:ttm="http://www.w3.org/ns/ttml#metadata">
     128        <head>
     129                <styling>
     130                        <style xml:id="defaultCaption" tts:fontSize="10" tts:fontFamily="SansSerif"
     131                        tts:fontWeight="normal" tts:fontStyle="normal"
     132                        tts:textDecoration="none" tts:color="white"
     133                        tts:backgroundColor="black" />
     134                </styling>
     135
     136        </head>
     137        <body>
     138                <div style="defaultCaption" xml:lang="en">
     139                        <p begin="00:00:03.400" end="00:00:06.177">In this lesson, we're going to<br />be talking about finance. And</p>
     140                        <p begin="00:00:06.177" end="00:00:10.009">one of the most important aspects<br />of finance is interest.</p>
     141                        <p begin="00:00:10.009" end="00:00:13.655">When I go to a bank or some<br />other lending institution</p>
     142                        <p begin="00:00:13.655" end="00:00:17.720">to borrow money, the bank is happy<br />to give me that money. But then I'm</p>
     143                        <p begin="00:00:17.900" end="00:00:21.480">going to be paying the bank for the<br />privilege of using their money. And that</p>
     144                        <p begin="00:00:21.660" end="00:00:26.440">amount of money that I pay the bank is<br />called interest. Likewise, if I put money</p>
     145                        <p begin="00:00:26.620" end="00:00:31.220">in a savings account or I purchase a<br />certificate of deposit, the bank just</p>
     146                        <p begin="00:00:31.300" end="00:00:35.800">doesn't put my money in a little box<br />and leave it there until later. They take</p>
     147                        <p begin="00:00:35.800" end="00:00:40.822">my money and lend it to someone<br />else. So they are using my money.</p>
     148                        <p begin="00:00:40.822" end="00:00:44.400">The bank has to pay me for the privilege<br />of using my money.</p>
     149                        <p begin="00:00:44.400" end="00:00:48.700">Now what makes banks<br />profitable is the rate</p>
     150                        <p begin="00:00:48.700" end="00:00:53.330">that they charge people to use the bank's<br />money is higher than the rate that they</p>
     151                        <p begin="00:00:53.510" end="00:01:00.720">pay people like me to use my money. The<br />amount of interest that a person pays or</p>
     152                        <p begin="00:01:00.800" end="00:01:06.640">earns is dependent on three things. It's<br />dependent on how much money is involved.</p>
     153                        <p begin="00:01:06.820" end="00:01:11.300">It's dependent upon the rate of interest<br />being paid or the rate of interest being</p>
     154                        <p begin="00:01:11.480" end="00:01:17.898">charged. And it's also dependent upon<br />how much time is involved. If I have</p>
     155                        <p begin="00:01:17.898" end="00:01:22.730">a loan and I want to decrease the amount<br />of interest that I'm going to pay, then</p>
     156                        <p begin="00:01:22.800" end="00:01:28.040">I'm either going to have to decrease how<br />much money I borrow, I'm going to have</p>
     157                        <p begin="00:01:28.220" end="00:01:32.420">to borrow the money over a shorter period<br />of time, or I'm going to have to find a</p>
     158                        <p begin="00:01:32.600" end="00:01:37.279">lending institution that charges a lower<br />interest rate. On the other hand, if I</p>
     159                        <p begin="00:01:37.279" end="00:01:41.480">want to earn more interest on my<br />investment, I'm going to have to invest</p>
     160                        <p begin="00:01:41.480" end="00:01:46.860">more money, leave the money in the<br />account for a longer period of time, or</p>
     161                        <p begin="00:01:46.860" end="00:01:49.970">find an institution that will pay<br />me a higher interest rate.</p>
     162                </div>
     163        </body>
     164</tt>
  • new file tests/phpunit/data/uploads/test.json

    diff --git tests/phpunit/data/uploads/test.json tests/phpunit/data/uploads/test.json
    new file mode 100644
    index 0000000000..8663e97887
    - +  
     1{"menu": {
     2  "id": "file",
     3  "value": "File",
     4  "popup": {
     5    "menuitem": [
     6      {"value": "New", "onclick": "CreateNewDoc()"},
     7      {"value": "Open", "onclick": "OpenDoc()"},
     8      {"value": "Close", "onclick": "CloseDoc()"}
     9    ]
     10  }
     11}}
     12{"menu": {
     13  "id": "file",
     14  "value": "File",
     15  "popup": {
     16    "menuitem": [
     17      {"value": "New", "onclick": "CreateNewDoc()"},
     18      {"value": "Open", "onclick": "OpenDoc()"},
     19      {"value": "Close", "onclick": "CloseDoc()"}
     20    ]
     21  }
     22}}
     23{"menu": {
     24  "id": "file",
     25  "value": "File",
     26  "popup": {
     27    "menuitem": [
     28      {"value": "New", "onclick": "CreateNewDoc()"},
     29      {"value": "Open", "onclick": "OpenDoc()"},
     30      {"value": "Close", "onclick": "CloseDoc()"}
     31    ]
     32  }
     33}}
     34{"menu": {
     35  "id": "file",
     36  "value": "File",
     37  "popup": {
     38    "menuitem": [
     39      {"value": "New", "onclick": "CreateNewDoc()"},
     40      {"value": "Open", "onclick": "OpenDoc()"},
     41      {"value": "Close", "onclick": "CloseDoc()"}
     42    ]
     43  }
     44}}
     45 No newline at end of file
  • new file tests/phpunit/data/uploads/test.rtf

    diff --git tests/phpunit/data/uploads/test.rtf tests/phpunit/data/uploads/test.rtf
    new file mode 100644
    index 0000000000..d8bcbf1621
    - +  
     1{\rtf1\ansi\ansicpg1252\cocoartf1671
     2{\fonttbl\f0\fswiss\fcharset0 Helvetica;}
     3{\colortbl;\red255\green255\blue255;}
     4{\*\expandedcolortbl;;}
     5\margl1440\margr1440\vieww14400\viewh11400\viewkind0
     6\pard\tx720\tx1440\tx2160\tx2880\tx3600\tx4320\tx5040\tx5760\tx6480\tx7200\tx7920\tx8640\pardirnatural\partightenfactor0
     7
     8\f0\fs24 \cf0 Test file.}
     9 No newline at end of file
  • new file tests/phpunit/data/uploads/test.tsv

    diff --git tests/phpunit/data/uploads/test.tsv tests/phpunit/data/uploads/test.tsv
    new file mode 100644
    index 0000000000..e66b39aa83
    - +  
     1sample  tsv     file    1
     2some    text    here    2
     3yup     it's    text    3
     4sample  tsv     file    1
     5some    text    here    2
     6yup     it's    text    3
     7sample  tsv     file    1
     8some    text    here    2
     9yup     it's    text    3
     10sample  tsv     file    1
     11some    text    here    2
     12yup     it's    text    3
     13 No newline at end of file
  • new file tests/phpunit/data/uploads/test.vtt

    diff --git tests/phpunit/data/uploads/test.vtt tests/phpunit/data/uploads/test.vtt
    new file mode 100644
    index 0000000000..d66ddd53c6
    - +  
     1WEBVTT
     2
     300:11.000 --> 00:13.000
     4<v Roger Bingham>We are in New York City
     5
     600:13.000 --> 00:16.000
     7<v Roger Bingham>We’re actually at the Lucern Hotel, just down the street
     8
     900:16.000 --> 00:18.000
     10<v Roger Bingham>from the American Museum of Natural History
     11
     1200:18.000 --> 00:20.000
     13<v Roger Bingham>And with me is Neil deGrasse Tyson
     14
     1500:20.000 --> 00:22.000
     16<v Roger Bingham>Astrophysicist, Director of the Hayden Planetarium
     17
     1800:22.000 --> 00:24.000
     19<v Roger Bingham>at the AMNH.
     20
     2100:24.000 --> 00:26.000
     22<v Roger Bingham>Thank you for walking down here.
     23
     2400:27.000 --> 00:30.000
     25<v Roger Bingham>And I want to do a follow-up on the last conversation we did.
     26
     2700:30.000 --> 00:31.500 align:right size:50%
     28<v Roger Bingham>When we e-mailed—
     29
     3000:30.500 --> 00:32.500 align:left size:50%
     31<v Neil deGrasse Tyson>Didn’t we talk about enough in that conversation?
     32
     3300:32.000 --> 00:35.500 align:right size:50%
     34<v Roger Bingham>No! No no no no; 'cos 'cos obviously 'cos
     35
     3600:32.500 --> 00:33.500 align:left size:50%
     37<v Neil deGrasse Tyson><i>Laughs</i>
     38
     3900:35.500 --> 00:38.000
     40<v Roger Bingham>You know I’m so excited my glasses are falling off here.
     41WEBVTT
     42
     4300:11.000 --> 00:13.000
     44<v Roger Bingham>We are in New York City
     45
     4600:13.000 --> 00:16.000
     47<v Roger Bingham>We’re actually at the Lucern Hotel, just down the street
     48
     4900:16.000 --> 00:18.000
     50<v Roger Bingham>from the American Museum of Natural History
     51
     5200:18.000 --> 00:20.000
     53<v Roger Bingham>And with me is Neil deGrasse Tyson
     54
     5500:20.000 --> 00:22.000
     56<v Roger Bingham>Astrophysicist, Director of the Hayden Planetarium
     57
     5800:22.000 --> 00:24.000
     59<v Roger Bingham>at the AMNH.
     60
     6100:24.000 --> 00:26.000
     62<v Roger Bingham>Thank you for walking down here.
     63
     6400:27.000 --> 00:30.000
     65<v Roger Bingham>And I want to do a follow-up on the last conversation we did.
     66
     6700:30.000 --> 00:31.500 align:right size:50%
     68<v Roger Bingham>When we e-mailed—
     69
     7000:30.500 --> 00:32.500 align:left size:50%
     71<v Neil deGrasse Tyson>Didn’t we talk about enough in that conversation?
     72
     7300:32.000 --> 00:35.500 align:right size:50%
     74<v Roger Bingham>No! No no no no; 'cos 'cos obviously 'cos
     75
     7600:32.500 --> 00:33.500 align:left size:50%
     77<v Neil deGrasse Tyson><i>Laughs</i>
     78
     7900:35.500 --> 00:38.000
     80<v Roger Bingham>You know I’m so excited my glasses are falling off here.
     81WEBVTT
     82
     8300:11.000 --> 00:13.000
     84<v Roger Bingham>We are in New York City
     85
     8600:13.000 --> 00:16.000
     87<v Roger Bingham>We’re actually at the Lucern Hotel, just down the street
     88
     8900:16.000 --> 00:18.000
     90<v Roger Bingham>from the American Museum of Natural History
     91
     9200:18.000 --> 00:20.000
     93<v Roger Bingham>And with me is Neil deGrasse Tyson
     94
     9500:20.000 --> 00:22.000
     96<v Roger Bingham>Astrophysicist, Director of the Hayden Planetarium
     97
     9800:22.000 --> 00:24.000
     99<v Roger Bingham>at the AMNH.
     100
     10100:24.000 --> 00:26.000
     102<v Roger Bingham>Thank you for walking down here.
     103
     10400:27.000 --> 00:30.000
     105<v Roger Bingham>And I want to do a follow-up on the last conversation we did.
     106
     10700:30.000 --> 00:31.500 align:right size:50%
     108<v Roger Bingham>When we e-mailed—
     109
     11000:30.500 --> 00:32.500 align:left size:50%
     111<v Neil deGrasse Tyson>Didn’t we talk about enough in that conversation?
     112
     11300:32.000 --> 00:35.500 align:right size:50%
     114<v Roger Bingham>No! No no no no; 'cos 'cos obviously 'cos
     115
     11600:32.500 --> 00:33.500 align:left size:50%
     117<v Neil deGrasse Tyson><i>Laughs</i>
     118
     11900:35.500 --> 00:38.000
     120<v Roger Bingham>You know I’m so excited my glasses are falling off here.
     121WEBVTT
     122
     12300:11.000 --> 00:13.000
     124<v Roger Bingham>We are in New York City
     125
     12600:13.000 --> 00:16.000
     127<v Roger Bingham>We’re actually at the Lucern Hotel, just down the street
     128
     12900:16.000 --> 00:18.000
     130<v Roger Bingham>from the American Museum of Natural History
     131
     13200:18.000 --> 00:20.000
     133<v Roger Bingham>And with me is Neil deGrasse Tyson
     134
     13500:20.000 --> 00:22.000
     136<v Roger Bingham>Astrophysicist, Director of the Hayden Planetarium
     137
     13800:22.000 --> 00:24.000
     139<v Roger Bingham>at the AMNH.
     140
     14100:24.000 --> 00:26.000
     142<v Roger Bingham>Thank you for walking down here.
     143
     14400:27.000 --> 00:30.000
     145<v Roger Bingham>And I want to do a follow-up on the last conversation we did.
     146
     14700:30.000 --> 00:31.500 align:right size:50%
     148<v Roger Bingham>When we e-mailed—
     149
     15000:30.500 --> 00:32.500 align:left size:50%
     151<v Neil deGrasse Tyson>Didn’t we talk about enough in that conversation?
     152
     15300:32.000 --> 00:35.500 align:right size:50%
     154<v Roger Bingham>No! No no no no; 'cos 'cos obviously 'cos
     155
     15600:32.500 --> 00:33.500 align:left size:50%
     157<v Neil deGrasse Tyson><i>Laughs</i>
     158
     15900:35.500 --> 00:38.000
     160<v Roger Bingham>You know I’m so excited my glasses are falling off here.
     161 No newline at end of file
  • tests/phpunit/tests/functions.php

    diff --git tests/phpunit/tests/functions.php tests/phpunit/tests/functions.php
    index f76c342c2f..6a7c447c28 100644
    class Tests_Functions extends WP_UnitTestCase { 
    12301230        }
    12311231
    12321232        /**
    1233          * Data profider for test_wp_get_image_mime();
     1233         * Data provider for test_wp_get_image_mime();
    12341234         */
    12351235        public function _wp_get_image_mime() {
    12361236                $data = array(
    class Tests_Functions extends WP_UnitTestCase { 
    13361336                                        'proper_filename' => false,
    13371337                                ),
    13381338                        ),
     1339                        // Non-image file not allowed even if it's named like one.
     1340                        array(
     1341                                DIR_TESTDATA . '/export/crazy-cdata.xml',
     1342                                'crazy-cdata.jpg',
     1343                                array(
     1344                                        'ext' => false,
     1345                                        'type' => false,
     1346                                        'proper_filename' => false,
     1347                                ),
     1348                        ),
     1349                        // Non-image file not allowed if it's named like something else.
     1350                        array(
     1351                                DIR_TESTDATA . '/export/crazy-cdata.xml',
     1352                                'crazy-cdata.doc',
     1353                                array(
     1354                                        'ext' => false,
     1355                                        'type' => false,
     1356                                        'proper_filename' => false,
     1357                                ),
     1358                        ),
     1359                        // Assorted text/* sample files
     1360                        array(
     1361                                DIR_TESTDATA . '/uploads/test.vtt',
     1362                                'test.vtt',
     1363                                array(
     1364                                        'ext' => 'vtt',
     1365                                        'type' => 'text/vtt',
     1366                                        'proper_filename' => false,
     1367                                ),
     1368                        ),
     1369                        array(
     1370                                DIR_TESTDATA . '/uploads/test.csv',
     1371                                'test.csv',
     1372                                array(
     1373                                        'ext' => 'csv',
     1374                                        'type' => 'text/csv',
     1375                                        'proper_filename' => false,
     1376                                ),
     1377                        ),
     1378                        // RTF files.
     1379                        array(
     1380                                DIR_TESTDATA . '/uploads/test.rtf',
     1381                                'test.rtf',
     1382                                array(
     1383                                        'ext' => 'rtf',
     1384                                        'type' => 'application/rtf',
     1385                                        'proper_filename' => false,
     1386                                ),
     1387                        ),
    13391388                );
    13401389
    13411390                // Test a few additional file types on single sites.