Show More
@@ -1,13 +1,14 b'' | |||||
1 | """Base class for notebook tests.""" |
|
1 | """Base class for notebook tests.""" | |
2 |
|
2 | |||
3 | import os |
|
|||
4 | import sys |
|
3 | import sys | |
5 | import time |
|
4 | import time | |
6 | import requests |
|
5 | import requests | |
7 | from contextlib import contextmanager |
|
6 | from contextlib import contextmanager | |
8 |
from subprocess import Popen, |
|
7 | from subprocess import Popen, STDOUT | |
9 | from unittest import TestCase |
|
8 | from unittest import TestCase | |
10 |
|
9 | |||
|
10 | import nose | |||
|
11 | ||||
11 | from IPython.utils.tempdir import TemporaryDirectory |
|
12 | from IPython.utils.tempdir import TemporaryDirectory | |
12 |
|
13 | |||
13 | class NotebookTestBase(TestCase): |
|
14 | class NotebookTestBase(TestCase): | |
@@ -55,11 +56,11 b' class NotebookTestBase(TestCase):' | |||||
55 | '--ipython-dir=%s' % cls.ipython_dir.name, |
|
56 | '--ipython-dir=%s' % cls.ipython_dir.name, | |
56 | '--notebook-dir=%s' % cls.notebook_dir.name, |
|
57 | '--notebook-dir=%s' % cls.notebook_dir.name, | |
57 | ] |
|
58 | ] | |
58 | devnull = open(os.devnull, 'w') |
|
|||
59 | cls.notebook = Popen(notebook_args, |
|
59 | cls.notebook = Popen(notebook_args, | |
60 | stdout=devnull, |
|
60 | stdout=nose.ipy_stream_capturer.writefd, | |
61 |
stderr= |
|
61 | stderr=STDOUT, | |
62 | ) |
|
62 | ) | |
|
63 | nose.ipy_stream_capturer.ensure_started() | |||
63 | cls.wait_until_alive() |
|
64 | cls.wait_until_alive() | |
64 |
|
65 | |||
65 | @classmethod |
|
66 | @classmethod |
General Comments 0
You need to be logged in to leave comments.
Login now