Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view

This file was deleted.

This file was deleted.

Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
outs:
- md5: 8924c7d80afcc92df4e77e6856b553a4
size: 336254
hash: md5
path: test_pygmtlogo_design_circle-horizontal.png
Original file line number Diff line number Diff line change
@@ -0,0 +1,5 @@
outs:
- md5: 5ee82660f20bc8424f3051af4f9fb9ac
size: 173671
hash: md5
path: test_pygmtlogo_design_circle-vertical.png
Original file line number Diff line number Diff line change
Expand Up @@ -2,4 +2,4 @@ outs:
- md5: fdc90d2867bcbc096bcf5a9303d15ddf
size: 31962
hash: md5
path: test_pygmtlogo_circle_no_wordmark.png
path: test_pygmtlogo_wordmark_none_circle.png
17 changes: 10 additions & 7 deletions pygmt/tests/test_pygmtlogo.py
Original file line number Diff line number Diff line change
Expand Up @@ -10,23 +10,25 @@

@pytest.mark.mpl_image_compare(savefig_kwargs={"dpi": 600})
@pytest.mark.parametrize("wordmark", ["horizontal", "vertical"])
def test_pygmtlogo_circle_design(wordmark):
@pytest.mark.parametrize("shape", ["circle"])
def test_pygmtlogo_design(shape, wordmark):
"""
Test the design details of the PyGMT circular logo, with a wordmark.
Test the design details of the PyGMT logo with a wordmark.

This is a regression test to ensure that the design of the logo does not change
unintentionally. The debugging lines (gridlines and circles) are helpful for
implementing the logo, but they are not included in the final logo design.
"""
fig = _create_logo(debug=True, wordmark=wordmark)
fig = _create_logo(debug=True, shape=shape, wordmark=wordmark)
return fig


@pytest.mark.mpl_image_compare
def test_pygmtlogo_circle_no_wordmark():
@pytest.mark.parametrize("shape", ["circle"])
def test_pygmtlogo_wordmark_none(shape):
"""
Test the PyGMT circular logo without the wordmark, including both light/dark themes,
and colored/black-and-white versions.
Test the PyGMT logo without the wordmark, including both light/dark themes, and
colored/black-and-white versions.
"""
fig = Figure()
fig.basemap(
Expand All @@ -41,8 +43,9 @@ def test_pygmtlogo_circle_no_wordmark():
((3.5, 1.0), "dark", False),
]:
fig.pygmtlogo(
position=Position((x, y), anchor="CM", cstype="mapcoords"),
position=Position((x, y), anchor="MC", cstype="mapcoords"),
theme=theme,
color=color,
shape=shape,
)
return fig
Loading