summaryrefslogtreecommitdiffstats
path: root/mobile/android/tests/browser/chrome/video_discovery.html
blob: 6eb181dc424462f2f5a9282e0d21f5b0b45e4788 (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
<!DOCTYPE HTML>
<html>
  <head>
    <title>Video Discovery Test</title>
    <style type="text/css">
      #video-box {
        float: left;
      }
      #video-overlay, #video-player {
        width: 640px;
        min-height: 370px;
      }
      #video-overlay {
        position: absolute;
        float: left;
        background-color:#f00;
        z-index:10;
      }
    </style>
  </head>
  <body>
    <!-- PASS: src uses a mp4 extension -->
    <video id="simple-mp4" poster="/simple.png" src="/simple.mp4"></video>

    <!-- FAIL: src uses a ogg extension -->
    <video id="simple-fail" src="/simple.ogg"></video>

    <!-- PASS: source list uses a mp4 extension -->
    <video id="with-sources-mp4">
      <source src="/simple.ogg">
      <source src="/simple.mp4">
    </video>

    <!-- PASS: source list uses a webm extension -->
    <video id="with-sources-webm">
      <source src="/simple.ogg">
      <source src="/simple.webm">
    </video>

    <!-- FAIL: source list has no mp4 or webm extension -->
    <video id="with-sources-fail">
      <source src="/simple.ogg">
    </video>

    <!-- PASS: source list uses a mp4 mimetype -->
    <video id="with-sources-mimetype-mp4">
      <source src="/simple-video-ogg" type="video/ogg">
      <source src="/simple-video-mp4" type="video/mp4">
    </video>

    <!-- PASS: source list uses a webm mimetype -->
    <video id="with-sources-mimetype-webm">
      <source src="/simple-video-ogg" type="video/ogg">
      <source src="/simple-video-webm" type="video/webm">
    </video>

    <!-- PASS: source list uses a mp4 mimetype and extra data -->
    <video id="with-sources-mimetype-plus">
      <source src="/simple-video-ogg" type="video/ogg">
      <source src="/simple-video-mp4" type="video/mp4; codecs='avc1.42E01E, mp4a.40.2'">
    </video>

    <!-- PASS: src uses a mp4 mimetype from the server -->
    <video id="simple-fetch-pass" src="http://mochi.test:8888/chrome/mobile/android/tests/browser/chrome/video_discovery.sjs?type=video/mp4"></video>

    <!-- FAIL: src uses a non-video mimetype from the server -->
    <video id="simple-fetch-fail" src="http://mochi.test:8888/chrome/mobile/android/tests/browser/chrome/video_discovery.sjs?type=image/png"></video>

    <!-- PASS: div overlay covers a video with mp4 src -->
    <div id="video-box">
      <div id="video-overlay"></div>
      <div>
        <video id="video-player" src="/simple.mp4"></video>
      </div>
    </div>
  </body>
</html>