Merge pull request #855 from p-l-/fix-test-pyx

Rename test_pyx to _test_pyx to "hide" it
This commit is contained in:
Guillaume Valadon 2017-10-02 10:10:50 +02:00 committed by GitHub
commit 697c462f6d
2 changed files with 6 additions and 6 deletions

View File

@ -27,7 +27,7 @@ except (ImportError, RuntimeError):
MATPLOTLIB_DEFAULT_PLOT_KARGS = dict()
log_loading.info("Can't import matplotlib. Won't be able to plot.")
def test_pyx():
def _test_pyx():
"""Returns if PyX is correctly installed or not"""
try:
with open(os.devnull, 'wb') as devnull:
@ -39,7 +39,7 @@ def test_pyx():
try:
import pyx
if test_pyx():
if _test_pyx():
PYX = 1
else:
log_loading.warning("PyX dependencies are not installed ! Please install TexLive or MikTeX.")

View File

@ -9148,8 +9148,8 @@ test_afterglow()
= psdump()
print(test_pyx())
if test_pyx():
print("PYX: %d" % PYX)
if PYX:
import tempfile
import os
filename = tempfile.mktemp(suffix=".ps")
@ -9160,8 +9160,8 @@ if test_pyx():
= pdfdump()
print(test_pyx())
if test_pyx():
print("PYX: %d" % PYX)
if PYX:
import tempfile
import os
filename = tempfile.mktemp(suffix=".pdf")