Shorten test paths: rename image_specific_tests => by_image

This commit is contained in:
Ayaz Salikhov
2025-02-24 01:18:33 +00:00
parent 24fe890c21
commit 5a556f5c8a
54 changed files with 1 additions and 1 deletions

View File

@@ -0,0 +1,25 @@
# Matplotlib: Test tex fonts
import matplotlib
import matplotlib.pyplot as plt
matplotlib.rcParams["pgf.texsystem"] = "pdflatex"
matplotlib.rcParams.update(
{
"font.family": "serif",
"font.size": 18,
"axes.labelsize": 20,
"axes.titlesize": 24,
"figure.titlesize": 28,
}
)
matplotlib.rcParams["text.usetex"] = True
fig, ax = plt.subplots(1, 1)
x = [1, 2]
y = [1, 2]
ax.plot(x, y, label="a label")
ax.legend(fontsize=15)
file_path = "/tmp/test_fonts.png"
fig.savefig(file_path)
print(f"File {file_path} saved")