示例#1
0
 def test_map_data(self):
     fig = figure()
     ax = fig.gca()
     html = map_data(self.data, ax, 'test.png')
     self.assertTrue(html.startswith('<!doctype html>'))
     html = map_data(self.data, ax, 'test.png', standalone=False)
     self.assertTrue(html.startswith('\n<img src="test.png"'))
示例#2
0
 def test_map_data(self):
     fig = figure()
     ax = fig.gca()
     html = map_data(self.data, ax, 'test.png')
     self.assertTrue(html.startswith('<!doctype html>'))
     html = map_data(self.data, ax, 'test.png', standalone=False)
     self.assertTrue(html.startswith('\n<img src="test.png"'))
示例#3
0
 def test_map_data(self):
     numpy.random.seed(0)
     data = numpy.vstack((numpy.arange(100), numpy.random.random(100)))
     fig = figure()
     ax = fig.gca()
     html = map_data(data, ax, 'test.png')
     assert html.startswith('<!doctype html>')
     html = map_data(data, ax, 'test.png', standalone=False)
     assert html.startswith('\n<img src="test.png"')
示例#4
0
 def test_map_data(self):
     numpy.random.seed(0)
     data = numpy.vstack((numpy.arange(100), numpy.random.random(100)))
     fig = figure()
     ax = fig.gca()
     html = map_data(data, ax, 'test.png')
     assert html.startswith('<!doctype html>')
     html = map_data(data, ax, 'test.png', standalone=False)
     assert html.startswith('\n<img src="test.png"')