Show More
@@ -2,6 +2,7 b'' | |||
|
2 | 2 | # Distributed under the terms of the Modified BSD License. |
|
3 | 3 | |
|
4 | 4 | import json |
|
5 | import tempfile | |
|
5 | 6 | import os |
|
6 | 7 | import warnings |
|
7 | 8 | |
@@ -149,4 +150,12 b' def test_json():' | |||
|
149 | 150 | nt.assert_equal(len(w), 1) |
|
150 | 151 | nt.assert_equal(j._repr_json_(), lis) |
|
151 | 152 | |
|
153 | def test_video_embedding(): | |
|
154 | """use a tempfile, with dummy-data, to ensure that video embedding doesn't crash""" | |
|
155 | with tempfile.NamedTemporaryFile(suffix='.mp4') as f: | |
|
156 | with open(f.name,'wb') as f: | |
|
157 | f.write(b'abc') | |
|
152 | 158 | |
|
159 | v = display.Video(f.name, embed=True) | |
|
160 | html = v._repr_html_() | |
|
161 | nt.assert_in('src="data:video/mp4;base64,YWJj"',html) |
General Comments 0
You need to be logged in to leave comments.
Login now